Example #1
0
 public void Healing(float hp)
 {
     if (stats.health + hp <= stats.MaxHealth)
     {
         stats.health += hp;
     }
     else
     {
         stats.health = stats.MaxHealth;
     }
     if (playerUIController != null)
     {
         playerUIController.SetHp(stats.MaxHealth, stats.health);
     }
 }
Example #2
0
 public void AddMaxHealth()
 {
     if (MutagenCount > 0 && CurrentPlayer.stats.HealthCountUpdate < 10)
     {
         CurrentPlayer.stats.MaxHealth += Mathematics.GetPercent(5, CurrentPlayer.stats.MaxHealth);
         MutagenCount--;
         CurrentPlayer.stats.HealthCountUpdate++;
         HealthP.UpdateImages(CurrentPlayer.stats.HealthCountUpdate - 1);
         playerUIController.SetHp(CurrentPlayer.stats.MaxHealth, CurrentPlayer.stats.health);
         playerUIController.SetMutagenCount(MutagenCount);
     }
 }