Example #1
0
 private void OnMouseDown()
 {
     foreach (DefenderButton defenderButton in defenderButtons)
     {
         defenderButton.GetComponent <SpriteRenderer>().color = inactiveColor;
     }
     GetComponent <SpriteRenderer>().color = Color.white;
     defenderSpawner.SetDefenderToSpawn(defenderPrefab);
 }