Log inGet started
World

Ironspine

Branchmain
Branchesmain
Commit9a7cce6233

README.md

game/live.module

The one table the running game keeps across a hot reload.

Editing a module re-evaluates every module that depends on it. game.game and game.boot are therefore re-run many times in a working session, and anything they held in a module-local table would be replaced by an empty one while the entities the slices built are still standing in the scene — the phase, the blackboard, the event listeners, the hold registry and the record of which slices are built, all quietly reset, with the game still looking correct and no longer moving.

live.module depends on nothing, so nothing re-evaluates it, so the tables it hands out are the same tables for the whole session.

It holds no logic. Anything with behaviour would have to change eventually, and the moment it changed it would stop being durable.

Used by

  • game/game.module — Game itself, Game.state, the event bus, the hold registry, the part list.
  • game/boot.module — which slices are built, their module tables, their root entities.