Runs one command through the rule, commits the resulting state, and charges its cost to the scheduler's current actor when one is given.
Restores the next checkpoint after an undo, or null when no redo is available.
Restores the previous committed simulation checkpoint, or null when undo is disabled.
StaticrestoreRebuilds a runtime from a snapshot taken by snapshot(). The caller supplies
actorOf to resolve the scheduler's ids back to live actor objects, the same way
Scheduler.restore does - the runtime has no identity primitive of its own to lean on.
A small facade over one state + one scheduler + one RNG, for the interactive half of a turn-based simulation: the command a player just issued, dispatched through the game's own rule.
advanceToInput/runScenario(simulation/Turns.ts/Scenario.ts) still cover the automatic-actor loop and fixed-command replay respectively; a game composes both against the sameschedulerrather than choosing one over the other.Example