Ejemplo n.º 1
0
 // Update is called once per frame
 void Update()
 {
     if (!isGameRunning)
     {
         Invoke("StartGame", .1f);
     }
     if (Input.GetKeyDown(KeyCode.T))
     {
         foreach (GroundEnemy enemy in GameObject.FindObjectsOfType <GroundEnemy>())
         {
             Destroy(enemy.gameObject);
             roundController.DecreaseEnemyCount();
         }
         foreach (FlyingEnemy enemy in GameObject.FindObjectsOfType <FlyingEnemy>())
         {
             Destroy(enemy.gameObject);
             roundController.DecreaseEnemyCount();
         }
     }
     if (Input.GetKeyDown(KeyCode.Escape))
     {
         Application.Quit();
     }
 }