Skip to content

Zone Runtime and Actor Model

Kurt edited this page Jul 9, 2026 · 5 revisions

Zone Runtime and Actor Model

Audience: Engine Developer Status: ✍️ Draft

The heart of the world server: each zone is a single-writer actor that owns its entities and processes operations serially. This eliminates in-zone locking, gives deterministic ordering, and is the unit of placement, handoff, and reload.

Intended contents

  • The single-writer invariant: one goroutine per zone owns all zone state; everything mutating a zone goes through its op queue (runOps cascade)
  • The op/command execution loop; how cross-entity effects fan out within a zone
  • Zone-owned entropy: the entropy-seeded, injectable RNG for reproducibility
  • Tick/heartbeat processing; scheduled work
  • Boundaries: what stays in-zone vs. what requires cross-zone/cross-shard coordination (→ handoff)
  • Reload and drain interactions at the zone level
  • Classes/algorithms/APIs: the zone actor type, op queue, tick loop
  • Mermaid: op-queue sequence diagram and zone lifecycle state diagram
  • Cross-links: Cross-Shard Handoff, Distributed Systems Model, Scoped Event Bus

Scaffold page — full content pending the wiki build-out.

Clone this wiki locally