Quantcast
Channel: Questions in topic: "weight"
Viewing all articles
Browse latest Browse all 136

Animation layer problem

$
0
0
Hello Please can anyone help me cause i haven't found an issu for my problem. I have a rotate animation wich is supposed to be played when i rotate my player, but when i rotate my player the animation doesn't work and my idle animation continue to play like nothing happen. I have tried to make the rotate animation in layer1, but in this case the rotate animation replace the idle and i can't play any other animation Here is my code if(Input.GetButton("Horizontal")) { myTransform.Rotate(0, Input.GetAxis("Horizontal")*Time.deltaTime*speedRotation,0); if(animation.IsPlaying("idle")) { animation.CrossFade("rotation"); } } else { animation.CrossFade("idle"); } thank you PS: can anyone explain me the difference between the animation.weight and the animation.layer, i have read the documentation but i haven't understood yet

Viewing all articles
Browse latest Browse all 136

Trending Articles