tweaking usage of getTotalPower to include new Boolean

This commit is contained in:
Northmoc
2021-01-31 14:00:37 -05:00
parent f876cb934a
commit 0e9f24cafd
3 changed files with 7 additions and 3 deletions

View File

@@ -1187,8 +1187,10 @@ public class HumanCostDecision extends CostDecisionMakerBase {
source, ability);
typeList = CardLists.filter(typeList, Presets.UNTAPPED);
boolean isCrew=false;
if (ability.hasParam("Crew")) {
typeList = CardLists.getNotKeyword(typeList, "CARDNAME can't crew Vehicles.");
isCrew=true;
}
if (c == null && !amount.equals("Any")) {
@@ -1247,7 +1249,7 @@ public class HumanCostDecision extends CostDecisionMakerBase {
inp.setCancelAllowed(true);
inp.showAndWait();
if (inp.hasCancelled() || CardLists.getTotalPower(inp.getSelected(), true) < i) {
if (inp.hasCancelled() || CardLists.getTotalPower(inp.getSelected(), true, isCrew) < i) {
return null;
}
return PaymentDecision.card(inp.getSelected());