- Home /
Instant animation transition
So, yeah, I've lost like two hours trying to figure out how to make instant transitions between animations. I know unchecking Has Exit Time should do the trick, but for some reason it doesn't. I run the game, and looked at the animator window, and you can clearly see that "Run" animation always plays till the end before going to "Idle", even though there is no input. In other words, even when the character stands still, the "Run" animation plays till the end and only then it transition back to idle. Even stranger is that the opposite, for some reason, works rather nice (Idle to Run). So, I have 0 idea why this is happening, and while I wait for answers here, I'll just start a new project and hope it was a bug.
Did you ever find the answer? I have the same problem. Animations always run their full course before reacting to a change in values. I have the transition time set to 0 and I unchecked 'has exit time'. In my console I can see that the value DOES change so it really is the animation that insists on playing all keyframes before exiting.
That's odd. $$anonymous$$y problem was that I used Input.GetAxis ins$$anonymous$$d of GetAxisRaw - it just looked like it was looping the whole thing, ins$$anonymous$$d, it just needed time to get back to zero. Haven't messed with animations a lot since then, so, sadly, I can't give you any useful advice. :(
Thanks! I wanted to achieve the same and disabling "Has Exit Time" already solved this for me. :)
Answer by Thaun_ · Jan 05, 2018 at 04:58 PM
Use these settings:
Has Exit Time: False
Fixed Duration: False
Transition Duration: 0
Transition Offset: 0

Thank you! In addition I had to disable "Can Transition To Self" or else my animations wouldn't play.
This messes up the initial animation, not interrupts it.
Answer by meat5000 · Feb 20, 2016 at 10:09 AM
I'll just start a new project
How can this ever be the answer? :D
Click on the transition arrow and note the Blue arrow sliders above the blue bar. Adjust them so they are close together, thus making the transition small.
Well, cuz I suspect it might be my computer that is bugging. :D Yeah, I've done that, and I still get a quarter of a second delay. Strange thing is (and maybe hopefully useful) that if I press 'd' for just a second (or in a quick transition), it works fine. But if I move longer (pressing key longer), then the problem appears. Again, maybe, it's something with my computer or I don't know... It isn't that big of a deal, I guess, but it's annoying, because everything else works fine. :D
Hey, I just wanted to let you know I found what was the problem. I was using GetAxis for input for movement, so I thought that maybe the problem was in the fact that it takes some time for the value to drop to zero, which would explain why Idle -> Run works well, but opposite is not (float speed, which I use for transitions rises above 0 as soon as input starts, but takes some time to reach 0 again afterwards). So, just simply using GetAxisRaw solved the problem and now works fine. :)
In my case, the transition time is 0 and I unchecked "has exit time", but the animation still plays all keyframes before switching to a different state.
Answer by OfficialHermie · Apr 13, 2020 at 09:08 PM
If you simply want to test an animation by looping it endlessly, add the same animation to a animator twice. Then connect them. Click each connection, then use these settings:
HasExitTime = True (else, the transition only works if we use Parameters like IsWalking, which is not what I want in this case)
Exit Time = 1
FixedDuration = True
Transition Duration (s) = 0
Transition Offset = 0
Answer by $$anonymous$$ · Nov 24, 2018 at 03:00 AM
can't read your question, you should give a picture
Your answer