Merge branch 'fixRitual' into 'master'

Fix imprinted Cards not being removed from host

See merge request core-developers/forge!3597
This commit is contained in:
Michael Kamensky
2021-01-31 05:13:57 +00:00
10 changed files with 22 additions and 3 deletions

View File

@@ -98,9 +98,11 @@ public class TriggerChangesZone extends Trigger {
if (hasParam("ValidCard")) {
Card moved = (Card) runParams.get(AbilityKey.Card);
boolean leavesBattlefield = "Battlefield".equals(getParam("Origin"));
boolean leavesLKIZone = "Battlefield".equals(getParam("Origin"));
//TODO make this smarter if there ever is a card that lets you play anything from exile
leavesLKIZone |= "Exile".equals(getParam("Origin")) && (moved.getZone().is(ZoneType.Graveyard) || moved.getZone().is(ZoneType.Command));
if (leavesBattlefield) {
if (leavesLKIZone) {
moved = (Card) runParams.get(AbilityKey.CardLKI);
}

View File

@@ -5,7 +5,8 @@ T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Any | Destination$ Battlefi
SVar:TrigExile:DB$ChangeZone | Imprint$ True | Origin$ Hand | Destination$ Exile | ChangeType$ Card.nonArtifact+nonLand | ChangeNum$ 1
A:AB$ ManaReflected | Cost$ T | Valid$ Defined.Imprinted | ColorOrType$ Color | ReflectProperty$ Is | SpellDescription$ Add one mana of any of the exiled card's colors.
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
T:Mode$ ChangesZone | Origin$ Exile | Destination$ Any | ValidCard$ Card.IsImprinted | Execute$ DBCleanup | Static$ True
T:Mode$ ChangesZone | Origin$ Exile | Destination$ Any | Static$ True | ValidCard$ Card.IsImprinted+ExiledWithSource | Execute$ DBForget
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
SVar:NeedsToPlayVar:Z GE1
SVar:Z:Count$ValidHand Card.nonArtifact+nonColorless+nonLand+YouOwn

View File

@@ -5,6 +5,8 @@ T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Any | Destination$ Battlefi
SVar:TrigExile:DB$ ChangeZone | Imprint$ True | ValidTgts$ Permanent.nonLand | TgtPrompt$ Select target nonland permanent | Origin$ Battlefield | Destination$ Exile
S:Mode$ CantBeCast | ValidCard$ Card.sharesNameWith Imprinted | Description$ Players can't cast spells with the same name as the exiled card.
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
T:Mode$ ChangesZone | ValidCard$ Card.IsImprinted+ExiledWithSource | Origin$ Exile | Execute$ DBForget | Static$ True
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
SVar:Picture:http://www.wizards.com/global/images/magic/general/exclusion_ritual.jpg
Oracle:Imprint — When Exclusion Ritual enters the battlefield, exile target nonland permanent.\nPlayers can't cast spells with the same name as the exiled card.

View File

@@ -7,6 +7,8 @@ T:Mode$ TapsForMana | ValidCard$ Land.sharesNameWith Imprinted | Execute$ TrigMa
SVar:TrigMana:DB$ ManaReflected | Valid$ Defined.Triggered | ColorOrType$ Type | ReflectProperty$ Produced | Defined$ TriggeredPlayer
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
T:Mode$ ChangesZone | ValidCard$ Card.IsImprinted+ExiledWithSource | Origin$ Exile | Execute$ DBForget | Static$ True
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
SVar:NeedsToPlay:Land.Basic+YouCtrl
AI:RemoveDeck:Random
SVar:Picture:http://www.wizards.com/global/images/magic/general/extraplanar_lens.jpg

View File

@@ -8,5 +8,7 @@ T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Land.s
SVar:TrigDamage:DB$DealDamage | Defined$ TriggeredCardController | NumDmg$ 2
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
T:Mode$ ChangesZone | Origin$ Exile | Destination$ Any | Static$ True | ValidCard$ Card.IsImprinted+ExiledWithSource | Execute$ DBForget
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
SVar:Picture:http://www.wizards.com/global/images/magic/general/invader_parasite.jpg
Oracle:Imprint — When Invader Parasite enters the battlefield, exile target land.\nWhenever a land with the same name as the exiled card enters the battlefield under an opponent's control, Invader Parasite deals 2 damage to that player.

View File

@@ -6,6 +6,8 @@ T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.S
SVar:TrigExile:DB$ ChangeZone | Origin$ Graveyard | Destination$ Exile | ValidTgts$ Card | Imprint$ True
T:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Any | Static$ True | ValidCard$ Card.Self | Execute$ DBCleanup
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
T:Mode$ ChangesZone | ValidCard$ Card.IsImprinted+ExiledWithSource | Origin$ Exile | Execute$ DBForget | Static$ True
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
S:Mode$ Continuous | Affected$ Card.Self | AddKeyword$ Protection from creatures | CheckSVar$ CheckCreature | SVarCompare$ GE1 | Description$ CARDNAME has protection from each of the exiled card's card types. (Artifact, creature, enchantment, instant, land, planeswalker, sorcery, and tribal are card types.)
S:Mode$ Continuous | Affected$ Card.Self | AddKeyword$ Protection:Land:Protection from lands | CheckSVar$ CheckLand | SVarCompare$ GE1
S:Mode$ Continuous | Affected$ Card.Self | AddKeyword$ Protection from enchantments | CheckSVar$ CheckEnchantment | SVarCompare$ GE1

View File

@@ -7,6 +7,8 @@ SVar:TrigExile:DB$ChangeZone | Imprint$ True | ValidTgts$ Creature.nonToken | Tg
T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Any | Execute$ TrigReset | Static$ True
SVar:TrigReset:DB$ Cleanup | ClearImprinted$ True
S:Mode$ Continuous | Affected$ Card.Self | AddPower$ X | AddToughness$ Y | References$ X,Y | Description$ CARDNAME gets +X/+Y, where X is the exiled creature card's power and Y is its toughness.
T:Mode$ ChangesZone | ValidCard$ Card.IsImprinted+ExiledWithSource | Origin$ Exile | Execute$ DBForget | Static$ True
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
SVar:X:Imprinted$CardPower
SVar:Y:Imprinted$CardToughness
SVar:Picture:http://www.wizards.com/global/images/magic/general/phyrexian_ingester.jpg

View File

@@ -6,6 +6,8 @@ SVar:TrigExile:DB$ChangeZone | Imprint$ True | Origin$ Hand | Destination$ Exile
S:Mode$ ReduceCost | ValidCard$ Card.sharesCardTypeWith Imprinted | Type$ Spell | Activator$ You | Amount$ 2 | Description$ Spells you cast that share a card type with the exiled card cost {2} less to cast.
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
T:Mode$ ChangesZone | Origin$ Exile | Destination$ Any | Static$ True | ValidCard$ Card.IsImprinted+ExiledWithSource | Execute$ DBForget
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
SVar:NeedsToPlayVar:Y GE1
SVar:Y:Count$ValidHand Permanent.nonLand+YouOwn
AI:RemoveDeck:Random

View File

@@ -8,6 +8,8 @@ T:Mode$ DamageDone | ValidSource$ Creature.EquippedBy | ValidTarget$ Player | Co
SVar:TrigSpell:DB$ Play | Defined$ Imprinted | Amount$ All | CopyOnce$ True | WithoutManaCost$ True | Optional$ True | CopyCard$ True
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
T:Mode$ ChangesZone | ValidCard$ Card.IsImprinted+ExiledWithSource | Origin$ Exile | Execute$ DBForget | Static$ True
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
#Amount$ All | CopyOnce$ True for Strionic Resonator
SVar:NeedsToPlayVar:Z GE1
SVar:Z:Count$ValidHand Card.Instant+YouOwn

View File

@@ -7,6 +7,8 @@ SVar:TrigExile:DB$ ChangeZone | Imprint$ True | Origin$ Library | Destination$ E
S:Mode$ Continuous | Affected$ Card.EquippedBy | AddPower$ X | AddToughness$ X | References$ X | Description$ Equipped creature gets +1/+1 for each land on the battlefield with the same name as the exiled card.
SVar:X:Count$Valid Land.sharesNameWith Imprinted
T:Mode$ ChangesZone | Origin$ Battlefield | ValidCard$ Card.Self | Destination$ Any | Execute$ DBCleanup | Static$ True
T:Mode$ ChangesZone | ValidCard$ Card.IsImprinted+ExiledWithSource | Origin$ Exile | Execute$ DBForget | Static$ True
SVar:DBForget:DB$ Pump | ForgetImprinted$ TriggeredCard
SVar:DBCleanup:DB$ Cleanup | ClearImprinted$ True
AI:RemoveDeck:Random
SVar:Picture:http://www.wizards.com/global/images/magic/general/strata_scythe.jpg