I have 03 buttons and the player must figure out the sequence. After making his attempt, the script checks the order and restart the game or to move to next stage. How can I do to prevent that the same button be pressed more than once. How to stop the player to press the same button again? I create this script but not work: Code (csharp): var bt1 = false; var bt2 = false; var bt3 = false; if (hit.gameObject.tag == "button") { if (bt1 == true) return; else number ++; bt1 = true; var lobjetct : GameObject = GameObject.FindWithTag("machine"); lobject.animation.Play ("anim1"); Tried this too: Code (csharp): var bt1 = false; var bt2 = false; var bt3 = false; if (hit.gameObject.tag == "button" bt1 == false) { number ++; bt1 = true; var lobjetct : GameObject = GameObject.FindWithTag("machine"); lobject.animation.Play ("anim1");