Do this only once each turn - fixed wrong triggers after optional usage (example: Ondu Spiritdancer, see #11106) (#11107)

* Fix Ondu Spiritdancer. Closes #11106
* Add tests for "Do this only once each turn"
* Add test for Ondu Spiritdancer
This commit is contained in:
PurpleCrowbar 2023-09-06 19:12:03 +01:00 committed by GitHub
parent 7b5139742f
commit 692c55e3e1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 131 additions and 4 deletions

View file

@ -157,15 +157,15 @@ public abstract class TriggeredAbilityImpl extends AbilityImpl implements Trigge
return false;
}
}
//20091005 - 603.4
if (!super.resolve(game)) {
return false;
}
if (doOnlyOnceEachTurn) {
game.getState().setValue(CardUtil.getCardZoneString(
"lastTurnUsed" + originalId, sourceId, game
), game.getTurnNum());
}
//20091005 - 603.4
if (!super.resolve(game)) {
return false;
}
return true;
}