Hi,
I just started making a game project with Unity Engine. When I add walking and idling scripts to my character, everything seems alright. But when I test it, if I press the key for moving forward, my character will slide for few second before walking. While sliding, it is moving to the direction I desire to, but I am not sure what is causing the delay of the walking behavior. Thank you.
Maybe there are too many lines between the method that checks if it is walking and the animation. For example, you could have
_
if (walking == true)
{
if(movingForwards=true)
{
Play(audio.GetComponent);
//Finally you do the animation
}
}
Also if it is in the update function the update may be slow. To test this do Fixed Update not update.
Hope This Helps!