void CheckTurretTypeToSell() { //bullet if (turret.GetComponent <BulletTurret>()) { BulletSpecial.RemoveTurret(turret.GetComponent <BulletTurret>()); } //missile else if (turret.GetComponent <MissileTurret>()) { MissileSpecial.RemoveTurret(turret.GetComponent <MissileTurret>()); } //railgun else if (turret.GetComponent <RailgunTurret>()) { RailgunSpecial.RemoveTurret(turret.GetComponent <RailgunTurret>()); } //laser else if (turret.GetComponent <LaserTurret>()) { LaserSpecial.RemoveTurret(turret.GetComponent <LaserTurret>()); } //tesla else if (turret.GetComponent <TeslaTurret>()) { TeslaSpecial.RemoveTurret(turret.GetComponent <TeslaTurret>()); } //fire else if (turret.GetComponent <FireTurret>()) { FireSpecial.RemoveTurret(turret.GetComponent <FireTurret>()); } //tank else if (turret.GetComponent <TankTurret>()) { TankSpecial.RemoveTurret(turret.GetComponent <TankTurret>()); } //farm else if (turret.GetComponent <FarmTower>()) { FarmSpecial.RemoveTower(turret.GetComponent <FarmTower>()); } else if (turret.GetComponent <WindTurret>()) { WindSpecial.RemoveTurret(turret.GetComponent <WindTurret>()); } }
void Awake() { instance = this; turrets = new List <WindTurret>(); num.gameObject.SetActive(false); }
public static void MakeWindSpecial(WindTurret wind) { instance.windBtn.SetActive(true); WindSpecial.AddNewWindTurret(wind); }