fix StackOverflow caused in checkStateEffects

This commit is contained in:
jendave
2011-08-06 23:46:30 +00:00
parent d9ece1df58
commit def0d09f63

View File

@@ -545,12 +545,12 @@ public class GameAction {
} }
}//if isAura }//if isAura
if(c.getNetDefense() <= c.getDamage() && !c.getKeyword().contains("Indestructible")) { if(c.isCreature() && c.getNetDefense() <= c.getDamage() && !c.getKeyword().contains("Indestructible")) {
destroy(c); destroy(c);
AllZone.Combat.removeFromCombat(c); //this is untested with instants and abilities but required for First Strike combat phase AllZone.Combat.removeFromCombat(c); //this is untested with instants and abilities but required for First Strike combat phase
} }
else if(c.getNetDefense() <= 0) { else if(c.isCreature() && c.getNetDefense() <= 0) {
destroy(c); destroy(c);
AllZone.Combat.removeFromCombat(c); AllZone.Combat.removeFromCombat(c);
} }