Help with Syntax please!!
Boolean is triggered once but never makes it to else or next part to be false:
#pragma strict
var animator : Animator;
var myBool : boolean;
function Start () {
animator = GetComponent(Animator);
}
function OnMouseUp () {
if (myBool == false) {
animator.SetBool("myBool", true);
}
else {
//if (myBool == true){
animator.SetBool("myBool", false);
}
}
↧