Checks if the current mode matches the target mode.
The target mode.
True if the current mode matches the target mode, otherwise false.
Adds an action to be executed on the next prompt.
The target phase.
The mode to wait for.
The callback to execute.
Optional
expireFn: (() => void)Optional function to determine if the prompt has expired.
Runs the game to the summon phase.
Optional
species: Species[]Optional array of species to summon.
A promise that resolves when the summon phase is reached.
Sets the game mode.
The mode to set.
Transitions to the start of a battle.
Optional
species: Species[]Optional array of species to start the battle with.
A promise that resolves when the battle is started.
Transition to the next upcoming CommandPhase
Emulate selecting a modifier (item) and transition to the next upcoming CommandPhase
Waits until the specified mode is set.
The mode to wait for.
A promise that resolves when the mode is set.
Class to manage the game state and transitions between phases.