I have a GameObject with a “floating” animation that consists of moving vertically up and down. I want to make the object rotate 360 degrees (once) on key press, for which I have another animation “rotation”.
I configured the default layer on the Animator, and play the animation on c# on key press. However, when the object finishes rotating, it restarts the “idle” animation from y=0, which I don’t want.
How do I make the gameobject to keep floating and do the 360 rotation without restarting the idle animation.