Unity-Technologies / com.unity.netcode.gameobjects

Netcode for GameObjects is a high-level netcode SDK that provides networking capabilities to GameObject/MonoBehaviour workflows within Unity and sits on top of underlying transport layer.
MIT License
2.1k stars 430 forks source link

NetworkRigidbody is not checking for NetworkTransform.Interpolate value on ownership change #2836

Closed kevincastejon closed 2 months ago

kevincastejon commented 3 months ago

Description

NetworkRigidbody is not checking for NetworkTransform.Interpolate value on ownership loss as it does on Awake, so it assumes that the NetworkTransform will treat the interpolation even if NetworkTransform.Interpolate is false.

Environment

Additional Context

Solution to fix : m_Rigidbody.interpolation = m_IsAuthority ? m_OriginalInterpolation : (m_NetworkTransform.Interpolate ? RigidbodyInterpolation.None : m_OriginalInterpolation);

NoelStephensUnity commented 2 months ago

Resolved in #2838

kevincastejon commented 2 months ago

you're welcome

NoelStephensUnity commented 2 months ago

you're welcome @kevincastejon

I apologize for not looking at the PR and that the author used your suggested fix. 😞

Thank you for your suggested fix! 👍