Files

13 lines
639 B
Markdown

# Shared protocol
`city.proto` defines WebSocket messages, city generation jobs and room snapshots.
Run `npm run proto:generate` to regenerate the committed TypeScript bindings.
Rust bindings are generated by Cargo using a vendored protoc executable.
Handshake protocol version is 1. Positions are signed centimetres and resident
IDs are uint32. Snapshots replace the AOI; deltas use absolute changed values
so intermediate ticks can be coalesced. New fields must be additive; never
reuse field numbers. An incompatible save version is rejected explicitly.
Static city format v1 uses JSON + gzip, independently of the network protocol.