Пример #1
0
 public void Attack(FightingRobot tarjet)
 {
     tarjet.currentHP = tarjet.currentHP - attackPower;
     if (tarjet.currentHP < 0)
     {
         tarjet.currentHP = 0;
     }
 }
Пример #2
0
 public void SpecialAttack(FightingRobot tarjet)
 {
     if (currentEP < 50)
     {
         tarjet.currentHP = currentHP;
         currentEP        = 0;
     }
     else
     {
         tarjet.currentHP = tarjet.currentHP - (attackPower * 2);
         if (tarjet.currentHP < 0)
         {
             tarjet.currentHP = 0;
         }
         currentEP = currentEP - 50;
     }
 }