By: Michael Lynch <git@mtlynch.io>
Predict the local player between snapshots Rendering the local sprite only from server snapshots meant its position stepped at 20 Hz, and no client-side movement filled the frames between. The walk read as choppy compared to the client-only version on master. The sprite now runs on an Arcade Physics body driven by input velocity, so motion integrates at Phaser's fixed step. Server snapshots stash the divergence as a decaying correction rather than teleporting the sprite. Correction is only applied on axes the player isn't actively driving — on a driven axis the gap is expected RTT-worth of lag, and consuming it would visibly slow the sprite below its intended speed. The one architectural cost is that PLAYER_SPEED now lives on both sides of the wire again; a comment in game-scene.ts calls out the pairing with state.ex. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
| Time to Start | Worker time | Duration | Time to finish | |
| Config | 2s | 17s | 17s | 20s |
| Eval | 13s | 38s | 38s | 51s |
| Build | 36s | 4m51s | 1m38s | 2m14s |
| Suite | 2s | 5m47s | 2m12s | 2m14s |