한국어English日本語简体中文繁體中文DeutschไทยTiếng ViệtРусскийPortuguês (Brasil)EspañolBahasa Indonesia

Game Lag White Paper › Netcode design

Pathfinding mismatch in command sync Command sync with divergent pathing

Cause ID sy-path-mismatch · Primary owner Game team (Server development) · Also Game team (Client development)

Open the interactive card with figures and simulations →

When only “go here” is exchanged and each side computes the path itself, even a small difference in the calculation sends a character or monster down a different path until it gets pulled back into place.

Why With click-to-move and monster chasing, only the destination is sent and the client computes the path on its own → Effect Differences in terrain data, collisions with other characters, or calculation order make it move along a different path from the server’s → On screen Monsters walk through walls and then snap to another spot, clicked characters change direction as if sliding

Symptoms
Teleporting, Rubber-banding
Factors
Latency
Who’s affected
Specific zone/channel, Just me
When
While moving or changing zones
Owner
Primary owner Game team (Server development) · Also Game team (Client development)
Game team action items
Server: send the path’s intermediate points (waypoints) as well, sync positions periodically. Client: converge smoothly when positions diverge, use the same terrain data as the server.
On the graph
Random spikes · Position correction count and distance per entity
Where to look
Per entity, the difference between the position the server sent and the position the client computed, with the coordinates of corrections plotted on the map. Periodically comparing checksums of both sides’ path results or positions pinpoints when they started to diverge
Confirmed if
Corrections cluster at specific terrain (ledges, narrow passages, slopes) or crowded spots and repeat at the same place even for players with normal network metrics
Ruled out if
Corrections happen only when loss or jitter spikes, regardless of place: connection problem. A single monster jumping on several players’ screens at once: check whether a slow client has control of the monster
Check with
Game server or client logs and metrics
Learn more
This approach is one reason click-to-move and tab-target games are less sensitive to ping. The trade-off is that nothing guarantees both sides get the same result, so a mechanism that syncs positions now and then is essential. Floating-point results can differ slightly depending on CPU type, compiler, and optimization settings (including debug versus release builds). In designs that exchange only inputs and assume both sides compute identical results, such as lockstep and rollback, these tiny differences can accumulate until the game state on the two screens splits apart (desync).

Sources

  1. Deterministic Lockstep Gaffer On Games
    Even if deterministic on the same machine, floating-point results can differ across compilers, OSes, and CPUs
  2. State Synchronization Gaffer On Games
    Sending state along with inputs keeps both sides in sync without perfect determinism
  3. Peeking into VALORANT's Netcode Riot Games
    Packet loss, or two characters trying to move to the same spot, makes server and client simulations diverge and need correction
  4. 1500 Archers on a 28.8: Network Programming in Age of Empires and Beyond Game Developer
    Tiny differences grow over time until a worker’s path drifts off; the world, entities, and pathfinding are compared by checksum to catch out-of-sync states
  5. Floating Point Determinism Gaffer On Games
    The same floating-point code can give different results depending on compiler, CPU architecture, and debug or release build; includes a case where AMD and Intel CPUs returned slightly different values from transcendental functions
  6. /fp (Specify floating-point behavior) Microsoft
    /fp:fast may reorder or combine floating-point operations and give results different from other /fp settings, and operations fused with FMA can also differ from a separate multiply and add

See also

Same layer: Netcode design

Same symptom (Teleporting), other layers

View the interactive card with figures and simulations