Hi the question is this:
I want to use a condition, like a boolean, to start an animation, and inmediatly it start, change that boolean, but dont stop the animation.
Example:
var canJump : boolean = true;
function Update {
if (canJump)
{
play.Animation(“Jump”);
canJump = false;
yield WaitForSeconds (2);
canJump = true;
}
}
So, in this example, I want to jump, and dont be able to jump again until 2 sec. But if I do this way, inmediatly canJump is turned false, the animation stop.
Any Idea?