Panharmonicon fix for Nadu, Winged Wisdom (#5297)

This commit is contained in:
tool4ever
2024-05-25 14:28:59 +02:00
committed by GitHub
parent 42cd2ec210
commit 651d01ab76
4 changed files with 11 additions and 13 deletions

View File

@@ -41,12 +41,6 @@ public class StaticAbilityPanharmonicon {
return n;
}
// "triggers only once" means it can't happen
if (t.hasParam("ActivationLimit")) {
// currently no other limits, so no further calculation needed
return n;
}
CardCollectionView cardList = null;
// if LTB look back
if (t.getMode() == TriggerType.Exploited || t.getMode() == TriggerType.Sacrificed || t.getMode() == TriggerType.Destroyed ||
@@ -67,6 +61,11 @@ public class StaticAbilityPanharmonicon {
if (!stAb.checkConditions(MODE)) {
continue;
}
// it can't trigger more times than the limit allows
if (t.hasParam("ActivationLimit") &&
t.getActivationsThisTurn() + n + 1 >= Integer.parseInt(t.getParam("ActivationLimit"))) {
break;
}
if (applyPanharmoniconAbility(stAb, t, runParams)) {
n++;
}