When trying to load a save after implementing this code, I get a null reference error.
The error points to these line:
var overrideController = animator.runtimeAnimatorController as AnimatorOverrideController;
if (animatorOverride != null)
{
animator.runtimeAnimatorController = animatorOverride;
}
else if (overrideController != null)
{
animator.runtimeAnimatorController = overrideController.runtimeAnimatorController;
}
Error:
RPG.Combat.Weapon.Spawn (UnityEngine.Transform rightHand, UnityEngine.Transform leftHand, UnityEngine.Animator animator) (at Assets/Scripts/Combat/Weapon.cs:34)
So as it is, saving is broken for me, and I haven’t any clue about how to fix it.
Annoyingly too, my scene transition is broken, but that is another issue for later.