Exemplo n.º 1
0
        private float spaceBetweenSquares = 2.5f;   // the distance between the centers of squares on the game board


        void Start()
        {
            rb           = GetComponent <Rigidbody>();
            gameManagerX = GameObject.Find("Game Manager").GetComponent <GameManagerX>();

            //transform.position = RandomSpawnPosition();
            StartCoroutine(RemoveObjectRoutine()); // begin timer before target leaves screen
        }
Exemplo n.º 2
0
 // Start is called before the first frame update
 void Start()
 {
     gameManagerX = GameObject.Find("Game Manager").GetComponent <GameManagerX>();
     button       = GetComponent <Button>();
     button.onClick.AddListener(SetDifficulty);
 }