public void RemovePlant(Selectable plant) { PlantedPlants.Remove(plant); if (EnoughMoney == false && PlantedPlants.Count <= 0) { GameOver(); } }
public void AddPlant(Selectable plant) { PlantedPlants.Add(plant); AddMoney(-200); if (PlantedPlants.Count >= 5) { Victory(); return; } UIManager.Instance.UpdateGoalText("GOAL " + PlantedPlants.Count + " / 5"); }