Game object

State

JSON-compatible data only: no functions, canvases or connections. init and step have no side effects and never mutate the previous state.

Time

step runs at 60Hz, dt = 1/60.

ValueMeaning
world.timeseconds from completed ticks
world.tickcompleted ticks
world.seedseed, default 1
world.capssave / shared / room / ai, all false

Player (standalone HTML only)

One player per canvas. Call stop() before removing the canvas.

Headless

Same seed and inputs give the same result.