i have an issue that i hope it's easy to resolve. I'm playing various animations in my libgdx-created game.
For a particular animation, i need that to play in loop mode but only if a particular condition is true. Simple this far.
What i need is to "reset" the animation (i mean restart from sprite n°1) when the condition become true again after the animation stopped. I know that i can simply dispose the actual animation and create another one every time the condition is true, but this seems a complicated way to resolve this..
How do i change the value of the index used by that animation? Is it possible? Do i have to create a class that extends the Animation class from libgdx library?