Shared zcc init code

This commit is contained in:
Steven Knipe 2025-06-01 13:01:20 -07:00 committed by Failure
parent b3d721c16b
commit bd996b2dac
6 changed files with 48 additions and 13 deletions

View file

@ -1306,7 +1306,7 @@ public abstract class PlayerImpl implements Player, Serializable {
SpellAbility ability = originalAbility.copy();
Set<MageIdentifier> allowedIdentifiers = originalAbility.spellCanBeActivatedNow(getId(), game);
ability.setControllerId(getId());
ability.setSourceObjectZoneChangeCounter(game.getState().getZoneChangeCounter(ability.getSourceId()));
ability.initSourceObjectZoneChangeCounter(game, true);
//20091005 - 601.2a
if (ability.getSourceId() == null) {
@ -1332,7 +1332,7 @@ public abstract class PlayerImpl implements Player, Serializable {
spell.setCopy(true, null);
}
// Update the zcc to the stack
ability.setSourceObjectZoneChangeCounter(game.getState().getZoneChangeCounter(ability.getSourceId()));
ability.initSourceObjectZoneChangeCounter(game, true);
// ALTERNATIVE COST from dynamic effects
// some effects set sourceId to cast without paying mana costs or other costs