Nethroi (IKO)

This commit is contained in:
Tim Mocny
2021-02-14 00:57:22 +00:00
committed by Anthony Calosa
parent 47fcd88366
commit d7f0665bae
8 changed files with 116 additions and 2 deletions

View File

@@ -1229,6 +1229,14 @@ public class ChangeZoneAi extends SpellAbilityAi {
}
}
// if max power exceeded, do not choose this card (but keep looking for other options)
if (sa.hasParam("MaxTotalTargetPower")) {
if (choice.getNetPower() > sa.getTargetRestrictions().getMaxTotalPower(choice, sa) -sa.getTargets().getTotalTargetedPower()) {
list.remove(choice);
continue;
}
}
// honor the Same Creature Type restriction
if (sa.getTargetRestrictions().isWithSameCreatureType()) {
Card firstTarget = sa.getTargetCard();