Character controller running stop animation transition
For some reason I cant upload images or files, but here's a link to a GDrive folder with them Hello, hope you all doing ok! I've come to ask about this problem I have and I cant find a way to figure it out. Im trying to build a third person "open-wolrd-like" character controller using blend trees and specific animation motions. My goal is to achieve an Uncharted, MGS V, Death Stranding like character controller. So far I have idle animations, idle to walk and idle to run animations in -180, -135, -90, -45, 0, 45, 90, 135, 180 degrees directions, all merged using a blend tree, controlled by a script that gets the direcion the camera is facing, the direction the character is facing and the direction of the WASD/Axis input and it succesfully gets the desired angle to apply the corresponding animations in the blend tree. I have the magnitude of the input and I can use it to blend between animations for walking forward and running forward in another state. So far so good but noe the problem is that I cant figure out a way to exit the moving state (it contains a blend tree that blends between walking and running) to a running to stop state also, depending on the foot that was forward at the moment the transition should happen. I have the corresponding animations in their corresponding states, but I cant find a way to correctly trigger this transition. In most cases, input the magnitude is involved and turns out if fades back to 0 way too fast for the transition conditions to met. I've tried this:
If certain amount of input magnitude is reached, lets say 0.75 then the character is running, blending works OK.
If the above condition is met, start a coroutine that checks every 0.25 seconds if the input magnitude has changed from 0.75 to something below 0.25. If this condition is true, set an animator variable to trigger the transition from the moving state to the running stop state, there are two animations for this, stop with the left foot or with the right foot, which to use is controlled by a variable that does its job, so there is no problem with this.
There is a transition from moving state to moving start state controlled by the input magnitude and viceversa, this one works, if the input magnitude is greater than 0.1 then a moving start animation is blended and it blends from a moving start to a moving state, blending all the way from walking to running.
Tried with behaviours also, setting the coroutines on and off
And here is the problem: I can go slow or fast from idle to run, three states involved: idle, moving start and moving. I can ONLY go back from moving (walking or running blend tree) to idle or, heck, walking stop states (got them in place) if the input magnitude decreases slowly. BUT if the input magnitude is suddenly zero or lets say, 0.2, the state goes back to walking or idle, INSTEAD of triggering a running stop state, THIS IS THE PROBLEM. I've changed the priority of the transitions and tried with coroutines to check states or speeds, even tried using a locking variable, but no luck so far. Any help is greatly accepted, maybe the solution is obvious but I cant figure it our, maybe Im complicating stuff. Hope you can help, thanks in advance!
Your answer
Follow this Question
Related Questions
Blend Tree stuck at half way when controlled by curve 0 Answers
3rd person controller- anim parameters are not changing when i press stuff 0 Answers
According player movement to multiple cameras 0 Answers
How can I make character accelerate and deccelerate using GetAxis? 0 Answers
how do I get full diagonal animation weight with blend tree 0 Answers