Vixen
02b45cc4
csharp
public readonly record struct TickRebase

Two realms' clocks, and the offset between them.

Read the guide page for this →

Remarks

Doc 27 § Tick rebasing: A and B run independent clocks and the two are not related. This is the whole of the relationship — an offset, measured during the overlap, applied at the switch.

⚠ What cannot be carried over is stated rather than hidden: the prediction history is cleared, the input log is cleared and re-armed from the target's first snapshot, and the snapshot buffers are dropped. So the visible cost is one interpolation delay of extra smoothing and one prediction reset — roughly 100–150 ms of softer local response, once, at a moment the player initiated.

Fields and properties (5)

  • public long SourceTick

    Where the source was.

  • public long TargetTick

    Where the target was at the same moment.

  • public static TickRebase None

    No rebase.

  • public long Offset

    What to add to a source tick to get a target tick.

  • public bool IsValid

    Whether there is one.

Methods (3)

  • public TickRebase(long SourceTick, long TargetTick)

    Two realms' clocks, and the offset between them.

  • public long ToTarget(long tick)

    Converts a tick on the source's clock to the target's.

  • public override string ToString()

    Returns the fully qualified type name of this instance.

Used by (2)

  • ClientTransferVixen.Live.Transfer
  • ClientTransferTestsVixen.Live.Transfer.Tests