diff --git a/forge-game/src/main/java/forge/game/replacement/ReplacementHandler.java b/forge-game/src/main/java/forge/game/replacement/ReplacementHandler.java index 7ddf126c199..5530e5447b2 100644 --- a/forge-game/src/main/java/forge/game/replacement/ReplacementHandler.java +++ b/forge-game/src/main/java/forge/game/replacement/ReplacementHandler.java @@ -112,15 +112,9 @@ public class ReplacementHandler { for (final Card crd : p.getAllCards()) { for (final ReplacementEffect replacementEffect : crd.getReplacementEffects()) { - // when testing ReplaceMoved effects, make sure to check last known information since the host card - // could have been moved, e.g. via a mass removal event (e.g. Kalitas, Traitor of Ghet + Wrath of God) - // TODO: currently only processing removal effects that way to avoid issues like e.g. Essence of - // the Wild destroyed in response to a creature spell going on stack still making the card ETB as a - // copy of the Essence. This probably needs some rework to allow both to function correctly without - // the need for hacks and exclusions. - boolean isReplaceMovedOnRemoval = replacementEffect instanceof ReplaceMoved && ("Graveyard".equals(replacementEffect.getMapParams().get("Destination")) || "Exile".equals(replacementEffect.getMapParams().get("Destination"))); - - Zone cardZone = isReplaceMovedOnRemoval ? game.getChangeZoneLKIInfo(crd).getLastKnownZone() : game.getZoneOf(crd); + // Use "CheckLKIZone" parameter to test for effects that care abut where the card was last (e.g. Kalitas, Traitor of Ghet + // getting hit by mass removal should still produce tokens). + Zone cardZone = "True".equals(replacementEffect.getMapParams().get("CheckLKIZone")) ? game.getChangeZoneLKIInfo(crd).getLastKnownZone() : game.getZoneOf(crd); if (!replacementEffect.hasRun() && replacementEffect.getLayer() == layer diff --git a/forge-gui/res/cardsfolder/k/kalitas_traitor_of_ghet.txt b/forge-gui/res/cardsfolder/k/kalitas_traitor_of_ghet.txt index 2017e3f009f..f60053aaa9f 100644 --- a/forge-gui/res/cardsfolder/k/kalitas_traitor_of_ghet.txt +++ b/forge-gui/res/cardsfolder/k/kalitas_traitor_of_ghet.txt @@ -3,7 +3,7 @@ ManaCost:2 B B Types:Legendary Creature Vampire Warrior PT:3/4 K:Lifelink -R:Event$ Moved | ActiveZones$ Battlefield | Origin$ Battlefield | Destination$ Graveyard | ValidLKI$ Creature.nonToken+OppCtrl | ReplaceWith$ Exile | Description$ If a nontoken creature an opponent controls would die, instead exile that card and put a 2/2 black Zombie creature token onto the battlefield. +R:Event$ Moved | ActiveZones$ Battlefield | Origin$ Battlefield | Destination$ Graveyard | ValidLKI$ Creature.nonToken+OppCtrl | ReplaceWith$ Exile | CheckLKIZone$ True | Description$ If a nontoken creature an opponent controls would die, instead exile that card and put a 2/2 black Zombie creature token onto the battlefield. SVar:Exile:DB$ ChangeZone | Origin$ Battlefield | Destination$ Exile | SubAbility$ DBToken | Defined$ ReplacedCard SVar:DBToken:DB$ Token | TokenAmount$ 1 | TokenName$ Zombie | TokenTypes$ Creature,Zombie | TokenColors$ Black | TokenPower$ 2 | TokenToughness$ 2 | TokenOwner$ You | TokenImage$ b 2 2 zombie OGW A:AB$ PutCounter | Cost$ 2 B Sac<1/Vampire.Other;Zombie.Other/another Vampire or Zombie> | CounterType$ P1P1 | CounterNum$ 2 | SpellDescription$ Put two +1/+1 counters on CARDNAME.