Netcode measurements
Every netcode measurement: events at the touch, your ball’s pace, the clock mend, other balls, replay skip.
Every measurement behind Netcode, moved here from the devblog post Netcode: prediction and smoothing so the post stays short. Measured 13 to 16 Nov 2026 unless it says otherwise.
Measured how: the real room and the real page in one process on a virtual clock over a simulated link (35, 80 and 150 ms with 1 to 3% loss), replaying the live rooms’ tick timing; it counts corrections, kinks, drawn-touch-to-effect delay, events shown then undone (phantoms), and how evenly your ball steps per frame. That harness became the feel audit and the pre-deploy feel gate (docs/FEEL-GATE.md).
Modes, and what replaced them
- 10 Nov: a second mode where your keys take effect about half a ping later, when the server applies them, as the classic game does. 13 Nov the names settled (Classic: input delay; Instant: keys at once) and the default moved to Instant and back to Classic the same day.
- 15 Nov: Light for slow computers runs no physics and draws the server’s updates, replacing the old Off (everything a ping late plus a buffer). Key press to drawn frame at 40 ms ping: 127 ms on Off, 73 on Light (60.7 in a quiet one-rep check); Classic 40.2 to 42.2 (32.2 quiet). A once-only offer of Light after a slow game shipped with it.
- Replaced 16 Nov: Automatic is the default for everyone, Classic switching to Light only as Auto quality’s last step when prediction takes 12% or more of the time, the switch easing each ball over 250 ms. The Light offer is gone.
Guess only what nothing else can change
We moved bombs, grabs, caps and tags to the server’s word to stop events being shown then taken back. Phantoms went from 2 to 0 over 11 runs, and players felt the 67 to 150 ms wait within hours. What held up: guess an event only where nothing else can change it. A tag when both balls are near the last snapshot and closing fast; a bomb, grab or pickup when no other ball is within 1.5 tiles; your own Space press. A tag on you was guessed wrong 0.6% of the time on day one.
| What | Before | After |
| Pops after the touch | 67 to 150 ms after the drawn touch | One frame (17 ms) when sure; 0 wrong in about 120 guesses |
| A pop with the balls drawn apart | 1.9 to 7.3 px | Drawn meeting first: under 1.2 px |
| Bombs | Drawn stopped inside for 50 to 167 ms; flight 2 to 10% off | 0 ms stopped, flight within 0%; about 3% of guesses undone |
| Neutral flag handover | 83 to 133 ms after the pop, up to 300 | 0 ms, at most 17 |
| Grabs and caps | 25 / 50 / 87 ms after the server at 35 / 80 / 150 ms | At the touch when uncontested; no phantoms |
| Your ball through portals | 3 to 7 stutters per 5 trips | 0, speed kept |
| A key press running a frame back in time | Other balls kinked 265 to 1,000 times a minute | 0 to 0.4 |
| Two-tick skips after a server burst | 4 to 5 a minute at 15 ms, 33 ms each | Worst 0.09 of a tick |
| A spike switch you press | 100 to 250 ms late, often not at all | On its tick |
| Camera snapping to whole pixels | Uneven steps on 40 to 55% of frames, up to 0.9 px | 0 px at 60, 120 and 144 Hz |
| An early snap after a bomb | 63 to 68 snaps a minute | 0; a boost into a corner 9.1 px off to 0 |
| Two balls drawn holding one neutral flag | 169 to 300 frames a minute, runs of 20 | 0 |
Harness, 15 and 16 Nov 2026. Also fixed: blinks and swaps drawn at once, other balls through portals as one clean jump, pickups guessed when uncontested, your ball pulled back at a game’s end.
Most snaps were in our own drawing code: the drawn path ran back from where a bomb step ended; a guessed lock kept the replay from finding a portal trip; a tab back from the background counted a frozen ping as 512 ms and pushed the input lead from 4 ticks to 77. Each was a few lines, no bandwidth.
Other balls’ guessed events scale with how far the guess runs: a bomb shows only when the guessed place is inside the trigger by more than it could be off, 0.25 + 0.045 k² px at k ticks past the snapshot (0.8 px at 4, 2.9 at 8), the p99 of measured guesses. Of 40, 45 and 38 bombs at 35 / 80 / 150 ms, shown at the touch: 26 / 30 / 24 at the edge (1 / 0 / 1 taken back), 16 / 24 / 22 at a fixed 4 px, 19 / 23 / 18 with the uncertainty rule (0 taken back).
Your ball at an even pace
Live rooms tick late by a wandering amount and catch up in bursts, so the drawn moment, following the server clock estimate at 5%, gave slow motion then fast forward. Your ball is now drawn from a ring of its last 32 steps at a moment that runs at the tick rate and drifts toward the estimate by 1% (3% past 3 ticks off), never more than a tick ahead, restarting past 12 ticks off. On live timing the roll is 2 to 2.5 times steadier for 0 ms drawn latency at the median and 12 at p99.
| Your ball at steady speed, p99 step error, 144 Hz | Before the clock mend | After |
| Classic, 15 ms | 10.0% | 2.9% |
| Classic, 80 ms | 11.7% | 1.7% |
| Instant, 15 ms | 10.0% | 2.9% |
| Instant, 0 ms | 28.8%, 11 stutter frames a minute | 4.5%, 0 |
| Light, 15 ms | 14.5% | 7.4% |
| Trace lateness p50 / p95 | 90 / 170 ms | 36 / 88 ms |
Crisp is under 5%. Still over after the mend: Instant at 0 ms on 60 Hz (12.9%) and 150 ms ping (5 to 6%). The mend itself: Rooms on Cloudflare. Live after it: ticks 31 / 73 / 81 ms behind real time at p50 / p90 / p99 (before 55 / 195 at p50 / p99, and 5 / 20 with no bots, 52 / 193 with 4 v 4 Expert, 109 / 431 with 12 v 12), stalls over 40 ms 2.2 to 0.0 a minute (7 to 11 tick stalls a minute in the harness before); in emulation your step error 8.0 to 5.1%, jerks 7.9 to 0, corrections 3.2 to 0. A 4 v 4 room allocated 203 KB a tick, 73% of it bots.
| Clock mend round 3, replay | Jumps a minute | Bursts a minute |
| cf-ticks | 6.0 to 4.9 | 8.2 to 0 |
| cf-ticks with slow pings | 12.0 to 5.5 | 10.9 to 0 |
| cf-mend | 4.9 to 4.4 | 14.2 to 7.1 (the rest are in the trace) |
A lone slow ping no longer sets the on-time mark; a stall is repaid at 0.25 ms per ms (up to 0.5), at most one extra tick a wake. Cost: ticks over 40 ms late 2.1 to 4.0% on the synthetic trace. Live before: 6 to 24 jumps a minute per region, the clock 90 to 190 ms behind at p50. 36 of 39 jumps in 4 minutes with bots were our own tick work, 40 to 170 ms each, none over 15 ms in Node, 12 to 18% of those windows holding a game event.
Live, the six hours to the evening of 15 Nov: gaps over 100 ms between updates in the US fell to 1.3 a minute from 8.6 the day before; ticks ran 0.5 ms late at p99 and waited 0.05 ms for the machine.
Other balls: why they wobble
Snapshots carry every ball’s keys at their tick, so a guess covers only the ticks past the newest: 3 to 7 at p50, 6 to 16 at p99. Stepping other balls on the keys really pressed (an oracle no page has) drops wobble to 12 to 49 a minute and the error to about zero: half the wobble is wrong key guesses, the rest each correction swinging the drawn speed as it blends in. Day one’s clock and spring blend had already taken visible kinks at 80 ms with jitter and 1% loss from about 10 a minute per ball to 0.
| Guess for the ticks past the snapshot | 1 to 2 | 3 to 4 | 5 to 7 | 8 or more |
| Snapshot keys 2 ticks, then the recent push fading (kept) | 10% | 35% | 69% | 87% |
| Hold the snapshot’s keys | 10% | 22% | 28% | 36% |
| Infer keys from the speed change | 48 to 54% | 48 to 54% | 48 to 54% | 48 to 54% |
How often each guess is wrong, at 80 ms. Every rule that commits to keys halved the error at 150 ms but raised wobble 5 to 100%; after 12 ticks every rule lands within 0.3 px.
| Other balls drawn | Wobble | Jumps a minute | Gap at touches p95 | Error p50 |
| Where we guess they are now (kept) | 1x | 0 to 1.5 | 0.5 to 3.6 px | 0.3 to 2.4 px |
| Half or one snapshot in the past | 2 to 6x | 6 to 35 | 2.5 to 15 px | 3 to 11 px |
| Far enough back to cover late snapshots | 22 to 29 a minute | 0 | 7 to 26 px | 8 to 17 px |
Foundry, 4 v 4 bots, Classic; others ended 41 to 205 ms behind your ball. Half a snapshot back, the newest was late on 23 to 61% of frames. The gentle blend that shipped (corrections swing at most 2x a ball’s push): wobble at 35 / 80 / 150 ms 63 / 114 / 201 to 61 / 107 / 180, error p99 4.9 / 15.9 / 18.2 to 5.1 / 15.9 / 18.9 px. A middle swing halved wobble (52 / 77 / 117 to 28 / 39 / 62) but doubled error (5.6 / 6.7 / 9.9 to 9.9 / 11.4 / 23.2 px).
Skipping replays
When every ball and prop in an update matches prediction exactly, the rewind and replay are skipped: 96% of updates on Lab: Big, 76% on Lab: Gravity, 5% with bots at first. At 10x CPU slowdown the replay was 15 to 25 ms of a frame on lab maps. The first cut was off within the hour: it skipped past a portal coming back to life and past stale key guesses (portal-chain step error 2% to 66%). With bots, a differing guess now counts only for a ball that could reach yours before the drawn moment; other balls’ error moved 0.3 px or less at p99 (1.6 to 1.7 px at 35 ms, 5.8 to 5.5 at 150).
Tried and dropped
- 90 or 120 server ticks a second: no less jitter, 1.2 to 2 times the server cost.
- Easing the drawn moment more slowly, or a longer clock window: both worse.
- Pacing a Cloudflare room on real time from players’ pings: no better live (its own work was small: 8 Expert bots about 0.4 ms a tick).
- Holding a ball at a bomb until the server answers: an enemy’s bomb threw you 4 to 7 times the server’s step.
- Holding two balls at an unsure tag: 2 to 5 more kinks a minute after carrier pops.
- Holding key guesses at wall corners: 36 kinks either way over 16 games (10 near corners, 26 away), drawn error 297.19 against 296.89 px.
- A smooth tick timeline for everything (net5): step error p99 2.9 to 12.9% down to 0.9 to 2.1% on live traces, but 0 to 98 corrections a minute on the pre-mend trace where the server jumps 6 to 10 ticks.
- Every ball on the even timeline: other balls’ error p99 0.5 to 1.4 px smaller, but a layer change became a two-frame lurch; the feel gate caught it.
- UDP: Workers can’t receive it, and most late updates were stalled rooms, not lost packets.
- Small ones kept: lag warnings wait 3 s and come at most every 45 s; the first seconds after a join don’t count toward your ping; a guessed pickup is matched to the server’s by item and kind within 1 s.