Hey!
Recently I got this error when playing Spine animation which happens every frame:
ArithmeticException: Function does not accept floating point Not-a-Number values.
at System.Math.Sign (System.Single value) [0x00028] in <2b3a3162be434770b7a4fac8b896e90c>:0
at Spine.AnimationState.ApplyRotateTimeline (Spine.RotateTimeline timeline, Spine.Skeleton skeleton, System.Single time, System.Single alpha, Spine.MixBlend blend, System.Single[] timelinesRotation, System.Int32 i, System.Boolean firstFrame) [0x0017a] in <235d56ff74434cbc92c60912dbb8d9f4>:0
at Spine.AnimationState.Apply (Spine.Skeleton skeleton) [0x0025a] in <235d56ff74434cbc92c60912dbb8d9f4>:0
at Spine.Unity.SkeletonAnimation.ApplyAnimation () [0x0002b] in <4498d6c5ece742429fe17167eb56a8b8>:0
at Spine.Unity.SkeletonAnimation.Update (System.Single deltaTime) [0x0005c] in <4498d6c5ece742429fe17167eb56a8b8>:0
at Spine.Unity.SkeletonAnimation.Update () [0x00028] in <4498d6c5ece742429fe17167eb56a8b8>:0
I have a bumper that has idle animation on layer 0.
Also it has a "push_middle" animation on layer 1. It plays one time after the bumper is being hit by something. The animation only has it's position animated and not rotation. Alpha of this layer depends on the git strength.
Also on layer 2 I have "push_left" and "push_right" animations that play if the bumper is being hit on one of the edges. These animations only apply rotation. The alpha on this layer is affected by strength and angle of the hit.
Strength is clamped between 0.1 and 2, and angle is clamped between 0 and 1.
Very rarely the bumper gets hit and dissappears as if it was hit way too hard and got pushed into a stratosphere. And after that this error pops up every frame.
I understand there's some issue in my code but the bug is very hard to reproduce. So maybe someone could give me a hint of what could possibly causing that error.