Changeset View
Changeset View
Standalone View
Standalone View
binaries/data/mods/public/gui/session/minimap/MiniMapPanel.js
/** | /** | ||||
* This class is concerned with managing the different elements of the minimap panel. | * This class is concerned with managing the different elements of the minimap panel. | ||||
*/ | */ | ||||
class MiniMapPanel | class MiniMapPanel | ||||
{ | { | ||||
constructor(playerViewControl, diplomacyColors, idleWorkerClasses) | constructor(playerViewControl, diplomacyColors, idleWorkerClasses) | ||||
{ | { | ||||
this.diplomacyColorsButton = new MiniMapDiplomacyColorsButton(diplomacyColors); | this.diplomacyColorsButton = new MiniMapDiplomacyColorsButton(diplomacyColors); | ||||
this.idleWorkerButton = new MiniMapIdleWorkerButton(playerViewControl, idleWorkerClasses); | this.idleWorkerButton = new MiniMapIdleWorkerButton(playerViewControl, idleWorkerClasses); | ||||
this.flareButton = new MiniMapFlareButton(); | |||||
this.miniMap = new MiniMap(); | this.miniMap = new MiniMap(); | ||||
} | } | ||||
hotkeyActionCheck(target, selection) | |||||
{ | |||||
return this.flareButton.hotkeyActionCheck(target, selection); | |||||
} | |||||
preSelectedActionCheck(target, selection) | |||||
{ | |||||
return this.flareButton.preSelectedActionCheck(target, selection); | |||||
} | |||||
flare(target, playerID) | |||||
{ | |||||
return this.miniMap.flare(target, playerID); | |||||
} | |||||
isMouseOverMiniMap() | isMouseOverMiniMap() | ||||
{ | { | ||||
return this.miniMap.isMouseOverMiniMap(); | return this.miniMap.isMouseOverMiniMap(); | ||||
} | } | ||||
} | } |
Wildfire Games · Phabricator