Open BenHamrick opened 3 months ago
@BenHamrick That does indeed look like it makes sense... half RTT vs 1 full RTT for the delta time adjustment. Running some tests against this, but so far it looks like that would be a welcome contribution. 👍
@NoelStephensUnity I am really glad to hear that! We are using the tick in our own custom physics engine to do predictive rollback on the server and client. I have been so confused for a long time about why the tick is not in sync between the client and the server. We even started to write our own syncing system that worked around this problem like people are in this thread: https://discussions.unity.com/t/network-messaging-latencies-very-high/912504/2 . I probably spent more than 40 hours trying to work around the issue by dynamically changing the NetworkManager.NetworkTimeSystem.LocalBufferSec
Btw to figure this problem out I used the relay server with 2 instances of unity running on the same machine. Then I was able to use local epoch time to see if each of the ticks are in sync between the server and client. They where not!
@NoelStephensUnity how long does it take to merge and backport a simple change like this?
When syncing the local time from the server to the client we need to use half the RTT time to get the local time in sync with the server. Otherwise the local time drifts relative to how long the RTT time is.
Changelog
Testing and Documentation