After upgrading my project, network variables have completely broken.
I have tested in the project with this simple test script:
public class NetworkVariableTester : MonoBehaviour
{
NetworkVariable<float> floatVariable = new();
private void Update()
{
floatVariable.Value = Time.time;
}
}
This throws the following error on every frame:
NullReferenceException: Object reference not set to an instance of an object
Unity.Netcode.NetworkVariable`1[T].set_Value (T value) (at Library/PackageCache/com.unity.netcode.gameobjects@1.1.0/Runtime/NetworkVariable/NetworkVariable.cs:53)
NetworkVariableTester.Update () (at Assets/NetworkVariableTester.cs:12)
This error seems to come from the NetworkVariableSerialization system that was added in 1.1.0. I'm not sure why it is broken in my project and no other users seem to be reporting errors. Any help would be appreciated as the project is completely unusable until this is fixed.
After upgrading my project, network variables have completely broken.
I have tested in the project with this simple test script:
This throws the following error on every frame:
This error seems to come from the NetworkVariableSerialization system that was added in 1.1.0. I'm not sure why it is broken in my project and no other users seem to be reporting errors. Any help would be appreciated as the project is completely unusable until this is fixed.