I’ve created an animation in the Animator with a couple of states (walking and idle). I have a boolean parameter called isWalking
which triggers the transitions between the idle
and walking
states.
However, when I set isWalking
to true, it waits until the idle
animation is finished before transitioning to the walking animation. I want it to begin the transition as soon as isWalking
is set to true.
Is there anyway I can make transitions activate immediately instead of waiting for the current animation to finish?
Edit:
As requested, here is the code:
if (GetComponent<CharacterPhysics>().IsWalking())
{
GetComponentInChildren<Animator>().SetBool("isWalking", true);
}
else
{
GetComponentInChildren<Animator>().SetBool("isWalking", false);
}
However, I’m not sure how relevant the code is because I can see the value being changed properly in the Animator window, but it waits until the current animation is finished before transitioning (instead of transitioning as soon as the conditions for the transition are set)