-
Notifications
You must be signed in to change notification settings - Fork 457
Description
Description
I've mentioned this issue here briefly: #2549 (comment)
When the ownership of a NetworkObject
with a ClientNetworkTransform
is changed during movement, the object jumps to a previous position for maybe one frame. It jumps back to its expected position immediately. This only happens with half precision.
I am aware that the ownership change cannot be totally smooth during movement without interpolation due to the network delay.
Reproduce Steps
- Start a host and a client instance of the attached project.
- The moving object in the scene changes ownership every second.
- Observe the movement during ownership change
In case that's relevant: I am using a symlinked copy of the Unity project for multiplayer testing and have only tested in the editor play mode.
netcode-issue-networktransform-returnownership.zip
Actual Outcome
The object is in an earlier, wrong position for a frame during ownership changes.
Does not happen with full precision on the ClientNetworkTransform
.
Expected Outcome
It should behave just like with full precision enabled. Just a short hiccup during ownership change due to network delay, but without the one frame flicker.
Environment
- OS: Windows 10
- Unity Version: 2021.3.24f1
- Netcode Version: 1.5.1 (but also tested with develop branch, same behaviour)
Additional Context
Possible workarounds: disable half precision, enable interpolation, don't change ownership during movement
This is not an urgent requirement for my project, I just noticed it by accident because I had interpolation disabled due to another issue in the past.