As you saw from the title my problem is that i have like 5-7 animations and they dont work when im standing still…for example i got a wave animation which works fine when im moving but when im not it just doesnt play…i notice a slight movement but it doesnt play as it normally should.Also it would be great to now how can i have several animations playing at the same time(e.g shoot and walk). Here is my script
function Update(){
//Plays Run Animation
if(Input.GetKeyDown(KeyCode.LeftShift)){
animation.Play("Sprint");
}
//Plays Walk Animation
if(Input.GetKeyDown(KeyCode.W)){
animation.Play("Walk");
}
//Plays Shoot Animation
if(Input.GetMouseButtonDown(1)){
animation.Play("Shoot");
}
//Plays Wave Animation
if(Input.GetKeyDown(KeyCode.M)){
animation.Play("Wave");
}
//Plays Crouch Animation
if(Input.GetKeyDown(KeyCode.Space)){
animation.Play("Jump");
}
//Plays walk(strafe left) animation
if(Input.GetKeyDown(KeyCode.A)){
animation.Play("Walk");
}
//Plays walk(strafe right) animation
if(Input.GetKeyDown(KeyCode.D)){
animation.Play("Walk");
}
}
I also got a seperate script for the idle animation:
function Update(){
if (Mathf.Abs(Input.GetAxis(“Vertical”)) <= 0.1){
animation.CrossFade(“Idle”);
}
}