Quantcast
Viewing latest article 16
Browse Latest Browse All 115

make my jump anim complete before walk anim starts?

I basically want it so when I press space while holding w my jump animation plays fully then when its complete change back to walk animation, right now it starts the jump animation and then switches back to walk animation :( I'm a noob in need of assistance. Here's the code I'm using:`enter code here:(FYI it's a javascript) function Update(){ if(Input.GetKey("w")){ animation.CrossFade("walkanim2"); } if(Input.GetKeyUp("w")) { animation.CrossFade("animstop"); } //sidewalk 2 if(Input.GetKey("d")){ animation.CrossFade("sidewalkleft"); } //animation stop if(Input.GetKeyUp("d")) { animation.CrossFade("animstop"); } //sidewalk 1 if(Input.GetKey("a")){ animation.CrossFade("sidewalk"); } //animation stop if(Input.GetKeyUp("a")) { animation.CrossFade("animstop"); } //jumping animation if(Input.GetKey("space")) animation.CrossFade("jump"); }

Viewing latest article 16
Browse Latest Browse All 115

Trending Articles