Battle Handle
Handle for an in-progress asynchronous battle.
Provides typed event access for real-time observation and control methods for battle management. Obtain via BattleRunner.startBattleAsync.
Must be closed when the battle is done to release bot processes and allow subsequent battles on the same BattleRunner.
Properties
Fires periodically (every 500 ms) and on every BotListUpdate during the boot phase, reporting how many bots have connected versus how many are expected.
Fires when the connected bot list changes.
Fires when the game is aborted.
Fires when the game ends with final results.
Fires when the game is paused.
Fires when the game resumes from pause.
Fires when the game starts (all bots ready).
Fires when a round ends.
Fires when a new round begins.
Fires on each game tick with full observer state.
Server features advertised during the handshake. Available immediately after the battle handle is obtained from BattleRunner.startBattleAsync.
Functions
Blocks until the battle completes and returns structured results.
Takes the server out of debug mode, returning to normal auto-advancing. Equivalent to calling resume, which also implicitly disables debug mode.
Puts the server into debug mode: after each turn is processed the server pauses and waits for nextTurn before advancing. Use disableDebugMode or resume to exit.
Sends a bot-policy-update for the given bot.