Hi there, Xcuse my english...
My character walk loop animation is strange, at the end of each loop it is tacking a stop before going ahead again... sort of stand by...
it is not a problem of having the same frame at the start and at the end ( the stop is to long for that).
and if i play the loop in the animation window it is perfect.
that is the code i wrote to make the caracter go forward :
if (controller.isGrounded){
moveDirection=Vector3(0,0,Input.GetAxis("Vertical"));
moveDirection=transform.TransformDirection(moveDirection);
moveDirection*=speed;
and that is the code to display the walk animation loop:
if (Input.GetAxis("Vertical") && controller.isGrounded){
figurine.animation.CrossFade("walk");
}else
{
figurine.animation.CrossFade("idle");
}
so i tried to change `CrossFade` in to `Play` but it does not solve the problem...
Any light??
Thank you.
↧