- AI should not overprioritize Gavony Township, otherwise it locks itself on mana too much.

This commit is contained in:
Agetian
2017-08-15 19:19:10 +00:00
parent aa4a793566
commit f279792273
2 changed files with 8 additions and 1 deletions

View File

@@ -37,6 +37,7 @@ public class CountersPutAllAi extends SpellAbilityAi {
final String type = sa.getParam("CounterType");
final String amountStr = sa.getParam("CounterNum");
final String valid = sa.getParam("ValidCards");
final String logic = sa.getParamOrDefault("AILogic", "");
final boolean curse = sa.isCurse();
final TargetRestrictions tgt = sa.getTargetRestrictions();
@@ -58,6 +59,12 @@ public class CountersPutAllAi extends SpellAbilityAi {
}
}
if (logic.equals("AtEOTOrBlock")) {
if (!ai.getGame().getPhaseHandler().is(PhaseType.END_OF_TURN) && !ai.getGame().getPhaseHandler().is(PhaseType.COMBAT_DECLARE_BLOCKERS)) {
return false;
}
}
if (tgt != null) {
Player pl = curse ? ComputerUtil.getOpponentFor(ai) : ai;
sa.getTargets().add(pl);