Ejemplo n.º 1
0
 public void CheckSequence(Player localplayer)
 {
     for (int i = 0; i < 7; i++)
     {
         for (int j = 0; j < 7; j++)
         {
             if (defender.battlelinefilling[j] == true)
             {
                 if (defender.battleline[j].health <= 0)
                 {
                     defender.battleline[j].OnDeath(attacker, defender, j);
                     defender.battleline[j].firstturn = true;
                     battleUIManager.RemoveCreatureOnUI(defender, j);
                     defender.battlelinefilling[j] = false;
                 }
             }
         }
         for (int j = 0; j < 7; j++)
         {
             if (attacker.battlelinefilling[j] == true)
             {
                 if (attacker.battleline[j].health <= 0)
                 {
                     attacker.selfkillspellused = true;
                     attacker.battleline[j].OnDeath(attacker, defender, j);
                     attacker.battleline[j].firstturn = true;
                     battleUIManager.RemoveCreatureOnUI(attacker, j);
                     attacker.battlelinefilling[j] = false;
                     attacker.selfkillspellused    = false;
                 }
             }
         }
     }
     for (int i = 0; i < 7; i++)
     {
         if (attacker.battlelinefilling[i] == true)
         {
             attacker.battleline[i].OnCheck(attacker, defender, i);
         }
     }
 }