Exemple #1
0
 private void OnPowerupCollected(BasePowerup powerup)
 {
     if (powerupTimer != null)
     {
         powerupTimer.ActivateTimer(powerup.GetPowerupDuration());
     }
 }
Exemple #2
0
 private void OnPowerupExhausted(BasePowerup powerup)
 {
     if (powerup.GetPowerupType() == PowerupType.ScoreMultiplier)
     {
         ScoreMultiplier = 1;
     }
 }
Exemple #3
0
 private void OnPowerupCollected(BasePowerup powerup)
 {
     if (powerup.GetPowerupType() == PowerupType.ScoreMultiplier)
     {
         ScoreMultiplier = ((ScoreMultiplier)powerup).GetMultiplier();
     }
 }
 private void OnPowerupExhausted(BasePowerup powerup)
 {
     if (powerup.GetPowerupType() == PowerupType.FastRunInvincibility)
     {
         moveSpeed -= ((FastRunInvincibility)powerup).GetSpeed();
     }
 }
Exemple #5
0
 private void OnPowerupExhausted(BasePowerup powerup)
 {
     if (powerup.GetPowerupType() == PowerupType.Invincibility || powerup.GetPowerupType() == PowerupType.FastRunInvincibility)
     {
         IsInvincible = false;
         //LeanTween.color(gameObject, Color.white, 0.5f);
         GetComponentInChildren <ParticleSystem>().Stop();
     }
 }
Exemple #6
0
 private void OnPowerupCollected(BasePowerup powerup)
 {
     if (powerup.GetPowerupType() == PowerupType.Invincibility || powerup.GetPowerupType() == PowerupType.FastRunInvincibility)
     {
         IsInvincible = true;
         //LeanTween.color(gameObject, Color.cyan, 0.5f);
         GetComponentInChildren <ParticleSystem>().Play();
     }
 }