public void VerifyPowerUpInstance() { if (this.gameObject.name.Contains("TripleShoot")) { PowerUpStatus = Enums.PowerUp.TripleShoot; } if (this.gameObject.name.Contains("Shield")) { PowerUpStatus = Enums.PowerUp.Shield; } if (this.gameObject.name.Contains("Speed")) { PowerUpStatus = Enums.PowerUp.Speed; } }
public void SetActivePowerUp(Enums.PowerUp powerUp) { switch ((int)powerUp) { case 0: Player.EnableTripleShoot(PowerUpTime); break; case 1: Player.EnableSpeed(PowerUpTime, SpeedBoost); break; case 2: Player.EnableShield(PowerUpTime); break; } }