UnityEvent NullReferenceException
Posted: Sat Aug 22, 2020 1:03 am
Hi,
I'm having a problem with UnityEvent after loading my prefab.
I have my prefab which has a class containing a Unity Event, I save the gameobject at runtime, but after loading the gameobject's Unityevent return NullReferenceException. A simple debug.log(theUnityEvent) also return "null".
The Event still show in the inspector (although it's invoke fields are gone, which is expected).
Any ideas what could be the reason?
I'm having a problem with UnityEvent after loading my prefab.
I have my prefab which has a class containing a Unity Event, I save the gameobject at runtime, but after loading the gameobject's Unityevent return NullReferenceException. A simple debug.log(theUnityEvent) also return "null".
The Event still show in the inspector (although it's invoke fields are gone, which is expected).
Any ideas what could be the reason?