support "cmcGT$ Turns" in StaticAbilityCantBeCast

This commit is contained in:
Northmoc
2021-12-12 19:57:53 -05:00
parent 520169b2c7
commit ed5152f2a2

View File

@@ -125,10 +125,15 @@ public class StaticAbilityCantBeCast {
return false; return false;
} }
if (stAb.hasParam("cmcGT") && (activator != null) if (stAb.hasParam("cmcGT") && (activator != null)) {
&& (card.getCMC() <= CardLists.getType(activator.getCardsIn(ZoneType.Battlefield), if (stAb.getParam("cmcGT").equals("Turns")) {
stAb.getParam("cmcGT")).size())) { if (card.getCMC() <= activator.getTurn()) {
return false; return false;
}
} else if (card.getCMC() <= CardLists.getType(activator.getCardsIn(ZoneType.Battlefield),
stAb.getParam("cmcGT")).size()) {
return false;
}
} }
if (stAb.hasParam("NumLimitEachTurn") && activator != null) { if (stAb.hasParam("NumLimitEachTurn") && activator != null) {