- Attempting to improve CountersPutAi when targeting the AI player itself (shouldn't try it if the AI player has no counters at all)

-TODO: isn't the inner condition check somewhat off too? (will currently attempt targeting every time eachExisting is false, even if the AI has no counters at all).
This commit is contained in:
Agetian
2017-07-07 18:16:20 +00:00
parent ca2a1f734b
commit d17b3d4019

View File

@@ -199,9 +199,11 @@ public class CountersPutAi extends SpellAbilityAi {
if (sa.canTarget(ai)) {
// don't target itself when its forced to add poison
// counters too
if (!eachExisting || ai.getPoisonCounters() < 5) {
sa.getTargets().add(ai);
return true;
if (!ai.getCounters().isEmpty()) {
if (!eachExisting || ai.getPoisonCounters() < 5) {
sa.getTargets().add(ai);
return true;
}
}
}