Two players in an online encounter do not see the same moment at the same instant. A shot that looks accurate to the attacker can arrive after the defender believes they reached cover. Lag compensation chooses how to adjudicate that disagreement. Treat it as an explicit fairness policy with technical constraints, rather than a hidden networking feature expected to make every perspective simultaneously correct.

Choose the actions that need historical evaluation

Different actions require different timing models. A precise hitscan weapon may benefit from evaluating a recent historical target position, while a slow projectile can remain an object simulated through the world. Area attacks, shields and moving cover add further questions about which state belongs to the evaluated moment.

Write examples before selecting implementation details. If a defender raises a shield just before an incoming shot reaches the authority, should the shield count? What if a door closes between the attacker and the target? There is no universally satisfying answer, but inconsistent answers across similar abilities are especially confusing. A shared combat timing document helps designers expose contradictions early.

Bound the amount of history

Keeping history does not imply accepting any client-provided time. Requests need a credible relationship to the server's timeline and the connection's observed behavior. Define a limited historical window and a consistent rule for requests outside it. Excessive forgiveness for one participant can make another participant's successful escape feel meaningless.

A cap is a product tradeoff, not a promise that all players below it receive identical experience. Review actual connection distributions and the intended audience. Where conditions exceed the game's supported envelope, provide clear connection feedback and sensible matchmaking options. Avoid silently expanding historical evaluation until slow connections can repeatedly defeat actions that appeared complete to everyone else.

Build tools that compare perspectives

A useful combat trace shows the attacker's presented view, the defender's presented view and the authority's evaluated state. Include timestamps, relevant collision shapes and the final reason for acceptance or rejection. A video from one client alone rarely explains a disputed hit because it omits the other timeline.

Create a small set of recognizable scenarios: crossing a doorway, ducking behind cover, raising a shield and exchanging simultaneous attacks. Run them under controlled delay and jitter. Ask testers whether the outcome is understandable before asking whether it feels favorable. Players can tolerate losing an encounter more readily when the rules seem consistent and the feedback explains what happened.

Align feedback with the confirmed result

Local impact effects should not imply certainty when confirmation is still pending. A distinct confirmed hit marker can separate an apparent intersection from an approved damage event. Keep that distinction subtle enough for fast play, but consistent across weapons and abilities. Spectator and replay views should also identify which timeline they reconstruct.

Before release, document the supported timing envelope, exceptions for particular mechanics and the metrics that might justify revisiting the policy. Review complaints alongside traces rather than adjusting rules from isolated clips. The goal is a stable compromise between responsiveness and defensible outcomes, supported by enough evidence to explain changes when the combat model evolves.

TAKE IT FORWARD

The key decisions.

  • Write contested combat examples before implementing rewind rules.
  • Bound historical evaluation and validate request timing.
  • Compare attacker, defender and authoritative views during testing.

Sources & further reading

Primary references for the concepts discussed. Check the applicable documentation when planning implementation.

  1. Epic Games: network emulation