Search Unity

Question Value of interpolation delay in NetworkTransform

Discussion in 'Netcode for GameObjects' started by CosmoM, May 18, 2022.

  1. CosmoM

    CosmoM

    Joined:
    Oct 31, 2015
    Posts:
    204
    My NPCs walk about with a certain pattern. They have NetworkTransforms with interpolation switched on. Because of this, there is an offset between their animation state and their positional changes, that is not there without interpolation. I can compensate for this by a one-time offset in their animation time, except that to do this I need to know the extra delay introduced by the NetworkTransform's interpolation buffering, and I can't quite figure out exactly how long that delay is. Does anyone know?

    EDIT: If I read the code correctly, the delay is just one server tick, but that seems an underestimation in practice.
     
    Last edited: May 18, 2022