-
- All Implemented Interfaces:
public enum BaseCommand.CommandContext
Represents what screen the player was on when they used the command.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CAMPAIGN_MAP
Command was entered on the campaign map.
CAMPAIGN_MARKET
Command was entered in a market.
COMBAT_CAMPAIGN
Command was entered during a battle in the campaign (doesn't include simulation battles).
COMBAT_MISSION
Command was entered during a mission.
COMBAT_SIMULATION
Command was entered during a refit simulation battle.
MAIN_MENU
Command was entered on the main menu.
-
Method Summary
Modifier and Type Method Description boolean
isInCombat()
Returns whether this context is on the combat map. boolean
isInCampaign()
Returns whether this context is on the campaign map. boolean
isInMarket()
Returns whether the player is interacting with a market-containing entity. boolean
isInMainMenu()
Returns whether the player is viewing the main menu. boolean
isCampaignAccessible()
Returns whether the player is in campaign mode, including in campaign battles (even refit simulation battles). SectorEntityToken
getEntityInteractedWith()
Returns the SectorEntityToken the player is in a dialog with, if any. MarketAPI
getMarket()
Returns the MarketAPI of the ) the player is in a dialog with, if any. static Array<BaseCommand.CommandContext>
values()
static BaseCommand.CommandContext
valueOf(String name)
-
-
Method Detail
-
isInCombat
boolean isInCombat()
Returns whether this context is on the combat map.
-
isInCampaign
boolean isInCampaign()
Returns whether this context is on the campaign map.
-
isInMarket
boolean isInMarket()
Returns whether the player is interacting with a market-containing entity.
-
isInMainMenu
boolean isInMainMenu()
Returns whether the player is viewing the main menu.
-
isCampaignAccessible
boolean isCampaignAccessible()
Returns whether the player is in campaign mode, including in campaign battles (even refit simulation battles).
-
getEntityInteractedWith
@Nullable() SectorEntityToken getEntityInteractedWith()
Returns the SectorEntityToken the player is in a dialog with, if any.
-
getMarket
@Nullable() MarketAPI getMarket()
Returns the MarketAPI of the ) the player is in a dialog with, if any. { } of the { } the player is currently in dialog with, or { null } if they are not in a dialog with a market-containing entity.
-
values
static Array<BaseCommand.CommandContext> values()
-
valueOf
static BaseCommand.CommandContext valueOf(String name)
-
-
-
-