mirror of
https://github.com/OpenDiablo2/OpenDiablo2
synced 2024-09-28 14:16:01 -04:00
fixed build and lint errors
This commit is contained in:
parent
8700d63f67
commit
3a5175f034
@ -274,7 +274,7 @@ func NewGameControls(
|
||||
hoverLabel.SetBackgroundColor(d2util.Color(blackAlpha50percent))
|
||||
|
||||
gc.heroStatsPanel.SetOnCloseCb(gc.onCloseHeroStatsPanel)
|
||||
gc.questLog.SetOnCloseCb(gc.onCloseHeroQuestLog)
|
||||
gc.questLog.SetOnCloseCb(gc.onCloseQuestLog)
|
||||
gc.inventory.SetOnCloseCb(gc.onCloseInventory)
|
||||
gc.skilltree.SetOnCloseCb(gc.onCloseSkilltree)
|
||||
|
||||
@ -604,10 +604,6 @@ func (g *GameControls) clearRightScreenSide() {
|
||||
g.updateLayout()
|
||||
}
|
||||
|
||||
func (g *GameControls) hasOpenPanels() bool {
|
||||
return g.isRightPanelOpen() || g.isLeftPanelOpen() || g.hud.skillSelectMenu.IsOpen()
|
||||
}
|
||||
|
||||
func (g *GameControls) clearScreen() {
|
||||
g.clearRightScreenSide()
|
||||
g.clearLeftScreenSide()
|
||||
@ -618,8 +614,9 @@ func (g *GameControls) clearScreen() {
|
||||
func (g *GameControls) openLeftPanel(panel Panel) {
|
||||
if !g.HelpOverlay.IsOpen() {
|
||||
isOpen := panel.IsOpen()
|
||||
fmt.Println(isOpen)
|
||||
|
||||
g.clearLeftScreenSide()
|
||||
|
||||
if !isOpen {
|
||||
panel.Open()
|
||||
g.hud.miniPanel.SetMovedRight(true)
|
||||
@ -631,8 +628,9 @@ func (g *GameControls) openLeftPanel(panel Panel) {
|
||||
func (g *GameControls) openRightPanel(panel Panel) {
|
||||
if !g.HelpOverlay.IsOpen() {
|
||||
isOpen := panel.IsOpen()
|
||||
fmt.Println(isOpen)
|
||||
|
||||
g.clearRightScreenSide()
|
||||
|
||||
if !isOpen {
|
||||
panel.Open()
|
||||
g.hud.miniPanel.SetMovedLeft(true)
|
||||
@ -666,6 +664,9 @@ func (g *GameControls) toggleQuestLog() {
|
||||
g.openLeftPanel(g.questLog)
|
||||
}
|
||||
|
||||
func (g *GameControls) onCloseQuestLog() {
|
||||
}
|
||||
|
||||
func (g *GameControls) toggleHelpOverlay() {
|
||||
if !g.isRightPanelOpen() || g.isLeftPanelOpen() {
|
||||
g.HelpOverlay.updateKeyMap(g.keyMap)
|
||||
@ -759,6 +760,10 @@ func (g *GameControls) isRightPanelOpen() bool {
|
||||
return g.inventory.IsOpen() || g.skilltree.IsOpen()
|
||||
}
|
||||
|
||||
func (g *GameControls) hasOpenPanels() bool {
|
||||
return g.isRightPanelOpen() || g.isLeftPanelOpen() || g.hud.skillSelectMenu.IsOpen()
|
||||
}
|
||||
|
||||
func (g *GameControls) isInActiveMenusRect(px, py int) bool {
|
||||
if g.bottomMenuRect.IsInRect(px, py) {
|
||||
return true
|
||||
|
Loading…
Reference in New Issue
Block a user