Net-sync — deterministic multiplayer

net-sync makes multiplayer by sending inputs, not state. Because the whole stage is a pure function of seed + inputs + ticks, two machines fed the same inputs produce the same frames — so you exchange only the tiny input stream, and lockstep or rollback keeps them in sync. This is the payoff the determinism contract quietly unlocks, and the family's most ambitious sibling.

Status: design — the horizon. Not built yet, and a serious undertaking; documented as the target the determinism design aims at.


What it makes possible

Ordinary multiplayer syncs game state — positions, velocities, everything — which is bandwidth-heavy and drifts. If the simulation is deterministic, you can instead sync only inputs: every machine runs the identical simulation from the same seed and the same per-tick input snapshots, and arrives — tick for tick — at the same state. This family is built to be exactly that deterministic, so input-sync is not a stretch; it is the natural conclusion.

Lockstep

The simple form: each tick, exchange every player's inputs, and advance only once all inputs for that tick are in. Perfectly in sync and trivially correct — but latency-bound, since everyone advances at the pace of the slowest link. Good for turn-ish or LAN play.

Rollback

The responsive form (GGPO-style): predict remote inputs and advance immediately, so local play never stalls; when the real remote inputs arrive and differ from the prediction, roll back to that tick and re-simulate forward with the correct inputs. It hides latency, and it is only possible because re-simulation is deterministic and cheap — the modern standard for fighting games.

Why only a deterministic family can do this

Rollback requires three things most engines can't offer: save-state, restore, and deterministic re-simulation. Here they all exist or nearly do — stage.tick steps deterministically, input record/replay is the input stream, and the seeded PRNG plus the fixed phase order make re-simulation exact. Net-sync needs just one more stage capability — snapshot and restore the whole sim state at a tick — and rollback falls out.

On the stage

net-sync wraps the tick: it gathers local + remote inputs, and either advances in lockstep, or predicts, snapshots, advances, and on a misprediction restores and re-simulates — all through stage.tick and the snapshot API. It writes no game state itself; it only drives the deterministic core with the right inputs at the right ticks.

Clients

  • Luau — require("netsync"): start a session (lockstep or rollback), feed local input, read link stats.

Related

Important: The Ant64 family of home computers are at early design/prototype stage, everything you see here is subject to change.