- Home /
animation on key press problem
im trying to play an animation when i press space, but when i start the game it just starts and loops the animation...the wrap mode is at once and Play Auto is off...here is the script im using.`
function Start () {
}
function Update () { if(Input.GetButtonDown("Jump")); animation.Play("engines landingtakingoff");
} `
Ive also tried GetButton.
Comment
Answer by EdwardChuen · Dec 31, 2013 at 03:51 AM
Use this :)
function Update () {
if(Input.GetButtonDown("Jump"))
animation.Play("engines landingtakingoff");
}
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
animation.isPlaying always true and Animation stuck at time 0 0 Answers
How to export MMD model to Unity? 0 Answers
Animation Problem 2 Answers
Terrain brush duplicates and warps. 0 Answers