Ok i think unlike the last thread I made this isn’t just a personal oversight. Since updating to 5.2 network animators not longer appear to work and just generate the following NRE over and over.
NullReferenceException: Object reference not set to an instance of an object
UnityEngine.Networking.NetworkSystem.AnimationParametersMessage.Serialize (UnityEngine.Networking.NetworkWriter writer) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/Messages.cs:413)
UnityEngine.Networking.LocalClient.InvokeHandlerOnClient (Int16 msgType, UnityEngine.Networking.MessageBase msg, Int32 channelId) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/LocalClient.cs:160)
UnityEngine.Networking.ULocalConnectionToClient.Send (Int16 msgType, UnityEngine.Networking.MessageBase msg) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/LocalConnections.cs:24)
UnityEngine.Networking.NetworkServer.SendToReady (UnityEngine.GameObject contextObj, Int16 msgType, UnityEngine.Networking.MessageBase msg) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/NetworkServer.cs:356)
UnityEngine.Networking.NetworkAnimator.OnAnimationParametersServerMessage (UnityEngine.Networking.NetworkMessage netMsg) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/NetworkAnimator.cs:400)
UnityEngine.Networking.NetworkConnection.InvokeHandler (Int16 msgType, UnityEngine.Networking.NetworkReader reader, Int32 channelId) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/NetworkConnection.cs:183)
UnityEngine.Networking.NetworkServer.InvokeHandlerOnServer (UnityEngine.Networking.ULocalConnectionToServer conn, Int16 msgType, UnityEngine.Networking.MessageBase msg, Int32 channelId) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/NetworkServer.cs:1643)
UnityEngine.Networking.ULocalConnectionToServer.Send (Int16 msgType, UnityEngine.Networking.MessageBase msg) (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/LocalConnections.cs:83)
UnityEngine.Networking.NetworkAnimator.CheckSendRate () (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/NetworkAnimator.cs:177)
UnityEngine.Networking.NetworkAnimator.FixedUpdate () (at /Users/builduser/buildslave/unity/build/Extensions/Networking/Runtime/NetworkAnimator.cs:96)
The animations play as expected on the local machine, they just don’t appear to pass over the network. Oddly even placing a NetworkAnimator on an object and scrolling the inspector will cause the console to explode with the following warning
Animator does not have an AnimatorController
UnityEditor.DockArea:OnGUI()
Removing the network animator appears to cause that error to go away. I did manually drag the objects local animator component into the NetworkAnimator field so I would figure that it should have the reference that it’s seeking. Thanks so much for any help!
Checked back in 5.1.1 and everything still seems to work as expected.