• RuntimesUnity
  • How can I tell if the animation is playing

I try to use the following code to determine:
AnimationState.GetCurrent(track);
But when the animation is finished, he can still get it, and it should not be in the playing state after the playback is finished.
If I use the following method to determine:
AnimationState.GetCurrent(track).IsComplete
So if you stop the loop animation in the middle, it gets the wrong result
I want to know how to accurately get if the animation is playing, no start or stop playing or finish playing is False, only when playing is True

Related Discussions
...

An animation played on an AnimationState track does not get automatically removed from the track. It continues being applied until you remove it. See here for how it works and how to remove it:
http://esotericsoftware.com/spine-applying-animations#Empty-animations

Checking GetCurrent(track) == null or GetCurrent(track).IsComplete == true will tell you if there is not animation or if the animation has completed at least one loop. If that doesn't work for you, please explain what you mean by "wrong result".