You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Determinism tools for the core's types: canonical encoding, hash, version for saves #22
A game that replays or saves has to build its own determinism tools around the core: a canonical form of its state, a hash to compare two runs, and a version check so a save is not read by another version of the rules.
Found by the arena (#16): arena/src/sim/save.ts writes its own canonical JSON and FNV-1a digest, and stamps a save with the content hash and contractVersion() so a save from another contract is refused.
GGRS requires the game to handle save, load and advance requests and lets it attach a checksum to each saved state to detect desyncs (https://docs.rs/ggrs/latest/ggrs/).
For the core's own types (progress, rolled items, random states, a character sheet if #17 lands): a canonical encoding and a stable hash, and a version a save can carry.
Open — decided when this is picked up
Which types; whether the hash is part of the contract (stable across releases) or only within one version.
Relation to the existing native/WebAssembly determinism check.
Activity