Пример #1
0
 void RecoverHealthWithMana(int damage, float immunityDuration)
 {
     damage = Mathf.FloorToInt(damage * factor);
     if (Game.Score.GetMana() > damage)
     {
         target.UndoDamage(damage);
         Game.Score.AddMana(-damage);
     }
     else
     {
         target.UndoDamage(Game.Score.GetMana());
         Game.Score.AddMana(-Game.Score.GetMana());
     }
 }