From fb0acb6a8b44133ba8a813b8ae0d66430a90a73b Mon Sep 17 00:00:00 2001 From: Agetian Date: Mon, 28 Aug 2017 19:26:54 +0000 Subject: [PATCH] - [XLN] Jace, Cunning Castaway: the clones should be immediately activatable as soon as they hit the battlefield. --- .../game/ability/effects/CopyPermanentEffect.java | 10 ++++++++++ .../res/cardsfolder/upcoming/jace_cunning_castaway.txt | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/forge-game/src/main/java/forge/game/ability/effects/CopyPermanentEffect.java b/forge-game/src/main/java/forge/game/ability/effects/CopyPermanentEffect.java index ed5b921e2a1..3190a167260 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/CopyPermanentEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/CopyPermanentEffect.java @@ -68,6 +68,7 @@ public class CopyPermanentEffect extends SpellAbilityEffect { final List triggers = Lists.newArrayList(); final List pumpKeywords = Lists.newArrayList(); boolean asNonLegendary = false; + boolean resetActivations = false; final long timestamp = game.getNextTimestamp(); @@ -88,6 +89,9 @@ public class CopyPermanentEffect extends SpellAbilityEffect { if (sa.hasParam("NonLegendary")) { asNonLegendary = true; } + if (sa.hasParam("ResetAbilityActivations")) { + resetActivations = true; + } if (sa.hasParam("AddSVars")) { svars.addAll(Arrays.asList(sa.getParam("AddSVars").split(" & "))); } @@ -329,6 +333,12 @@ public class CopyPermanentEffect extends SpellAbilityEffect { copy.removeIntrinsicKeyword("Devoid"); } + if (resetActivations) { + for (SpellAbility ab : copy.getSpellAbilities()) { + ab.getRestrictions().resetTurnActivations(); + } + } + copy.updateStateForView(); // Temporarily register triggers of an object created with CopyPermanent diff --git a/forge-gui/res/cardsfolder/upcoming/jace_cunning_castaway.txt b/forge-gui/res/cardsfolder/upcoming/jace_cunning_castaway.txt index 3497fdd6d47..e67081f0d61 100644 --- a/forge-gui/res/cardsfolder/upcoming/jace_cunning_castaway.txt +++ b/forge-gui/res/cardsfolder/upcoming/jace_cunning_castaway.txt @@ -9,6 +9,6 @@ SVar:DBDiscard:DB$ Discard | Defined$ You | NumCards$ 1 | Mode$ TgtChoose A:AB$ Token | Cost$ SubCounter<2/LOYALTY> | Planeswalker$ True | TokenAmount$ 1 | TokenName$ Illusion | TokenTypes$ Creature,Illusion | TokenPower$ 2 | TokenToughness$ 2 | TokenOwner$ You | TokenColors$ Blue | TokenImage$ u 2 2 illusion XLN | TokenTriggers$ SacOnSpell | TokenSVars$ DoSac | SpellDescription$ Create a 2/2 blue Illusion token with "When this creature becomes the target of a spell, sacrifice it." SVar:SacOnSpell:Mode$ BecomesTarget | ValidTarget$ Card.Self | SourceType$ Spell | TriggerZones$ Battlefield | Execute$ DoSac | TriggerDescription$ When CARDNAME becomes the target of a spell, sacrifice it. SVar:DoSac:DB$ Sacrifice | Defined$ Self -A:AB$ CopyPermanent | Cost$ SubCounter<5/LOYALTY> | Planeswalker$ True | Ultimate$ True | Defined$ Self | NumCopies$ 2 | NonLegendary$ True | SpellDescription$ Create two tokens that are copies of CARDNAME, except they're not legendary. +A:AB$ CopyPermanent | Cost$ SubCounter<5/LOYALTY> | Planeswalker$ True | Ultimate$ True | Defined$ Self | NumCopies$ 2 | NonLegendary$ True | ResetAbilityActivations$ True | SpellDescription$ Create two tokens that are copies of CARDNAME, except they're not legendary. SVar:Picture:http://www.wizards.com/global/images/magic/general/jace_cunning_castaway.jpg Oracle:[+1] Whenever one or more creatures you control deal combat damage to a player this turn, draw a card, then discard a card.\n[-2] Create a 2/2 blue Illusion token with "When this creature becomes the target of a spell, sacrifice it."\n[-5] Create two tokens that are copies of Jace, Cunning Castaway, except they're not legendary. \ No newline at end of file