From 3b5d273409e5338e768bbee6aa0cb9090224ce85 Mon Sep 17 00:00:00 2001 From: Hanmac Date: Sun, 20 May 2018 11:33:18 +0200 Subject: [PATCH 1/3] CounterEffects: use gameState and timestamp checks --- .../src/main/java/forge/ai/GameState.java | 6 ++--- .../java/forge/ai/simulation/GameCopier.java | 1 - forge-game/src/main/java/forge/game/Game.java | 10 ++++--- .../ability/effects/CountersMoveEffect.java | 12 ++++----- .../effects/CountersMultiplyEffect.java | 15 ++++++++--- .../ability/effects/CountersPutEffect.java | 27 +++++++++++++++++-- .../effects/CountersPutOrRemoveEffect.java | 7 +++++ .../ability/effects/CountersRemoveEffect.java | 9 ++++++- .../src/main/java/forge/game/card/Card.java | 8 ------ .../java/forge/game/card/CardFactoryUtil.java | 5 ---- .../game/trigger/TriggerBecomeMonstrous.java | 13 +++++---- .../main/java/forge/trackable/Tracker.java | 4 +++ 12 files changed, 78 insertions(+), 39 deletions(-) diff --git a/forge-ai/src/main/java/forge/ai/GameState.java b/forge-ai/src/main/java/forge/ai/GameState.java index 9a3712a5f51..9ca52ea5324 100644 --- a/forge-ai/src/main/java/forge/ai/GameState.java +++ b/forge-ai/src/main/java/forge/ai/GameState.java @@ -241,8 +241,7 @@ public abstract class GameState { newText.append("|Renowned"); } if (c.isMonstrous()) { - newText.append("|Monstrous:"); - newText.append(c.getMonstrosityNum()); + newText.append("|Monstrous"); } if (c.isPhasedOut()) { newText.append("|PhasedOut"); @@ -979,9 +978,8 @@ public abstract class GameState { c.tap(); } else if (info.startsWith("Renowned")) { c.setRenowned(true); - } else if (info.startsWith("Monstrous:")) { + } else if (info.startsWith("Monstrous")) { c.setMonstrous(true); - c.setMonstrosityNum(Integer.parseInt(info.substring((info.indexOf(':') + 1)))); } else if (info.startsWith("PhasedOut")) { c.setPhasedOut(true); } else if (info.startsWith("Counters:")) { diff --git a/forge-ai/src/main/java/forge/ai/simulation/GameCopier.java b/forge-ai/src/main/java/forge/ai/simulation/GameCopier.java index 33c614de03b..6324ff494e1 100644 --- a/forge-ai/src/main/java/forge/ai/simulation/GameCopier.java +++ b/forge-ai/src/main/java/forge/ai/simulation/GameCopier.java @@ -318,7 +318,6 @@ public class GameCopier { } if (c.isMonstrous()) { newCard.setMonstrous(true); - newCard.setMonstrosityNum(c.getMonstrosityNum()); } if (c.isRenowned()) { newCard.setRenowned(true); diff --git a/forge-game/src/main/java/forge/game/Game.java b/forge-game/src/main/java/forge/game/Game.java index 79ef215ddc0..83e0e5e9396 100644 --- a/forge-game/src/main/java/forge/game/Game.java +++ b/forge-game/src/main/java/forge/game/Game.java @@ -543,15 +543,19 @@ public class Game { return found == null; } - public Card getFound() { - return found == null ? old : found; + public Card getFound(final Card notFound) { + return found == null ? notFound : found; } } public Card getCardState(final Card card) { + return getCardState(card, card); + } + + public Card getCardState(final Card card, final Card notFound) { CardStateVisitor visit = new CardStateVisitor(card); this.forEachCardInGame(visit); - return visit.getFound(); + return visit.getFound(notFound); } // Allows visiting cards in game without allocating a temporary list. diff --git a/forge-game/src/main/java/forge/game/ability/effects/CountersMoveEffect.java b/forge-game/src/main/java/forge/game/ability/effects/CountersMoveEffect.java index b93abcbf6a3..5c876c6720b 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/CountersMoveEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/CountersMoveEffect.java @@ -95,8 +95,8 @@ public class CountersMoveEffect extends SpellAbilityEffect { return; } - Card cur = game.getCardState(dest); - if (cur.getTimestamp() != dest.getTimestamp()) { + Card cur = game.getCardState(dest, null); + if (cur == null || !cur.equalsWithTimestamp(dest)) { // Test to see if the card we're trying to add is in the expected state return; } @@ -185,8 +185,8 @@ public class CountersMoveEffect extends SpellAbilityEffect { continue; } - Card cur = game.getCardState(dest); - if (cur.getTimestamp() != dest.getTimestamp()) { + Card cur = game.getCardState(dest, null); + if (cur == null || !cur.equalsWithTimestamp(dest)) { // Test to see if the card we're trying to add is in the expected state continue; } @@ -238,8 +238,8 @@ public class CountersMoveEffect extends SpellAbilityEffect { if (source.equals(dest)) { continue; } - Card cur = game.getCardState(dest); - if (cur.getTimestamp() != dest.getTimestamp()) { + Card cur = game.getCardState(dest, null); + if (cur == null || !cur.equalsWithTimestamp(dest)) { // Test to see if the card we're trying to add is in the expected state continue; } diff --git a/forge-game/src/main/java/forge/game/ability/effects/CountersMultiplyEffect.java b/forge-game/src/main/java/forge/game/ability/effects/CountersMultiplyEffect.java index 94b029bbdde..08117188072 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/CountersMultiplyEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/CountersMultiplyEffect.java @@ -42,14 +42,21 @@ public class CountersMultiplyEffect extends SpellAbilityEffect { final int n = Integer.valueOf(sa.getParamOrDefault("Multiplier", "2")) - 1; for (final Card tgtCard : getTargetCards(sa)) { + Card gameCard = game.getCardState(tgtCard, null); + // gameCard is LKI in that case, the card is not in game anymore + // or the timestamp did change + // this should check Self too + if (gameCard == null || !tgtCard.equalsWithTimestamp(gameCard)) { + continue; + } if (counterType != null) { - tgtCard.addCounter(counterType, tgtCard.getCounters(counterType) * n, host, true); + gameCard.addCounter(counterType, gameCard.getCounters(counterType) * n, host, true); } else { - for (Map.Entry e : tgtCard.getCounters().entrySet()) { - tgtCard.addCounter(e.getKey(), e.getValue() * n, host, true); + for (Map.Entry e : gameCard.getCounters().entrySet()) { + gameCard.addCounter(e.getKey(), e.getValue() * n, host, true); } } - game.updateLastStateForCard(tgtCard); + game.updateLastStateForCard(gameCard); } } diff --git a/forge-game/src/main/java/forge/game/ability/effects/CountersPutEffect.java b/forge-game/src/main/java/forge/game/ability/effects/CountersPutEffect.java index a69e97cca63..d58b3ab209c 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/CountersPutEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/CountersPutEffect.java @@ -128,6 +128,18 @@ public class CountersPutEffect extends SpellAbilityEffect { } for (final GameObject obj : tgtObjects) { + // check if the object is still in game or if it was moved + if (obj instanceof Card) { + Card tgtCard = (Card) obj; + Card gameCard = game.getCardState(tgtCard, null); + // gameCard is LKI in that case, the card is not in game anymore + // or the timestamp did change + // this should check Self too + if (gameCard == null || !tgtCard.equalsWithTimestamp(gameCard)) { + continue; + } + } + if (existingCounter) { final List choices = Lists.newArrayList(); if (obj instanceof GameEntity) { @@ -186,11 +198,22 @@ public class CountersPutEffect extends SpellAbilityEffect { // this check needs to check if this card would be on the battlefield noTributeLKI.setLastKnownZone(activator.getZone(ZoneType.Battlefield)); + // double freeze tracker, so it doesn't update view + game.getTracker().freeze(); + CardCollection preList = new CardCollection(noTributeLKI); game.getAction().checkStaticAbilities(false, Sets.newHashSet(noTributeLKI), preList); + boolean abort = !noTributeLKI.canReceiveCounters(counterType); + + game.getAction().checkStaticAbilities(false); + // clear delayed changes, this check should not have updated the view + game.getTracker().clearDelayed(); + // need to unfreeze tracker + game.getTracker().unfreeze(); + // check if it can recive the Tribute - if (!noTributeLKI.canReceiveCounters(counterType)) { + if (abort) { continue; } @@ -225,9 +248,9 @@ public class CountersPutEffect extends SpellAbilityEffect { } if (sa.hasParam("Monstrosity")) { tgtCard.setMonstrous(true); - tgtCard.setMonstrosityNum(counterAmount); final Map runParams = Maps.newHashMap(); runParams.put("Card", tgtCard); + runParams.put("MonstrosityAmount", counterAmount); game.getTriggerHandler().runTrigger(TriggerType.BecomeMonstrous, runParams, false); } if (sa.hasParam("Renown")) { diff --git a/forge-game/src/main/java/forge/game/ability/effects/CountersPutOrRemoveEffect.java b/forge-game/src/main/java/forge/game/ability/effects/CountersPutOrRemoveEffect.java index d5d34ae56cc..9273c1ce2c6 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/CountersPutOrRemoveEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/CountersPutOrRemoveEffect.java @@ -57,6 +57,13 @@ public class CountersPutOrRemoveEffect extends SpellAbilityEffect { } for (final Card tgtCard : getDefinedCardsOrTargeted(sa)) { + Card gameCard = game.getCardState(tgtCard, null); + // gameCard is LKI in that case, the card is not in game anymore + // or the timestamp did change + // this should check Self too + if (gameCard == null || !tgtCard.equalsWithTimestamp(gameCard)) { + continue; + } if (!sa.usesTargeting() || tgtCard.canBeTargetedBy(sa)) { if (tgtCard.hasCounters()) { if (sa.hasParam("EachExistingCounter")) { diff --git a/forge-game/src/main/java/forge/game/ability/effects/CountersRemoveEffect.java b/forge-game/src/main/java/forge/game/ability/effects/CountersRemoveEffect.java index 12f25d8aa2d..1b6f684af87 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/CountersRemoveEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/CountersRemoveEffect.java @@ -108,8 +108,15 @@ public class CountersRemoveEffect extends SpellAbilityEffect { } for (final Card tgtCard : getTargetCards(sa)) { + Card gameCard = game.getCardState(tgtCard, null); + // gameCard is LKI in that case, the card is not in game anymore + // or the timestamp did change + // this should check Self too + if (gameCard == null || !tgtCard.equalsWithTimestamp(gameCard)) { + continue; + } if (!sa.usesTargeting() || tgtCard.canBeTargetedBy(sa)) { - final Zone zone = game.getZoneOf(tgtCard); + final Zone zone = game.getZoneOf(gameCard); if (type.equals("All")) { for (Map.Entry e : tgtCard.getCounters().entrySet()) { tgtCard.subtractCounter(e.getKey(), e.getValue()); diff --git a/forge-game/src/main/java/forge/game/card/Card.java b/forge-game/src/main/java/forge/game/card/Card.java index 304a14b0a4b..b3e2ef8b34f 100644 --- a/forge-game/src/main/java/forge/game/card/Card.java +++ b/forge-game/src/main/java/forge/game/card/Card.java @@ -154,7 +154,6 @@ public class Card extends GameEntity implements Comparable { private boolean unearthed; private boolean monstrous = false; - private int monstrosityNum = 0; private boolean renowned = false; @@ -4725,13 +4724,6 @@ public class Card extends GameEntity implements Comparable { monstrous = monstrous0; } - public final int getMonstrosityNum() { - return monstrosityNum; - } - public final void setMonstrosityNum(final int num) { - monstrosityNum = num; - } - public final boolean isRenowned() { return renowned; } diff --git a/forge-game/src/main/java/forge/game/card/CardFactoryUtil.java b/forge-game/src/main/java/forge/game/card/CardFactoryUtil.java index 4f1c987634e..3da41b1252d 100644 --- a/forge-game/src/main/java/forge/game/card/CardFactoryUtil.java +++ b/forge-game/src/main/java/forge/game/card/CardFactoryUtil.java @@ -1017,11 +1017,6 @@ public class CardFactoryUtil { return 0; } - // Count$MonstrosityMagnitude - if (sq[0].contains("MonstrosityMagnitude")) { - return doXMath(c.getMonstrosityNum(), m, c); - } - // Count$Chroma. // Count$Devotion. if (sq[0].contains("Chroma") || sq[0].equals("Devotion")) { diff --git a/forge-game/src/main/java/forge/game/trigger/TriggerBecomeMonstrous.java b/forge-game/src/main/java/forge/game/trigger/TriggerBecomeMonstrous.java index e0ee286c3d1..5a70ce99648 100644 --- a/forge-game/src/main/java/forge/game/trigger/TriggerBecomeMonstrous.java +++ b/forge-game/src/main/java/forge/game/trigger/TriggerBecomeMonstrous.java @@ -17,6 +17,8 @@ */ package forge.game.trigger; +import java.util.Map; + import forge.game.card.Card; import forge.game.spellability.SpellAbility; @@ -42,15 +44,15 @@ public class TriggerBecomeMonstrous extends Trigger { * @param intrinsic * the intrinsic */ - public TriggerBecomeMonstrous(final java.util.Map params, final Card host, final boolean intrinsic) { + public TriggerBecomeMonstrous(Map params, final Card host, final boolean intrinsic) { super(params, host, intrinsic); } /** {@inheritDoc} */ @Override - public final boolean performTest(final java.util.Map runParams2) { - if (this.mapParams.containsKey("ValidCard")) { - if (!matchesValid(runParams2.get("Card"), this.mapParams.get("ValidCard").split(","), + public final boolean performTest(Map runParams2) { + if (hasParam("ValidCard")) { + if (!matchesValid(runParams2.get("Card"), getParam("ValidCard").split(","), this.getHostCard())) { return false; } @@ -62,7 +64,8 @@ public class TriggerBecomeMonstrous extends Trigger { /** {@inheritDoc} */ @Override public final void setTriggeringObjects(final SpellAbility sa) { - sa.setTriggeringObject("Card", this.getRunParams().get("Card")); + sa.setTriggeringObject("Card", getRunParams().get("Card")); + sa.setTriggeringObject("MonstrosityAmount", getRunParams().get("MonstrosityAmount")); } @Override diff --git a/forge-game/src/main/java/forge/trackable/Tracker.java b/forge-game/src/main/java/forge/trackable/Tracker.java index e65be26c6f8..25ce378f68c 100644 --- a/forge-game/src/main/java/forge/trackable/Tracker.java +++ b/forge-game/src/main/java/forge/trackable/Tracker.java @@ -52,6 +52,10 @@ public class Tracker { delayedPropChanges.add(new DelayedPropChange(object, prop, value)); } + public void clearDelayed() { + delayedPropChanges.clear(); + } + private class DelayedPropChange { private final TrackableObject object; private final TrackableProperty prop; From e4b7c105b1bda928ab869de5a40b47c681bf2bca Mon Sep 17 00:00:00 2001 From: Hanmac Date: Sun, 20 May 2018 11:33:43 +0200 Subject: [PATCH 2/3] cards: update Monstrosity using TriggeredCount --- forge-gui/res/cardsfolder/h/hydra_broodmaster.txt | 2 +- forge-gui/res/cardsfolder/p/polukranos_world_eater.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/forge-gui/res/cardsfolder/h/hydra_broodmaster.txt b/forge-gui/res/cardsfolder/h/hydra_broodmaster.txt index b3d4e020183..9358cb9dba6 100644 --- a/forge-gui/res/cardsfolder/h/hydra_broodmaster.txt +++ b/forge-gui/res/cardsfolder/h/hydra_broodmaster.txt @@ -6,7 +6,7 @@ K:Monstrosity:X:X X G T:Mode$ BecomeMonstrous | ValidCard$ Card.Self | TriggerZones$ Battlefield | Execute$ TrigToken | TriggerDescription$ When CARDNAME becomes monstrous, create X X/X green Hydra creature tokens. SVar:TrigToken:DB$ Token | TokenAmount$ MonstrosityX | TokenName$ Hydra | TokenTypes$ Creature,Hydra | TokenOwner$ You | TokenColors$ Green | TokenPower$ MonstrosityX | TokenToughness$ MonstrosityX | TokenImage$ g x x hydra | References$ MonstrosityX SVar:X:Count$xPaid -SVar:MonstrosityX:Count$MonstrosityMagnitude +SVar:MonstrosityX:TriggerCount$MonstrosityAmount DeckHas:Ability$Counters & Ability$Token SVar:Picture:http://www.wizards.com/global/images/magic/general/hydra_broodmaster.jpg Oracle:{X}{X}{G}: Monstrosity X. (If this creature isn't monstrous, put X +1/+1 counters on it and it becomes monstrous.)\nWhen Hydra Broodmaster becomes monstrous, create X X/X green Hydra creature tokens. diff --git a/forge-gui/res/cardsfolder/p/polukranos_world_eater.txt b/forge-gui/res/cardsfolder/p/polukranos_world_eater.txt index 4707eff3bbe..a7f63e3a4b8 100644 --- a/forge-gui/res/cardsfolder/p/polukranos_world_eater.txt +++ b/forge-gui/res/cardsfolder/p/polukranos_world_eater.txt @@ -9,7 +9,7 @@ SVar:DBDmg:DB$ RepeatEach | RepeatSubAbility$ PolukranosFight | UseImprinted$ Tr SVar:PolukranosFight:DB$ DealDamage | DamageSource$ Imprinted | NumDmg$ Y | References$ Y | Defined$ Self | StackDescription$ None SVar:X:Count$xPaid SVar:Y:Imprinted$CardPower -SVar:MonstrosityX:Count$MonstrosityMagnitude +SVar:MonstrosityX:TriggerCount$MonstrosityAmount SVar:MaxTgts:Count$Valid Creature.OppCtrl SVar:MonstrosityAILogic:Polukranos DeckHas:Ability$Counters From 57af402bcf5b4bf9b637d15b6d9c38085e57dd85 Mon Sep 17 00:00:00 2001 From: Hanmac Date: Sun, 20 May 2018 11:37:28 +0200 Subject: [PATCH 3/3] cards: PutCounter use Triggered LKICopy --- forge-gui/res/cardsfolder/a/aurification.txt | 2 +- forge-gui/res/cardsfolder/b/bogardan_phoenix.txt | 2 +- forge-gui/res/cardsfolder/c/curse_of_predation.txt | 2 +- forge-gui/res/cardsfolder/c/curse_of_stalked_prey.txt | 2 +- forge-gui/res/cardsfolder/d/durable_handicraft.txt | 2 +- forge-gui/res/cardsfolder/e/epochrasite.txt | 2 +- forge-gui/res/cardsfolder/f/ferocity.txt | 4 ++-- forge-gui/res/cardsfolder/f/freyalises_winds.txt | 2 +- forge-gui/res/cardsfolder/g/gleam_of_battle.txt | 2 +- forge-gui/res/cardsfolder/j/juniper_order_ranger.txt | 4 ++-- forge-gui/res/cardsfolder/m/matopi_golem.txt | 2 +- forge-gui/res/cardsfolder/m/mephidross_vampire.txt | 2 +- forge-gui/res/cardsfolder/m/mighty_emergence.txt | 2 +- forge-gui/res/cardsfolder/m/mindbender_spores.txt | 2 +- forge-gui/res/cardsfolder/n/necropolis_regent.txt | 2 +- forge-gui/res/cardsfolder/o/obelisk_spider.txt | 2 +- .../res/cardsfolder/o/olivia_mobilized_for_war.txt | 4 ++-- forge-gui/res/cardsfolder/q/quagmire_lamprey.txt | 2 +- forge-gui/res/cardsfolder/r/rakish_heir.txt | 2 +- forge-gui/res/cardsfolder/r/rite_of_passage.txt | 2 +- forge-gui/res/cardsfolder/s/salt_road_ambushers.txt | 2 +- .../res/cardsfolder/s/shaman_of_the_great_hunt.txt | 2 +- forge-gui/res/cardsfolder/s/sigil_captain.txt | 2 +- forge-gui/res/cardsfolder/s/skeleton_scavengers.txt | 2 +- forge-gui/res/cardsfolder/s/spirit_shackle.txt | 2 +- forge-gui/res/cardsfolder/s/stensia.txt | 10 +++++----- forge-gui/res/cardsfolder/s/stensia_masquerade.txt | 2 +- forge-gui/res/cardsfolder/t/temporal_distortion.txt | 6 +++--- forge-gui/res/cardsfolder/w/woolly_razorback.txt | 2 +- 29 files changed, 38 insertions(+), 38 deletions(-) diff --git a/forge-gui/res/cardsfolder/a/aurification.txt b/forge-gui/res/cardsfolder/a/aurification.txt index 56b7164fdf8..2477f5b7d02 100644 --- a/forge-gui/res/cardsfolder/a/aurification.txt +++ b/forge-gui/res/cardsfolder/a/aurification.txt @@ -2,7 +2,7 @@ Name:Aurification ManaCost:2 W W Types:Enchantment T:Mode$ DamageDone | ValidSource$ Creature | ValidTarget$ You | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever a creature deals damage to you, put a gold counter on it. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSource | CounterType$ GOLD | CounterNum$ 1 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ GOLD | CounterNum$ 1 S:Mode$ Continuous | Affected$ Creature.counters_GE1_GOLD | AddType$ Wall | AddKeyword$ Defender | Description$ Each creature with a gold counter on it is a Wall in addition to its other creature types and has defender. (Those creatures can't attack.) T:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Any | ValidCard$ Card.Self | Execute$ TrigRemove | TriggerController$ TriggeredCardController | TriggerDescription$ When CARDNAME leaves the battlefield, remove all gold counters from all creatures. SVar:TrigRemove:DB$ RemoveCounterAll | ValidCards$ Creature | CounterType$ GOLD | AllCounters$ True diff --git a/forge-gui/res/cardsfolder/b/bogardan_phoenix.txt b/forge-gui/res/cardsfolder/b/bogardan_phoenix.txt index 78b6d01277c..f96dea5e4e2 100644 --- a/forge-gui/res/cardsfolder/b/bogardan_phoenix.txt +++ b/forge-gui/res/cardsfolder/b/bogardan_phoenix.txt @@ -6,7 +6,7 @@ K:Flying T:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ TrigReturn | TriggerController$ TriggeredCardController | TriggerDescription$ When CARDNAME dies, exile it if it had a death counter on it. Otherwise, return it to the battlefield under your control and put a death counter on it. SVar:TrigReturn:DB$ ChangeZone | Defined$ TriggeredCard | Origin$ Graveyard | Destination$ Exile | ConditionCheckSVar$ X | ConditionSVarCompare$ GE1 | SubAbility$ DBReturn | References$ X SVar:DBReturn:DB$ ChangeZone | Defined$ TriggeredCard | Origin$ Graveyard | Destination$ Battlefield | ConditionCheckSVar$ X | ConditionSVarCompare$ EQ0 | SubAbility$ DBPutCounter | References$ X -SVar:DBPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ DEATH | CounterNum$ 1 | ConditionCheckSVar$ X | ConditionSVarCompare$ EQ0 | References$ X +SVar:DBPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ DEATH | CounterNum$ 1 | ConditionCheckSVar$ X | ConditionSVarCompare$ EQ0 | References$ X SVar:X:TriggeredCard$CardCounters.DEATH SVar:Picture:http://www.wizards.com/global/images/magic/general/bogardan_phoenix.jpg Oracle:Flying\nWhen Bogardan Phoenix dies, exile it if it had a death counter on it. Otherwise, return it to the battlefield under your control and put a death counter on it. diff --git a/forge-gui/res/cardsfolder/c/curse_of_predation.txt b/forge-gui/res/cardsfolder/c/curse_of_predation.txt index 2bb8154694d..843a044d212 100644 --- a/forge-gui/res/cardsfolder/c/curse_of_predation.txt +++ b/forge-gui/res/cardsfolder/c/curse_of_predation.txt @@ -4,6 +4,6 @@ Types:Enchantment Aura Curse K:Enchant player A:SP$ Attach | Cost$ 2 G | ValidTgts$ Player | AILogic$ Curse T:Mode$ Attacks | ValidCard$ Creature | Attacked$ Player.EnchantedBy | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever a creature attacks enchanted player, put a +1/+1 counter on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredAttacker | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredAttackerLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:Picture:http://www.wizards.com/global/images/magic/general/curse_of_predation.jpg Oracle:Enchant player\nWhenever a creature attacks enchanted player, put a +1/+1 counter on it. diff --git a/forge-gui/res/cardsfolder/c/curse_of_stalked_prey.txt b/forge-gui/res/cardsfolder/c/curse_of_stalked_prey.txt index d6269d7922c..c81c722eb67 100644 --- a/forge-gui/res/cardsfolder/c/curse_of_stalked_prey.txt +++ b/forge-gui/res/cardsfolder/c/curse_of_stalked_prey.txt @@ -4,6 +4,6 @@ Types:Enchantment Aura Curse K:Enchant player A:SP$ Attach | Cost$ 1 R| ValidTgts$ Player | AILogic$ Curse T:Mode$ DamageDone | ValidSource$ Creature | ValidTarget$ Player.EnchantedBy | TriggerZones$ Battlefield | CombatDamage$ True | Execute$ TrigPutCounter | TriggerDescription$ Whenever a creature deals combat damage to enchanted player, put a +1/+1 counter on that creature. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredSource | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:Picture:http://www.wizards.com/global/images/magic/general/curse_of_stalked_prey.jpg Oracle:Enchant player\nWhenever a creature deals combat damage to enchanted player, put a +1/+1 counter on that creature. diff --git a/forge-gui/res/cardsfolder/d/durable_handicraft.txt b/forge-gui/res/cardsfolder/d/durable_handicraft.txt index 0f68c48b2ab..044f0f1a8a5 100644 --- a/forge-gui/res/cardsfolder/d/durable_handicraft.txt +++ b/forge-gui/res/cardsfolder/d/durable_handicraft.txt @@ -2,7 +2,7 @@ Name:Durable Handicraft ManaCost:1 G Types:Enchantment T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Creature.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever a creature enters the battlefield under your control, you may pay {1}. If you do, put a +1/+1 counter on that creature. -SVar:TrigPutCounter:AB$PutCounter | Cost$ 1 | Defined$ TriggeredCard | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:AB$PutCounter | Cost$ 1 | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 1 A:AB$ PutCounterAll | Cost$ 5 G Sac<1/CARDNAME> | ValidCards$ Creature.YouCtrl | CounterType$ P1P1 | CounterNum$ 1 | SpellDescription$ Put a +1/+1 counter on each creature you control. SVar:Picture:http://www.wizards.com/global/images/magic/general/durable_handicraft.jpg Oracle:Whenever a creature enters the battlefield under your control, you may pay {1}. If you do, put a +1/+1 counter on that creature.\n{5}{G}, Sacrifice Durable Handicraft: Put a +1/+1 counter on each creature you control. diff --git a/forge-gui/res/cardsfolder/e/epochrasite.txt b/forge-gui/res/cardsfolder/e/epochrasite.txt index 738c0107081..312a17f1629 100644 --- a/forge-gui/res/cardsfolder/e/epochrasite.txt +++ b/forge-gui/res/cardsfolder/e/epochrasite.txt @@ -5,7 +5,7 @@ PT:1/1 K:etbCounter:P1P1:3:ValidCard$ Card.Self+wasNotCastFromHand:CARDNAME enters the battlefield with three +1/+1 counters on it if you didn't cast it from your hand. T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Graveyard | Execute$ TrigExile | TriggerController$ TriggeredCardController | TriggerDescription$ When CARDNAME dies, exile it with three time counters on it and it gains suspend. SVar:TrigExile:DB$ ChangeZone | Defined$ TriggeredCard | Origin$ Graveyard | Destination$ Exile | SubAbility$ DBPutCounter -SVar:DBPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ TIME | CounterNum$ 3 | SubAbility$ GiveSuspend +SVar:DBPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ TIME | CounterNum$ 3 | SubAbility$ GiveSuspend SVar:GiveSuspend:DB$ Pump | Defined$ TriggeredCard | KW$ Suspend | PumpZone$ Exile | Permanent$ True SVar:Picture:http://www.wizards.com/global/images/magic/general/epochrasite.jpg Oracle:Epochrasite enters the battlefield with three +1/+1 counters on it if you didn't cast it from your hand.\nWhen Epochrasite dies, exile it with three time counters on it and it gains suspend. (At the beginning of your upkeep, remove a time counter. When the last is removed, cast this card without paying its mana cost. It has haste.) diff --git a/forge-gui/res/cardsfolder/f/ferocity.txt b/forge-gui/res/cardsfolder/f/ferocity.txt index dabb59c5c0f..a40272aa0b6 100644 --- a/forge-gui/res/cardsfolder/f/ferocity.txt +++ b/forge-gui/res/cardsfolder/f/ferocity.txt @@ -5,7 +5,7 @@ K:Enchant creature A:SP$ Attach | Cost$ 1 G | ValidTgts$ Creature | AILogic$ Pump T:Mode$ AttackerBlocked | ValidCard$ Card.AttachedBy | Execute$ TrigPutCounter | OptionalDecider$ You | TriggerDescription$ Whenever enchanted creature blocks or becomes blocked, you may put a +1/+1 counter on it. T:Mode$ Blocks | ValidCard$ Card.AttachedBy | Execute$ TrigPutCounter2 | OptionalDecider$ You | Secondary$ True | TriggerDescription$ Whenever enchanted creature blocks or becomes blocked, you may put a +1/+1 counter on it. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredAttacker | CounterType$ P1P1 | CounterNum$ 1 -SVar:TrigPutCounter2:DB$PutCounter | Defined$ TriggeredBlocker | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredAttackerLKICopy | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter2:DB$PutCounter | Defined$ TriggeredBlockerLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:Picture:http://www.wizards.com/global/images/magic/general/ferocity.jpg Oracle:Enchant creature\nWhenever enchanted creature blocks or becomes blocked, you may put a +1/+1 counter on it. diff --git a/forge-gui/res/cardsfolder/f/freyalises_winds.txt b/forge-gui/res/cardsfolder/f/freyalises_winds.txt index ef998414594..5cbe64290cb 100644 --- a/forge-gui/res/cardsfolder/f/freyalises_winds.txt +++ b/forge-gui/res/cardsfolder/f/freyalises_winds.txt @@ -2,7 +2,7 @@ Name:Freyalise's Winds ManaCost:2 G G Types:Enchantment T:Mode$ Taps | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever a permanent becomes tapped, put a wind counter on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ WIND | CounterNum$ 1 +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ WIND | CounterNum$ 1 R:Event$ Untap | ActiveZones$ Battlefield | ValidCard$ Permanent.counters_GE1_WIND | ReplaceWith$ RepRemoveCounter | UntapStep$ True | Description$ If a permanent with a wind counter on it would untap during its controller's untap step, remove all wind counters from it instead. SVar:RepRemoveCounter:DB$ RemoveCounter | Defined$ ReplacedCard | CounterType$ WIND | CounterNum$ All SVar:RemRandomDeck:True diff --git a/forge-gui/res/cardsfolder/g/gleam_of_battle.txt b/forge-gui/res/cardsfolder/g/gleam_of_battle.txt index 21069cea525..ebadf20434e 100644 --- a/forge-gui/res/cardsfolder/g/gleam_of_battle.txt +++ b/forge-gui/res/cardsfolder/g/gleam_of_battle.txt @@ -2,7 +2,7 @@ Name:Gleam of Battle ManaCost:4 R W Types:Enchantment T:Mode$ Attacks | ValidCard$ Creature.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigPut | TriggerDescription$ Whenever a creature you control attacks, put a +1/+1 counter on it. -SVar:TrigPut:DB$ PutCounter | Defined$ TriggeredAttacker | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPut:DB$ PutCounter | Defined$ TriggeredAttackerLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:PlayMain1:TRUE DeckHas:Ability$Counters SVar:Picture:http://www.wizards.com/global/images/magic/general/gleam_of_battle.jpg diff --git a/forge-gui/res/cardsfolder/j/juniper_order_ranger.txt b/forge-gui/res/cardsfolder/j/juniper_order_ranger.txt index bdf758f1288..1a388fb80dc 100644 --- a/forge-gui/res/cardsfolder/j/juniper_order_ranger.txt +++ b/forge-gui/res/cardsfolder/j/juniper_order_ranger.txt @@ -3,8 +3,8 @@ ManaCost:3 G W Types:Creature Human Knight PT:2/4 T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Creature.Other+YouCtrl | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever another creature enters the battlefield under your control, put a +1/+1 counter on that creature and a +1/+1 counter on CARDNAME. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredCard | CounterType$ P1P1 | CounterNum$ 1 | SubAbility$ DBPutCounter -SVar:DBPutCounter:DB$PutCounter | Defined$ Self | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 1 | SubAbility$ DBPutCounter +SVar:DBPutCounter:DB$PutCounter | Defined$ Self.StrictlySelf | CounterType$ P1P1 | CounterNum$ 1 SVar:BuffedBy:Creature SVar:Picture:http://www.wizards.com/global/images/magic/general/juniper_order_ranger.jpg Oracle:Whenever another creature enters the battlefield under your control, put a +1/+1 counter on that creature and a +1/+1 counter on Juniper Order Ranger. diff --git a/forge-gui/res/cardsfolder/m/matopi_golem.txt b/forge-gui/res/cardsfolder/m/matopi_golem.txt index 6cece8d30e9..fb65194b3f1 100644 --- a/forge-gui/res/cardsfolder/m/matopi_golem.txt +++ b/forge-gui/res/cardsfolder/m/matopi_golem.txt @@ -3,7 +3,7 @@ ManaCost:5 Types:Artifact Creature Golem PT:3/3 A:AB$ Regenerate | Cost$ 1 | RegenerationTrigger$ TrigPutCounter | References$ TrigPutCounter | SpellDescription$ Regenerate CARDNAME. When it regenerates this way, put a -1/-1 counter on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ M1M1 | CounterNum$ 1 | SpellDescription$ When it regenerates this way, put a -1/-1 counter on it. +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ M1M1 | CounterNum$ 1 | SpellDescription$ When it regenerates this way, put a -1/-1 counter on it. DeckHas:Ability$Counters SVar:Picture:http://www.wizards.com/global/images/magic/general/matopi_golem.jpg Oracle:{1}: Regenerate Matopi Golem. When it regenerates this way, put a -1/-1 counter on it. diff --git a/forge-gui/res/cardsfolder/m/mephidross_vampire.txt b/forge-gui/res/cardsfolder/m/mephidross_vampire.txt index 0e8ae43ed9b..301f9be896f 100644 --- a/forge-gui/res/cardsfolder/m/mephidross_vampire.txt +++ b/forge-gui/res/cardsfolder/m/mephidross_vampire.txt @@ -5,7 +5,7 @@ PT:3/4 K:Flying S:Mode$ Continuous | Affected$ Creature.YouCtrl | AddType$ Vampire | AddTrigger$ MephidrossPutCounter | AddSVar$ MephidrossCounters | Description$ Each creature you control is a Vampire in addition to its other types and has "Whenever this creature deals damage to a creature, put a +1/+1 counter on this creature." SVar:MephidrossPutCounter:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Creature | Execute$ MephidrossCounters | TriggerDescription$ Whenever CARDNAME deals damage to a creature, put a +1/+1 counter on this creature. -SVar:MephidrossCounters:DB$ PutCounter | Defined$ TriggeredSource | CounterType$ P1P1 | CounterNum$ 1 +SVar:MephidrossCounters:DB$ PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:PlayMain1:TRUE SVar:Picture:http://www.wizards.com/global/images/magic/general/mephidross_vampire.jpg Oracle:Flying\nEach creature you control is a Vampire in addition to its other creature types and has "Whenever this creature deals damage to a creature, put a +1/+1 counter on this creature." diff --git a/forge-gui/res/cardsfolder/m/mighty_emergence.txt b/forge-gui/res/cardsfolder/m/mighty_emergence.txt index a1b4f5230f9..136d2675c52 100644 --- a/forge-gui/res/cardsfolder/m/mighty_emergence.txt +++ b/forge-gui/res/cardsfolder/m/mighty_emergence.txt @@ -2,7 +2,7 @@ Name:Mighty Emergence ManaCost:2 G Types:Enchantment T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Creature.powerGE5+YouCtrl | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever a creature with power 5 or greater enters the battlefield under your control, you may put two +1/+1 counters on it. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredCard | CounterType$ P1P1 | CounterNum$ 2 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 2 SVar:RemRandomDeck:True SVar:Picture:http://www.wizards.com/global/images/magic/general/mighty_emergence.jpg Oracle:Whenever a creature with power 5 or greater enters the battlefield under your control, you may put two +1/+1 counters on it. diff --git a/forge-gui/res/cardsfolder/m/mindbender_spores.txt b/forge-gui/res/cardsfolder/m/mindbender_spores.txt index e12e2664f26..07618c1c925 100644 --- a/forge-gui/res/cardsfolder/m/mindbender_spores.txt +++ b/forge-gui/res/cardsfolder/m/mindbender_spores.txt @@ -5,7 +5,7 @@ PT:0/1 K:Defender K:Flying T:Mode$ AttackerBlocked | ValidCard$ Creature | ValidBlocker$ Card.Self | Execute$ AddSpores | TriggerDescription$ Whenever CARDNAME blocks a creature, put four fungus counters on that creature. The creature gains "This creature doesn't untap during your untap step if it has a fungus counter on it" and "At the beginning of your upkeep, remove a fungus counter from this creature." -SVar:AddSpores:DB$ PutCounter | CounterType$ FUNGUS | CounterNum$ 4 | Defined$ TriggeredAttacker | SubAbility$ AddFungalEffects +SVar:AddSpores:DB$ PutCounter | CounterType$ FUNGUS | CounterNum$ 4 | Defined$ TriggeredAttackerLKICopy | SubAbility$ AddFungalEffects SVar:AddFungalEffects:DB$ Animate | Defined$ TriggeredAttacker | staticAbilities$ FungalFunk | Triggers$ TrigSporeUpkeep | sVars$ LoseSpores | Permanent$ True SVar:FungalFunk:Mode$ Continuous | Affected$ Card.Self+counters_GE1_FUNGUS | AddHiddenKeyword$ CARDNAME doesn't untap during your untap step. | Description$ CARDNAME doesn't untap during your untap step if it has a fungus counter on it. SVar:TrigSporeUpkeep:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ LoseSpores | TriggerDescription$ At the beginning of your upkeep, remove a fungus counter from CARDNAME. diff --git a/forge-gui/res/cardsfolder/n/necropolis_regent.txt b/forge-gui/res/cardsfolder/n/necropolis_regent.txt index 9c5f32ef6b8..2afbd0bfb82 100644 --- a/forge-gui/res/cardsfolder/n/necropolis_regent.txt +++ b/forge-gui/res/cardsfolder/n/necropolis_regent.txt @@ -4,7 +4,7 @@ Types:Creature Vampire PT:6/5 K:Flying T:Mode$ DamageDone | ValidSource$ Creature.YouCtrl | ValidTarget$ Player | TriggerZones$ Battlefield | CombatDamage$ True | Execute$ TrigPutCounter | TriggerDescription$ Whenever a creature you control deals combat damage to a player, put that many +1/+1 counters on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredSource | CounterType$ P1P1 | CounterNum$ X | References$ X +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ P1P1 | CounterNum$ X | References$ X SVar:X:TriggerCount$DamageAmount SVar:Picture:http://www.wizards.com/global/images/magic/general/necropolis_regent.jpg Oracle:Flying\nWhenever a creature you control deals combat damage to a player, put that many +1/+1 counters on it. diff --git a/forge-gui/res/cardsfolder/o/obelisk_spider.txt b/forge-gui/res/cardsfolder/o/obelisk_spider.txt index 9ef98709137..89b2df21f08 100644 --- a/forge-gui/res/cardsfolder/o/obelisk_spider.txt +++ b/forge-gui/res/cardsfolder/o/obelisk_spider.txt @@ -4,7 +4,7 @@ Types:Creature Spider PT:1/4 K:Reach T:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Creature | CombatDamage$ True | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever CARDNAME deals combat damage to a creature, put a -1/-1 counter on that creature. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredTarget | CounterType$ M1M1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredTargetLKICopy | CounterType$ M1M1 | CounterNum$ 1 T:Mode$ CounterAddedOnce | ValidCard$ Creature | ValidSource$ Card.YouCtrl | CounterType$ M1M1 | TriggerZones$ Battlefield | Execute$ TrigDrain | TriggerDescription$ Whenever you put one or more -1/-1 counters on a creature, each opponent loses 1 life and you gain 1 life. SVar:TrigDrain:DB$ LoseLife | Defined$ Player.Opponent | LifeAmount$ 1 | SubAbility$ DBGainLife SVar:DBGainLife:DB$ GainLife | Defined$ You | LifeAmount$ 1 diff --git a/forge-gui/res/cardsfolder/o/olivia_mobilized_for_war.txt b/forge-gui/res/cardsfolder/o/olivia_mobilized_for_war.txt index 803252f4f71..064b84a9c6c 100644 --- a/forge-gui/res/cardsfolder/o/olivia_mobilized_for_war.txt +++ b/forge-gui/res/cardsfolder/o/olivia_mobilized_for_war.txt @@ -5,9 +5,9 @@ PT:3/3 K:Flying T:Mode$ ChangesZone | ValidCard$ Creature.Other+YouCtrl | Origin$ Any | Destination$ Battlefield | Execute$ TrigDiscard | TriggerZones$ Battlefield | OptionalDecider$ You | TriggerDescription$ Whenever another creature enters the battlefield under your control, you may discard a card. If you do, put a +1/+1 counter on that creature, it gains haste until end of turn, and it becomes a vampire in addition to its other types. SVar:TrigDiscard:DB$ Discard | Defined$ You | NumCards$ 1 | Mode$ TgtChoose | RememberDiscarded$ True | SubAbility$ DBPutCounter -SVar:DBPutCounter:DB$PutCounter | Defined$ TriggeredCard | CounterType$ P1P1 | CounterNum$ 1 | ConditionDefined$ Remembered | ConditionPresent$ Card | ConditionCompare$ GE1 | SubAbility$ DBPump +SVar:DBPutCounter:DB$PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 1 | ConditionDefined$ Remembered | ConditionPresent$ Card | ConditionCompare$ GE1 | SubAbility$ DBPump SVar:DBPump:DB$ Pump | Defined$ TriggeredCard | KW$ Haste | ConditionDefined$ Remembered | ConditionPresent$ Card | ConditionCompare$ GE1 | SubAbility$ DBAnimate SVar:DBAnimate:DB$ Animate | Defined$ TriggeredCard | Types$ Vampire | Permanent$ True | ConditionDefined$ Remembered | ConditionPresent$ Card | ConditionCompare$ GE1 | SubAbility$ DBCleanup SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True SVar:Picture:http://www.wizards.com/global/images/magic/general/olivia_mobilized_for_war.jpg -Oracle:Flying\nWhenever another creature enters the battlefield under your control, you may discard a card. If you do, put a +1/+1 counter on that creature, it gains haste until end of turn, and it becomes a vampire in addition to its other types. +Oracle:Flying\nWhenever another creature enters the battlefield under your control, you may discard a card. If you do, put a +1/+1 counter on that creature, it gains haste until end of turn, and it becomes a Vampire in addition to its other types. diff --git a/forge-gui/res/cardsfolder/q/quagmire_lamprey.txt b/forge-gui/res/cardsfolder/q/quagmire_lamprey.txt index 554ff193325..7d20ac5f4d8 100644 --- a/forge-gui/res/cardsfolder/q/quagmire_lamprey.txt +++ b/forge-gui/res/cardsfolder/q/quagmire_lamprey.txt @@ -3,7 +3,7 @@ ManaCost:2 B Types:Creature Fish PT:1/1 T:Mode$ AttackerBlockedByCreature | ValidCard$ Card.Self | ValidBlocker$ Creature | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever CARDNAME becomes blocked by a creature, put a -1/-1 counter on that creature. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredBlocker | CounterType$ M1M1 | CounterNum$ 1 | IsCurse$ True +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredBlockerLKICopy | CounterType$ M1M1 | CounterNum$ 1 | IsCurse$ True SVar:HasAttackEffect:Blocked SVar:Picture:http://www.wizards.com/global/images/magic/general/quagmire_lamprey.jpg Oracle:Whenever Quagmire Lamprey becomes blocked by a creature, put a -1/-1 counter on that creature. diff --git a/forge-gui/res/cardsfolder/r/rakish_heir.txt b/forge-gui/res/cardsfolder/r/rakish_heir.txt index ce054d0f76b..5b6365aba26 100644 --- a/forge-gui/res/cardsfolder/r/rakish_heir.txt +++ b/forge-gui/res/cardsfolder/r/rakish_heir.txt @@ -3,7 +3,7 @@ ManaCost:2 R Types:Creature Vampire PT:2/2 T:Mode$ DamageDone | ValidSource$ Vampire.YouCtrl | ValidTarget$ Player | CombatDamage$ True | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever a Vampire you control deals combat damage to a player, put a +1/+1 counter on it. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSource | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:PlayMain1:TRUE SVar:Picture:http://www.wizards.com/global/images/magic/general/rakish_heir.jpg Oracle:Whenever a Vampire you control deals combat damage to a player, put a +1/+1 counter on it. diff --git a/forge-gui/res/cardsfolder/r/rite_of_passage.txt b/forge-gui/res/cardsfolder/r/rite_of_passage.txt index 3485a6876d3..19b58863099 100644 --- a/forge-gui/res/cardsfolder/r/rite_of_passage.txt +++ b/forge-gui/res/cardsfolder/r/rite_of_passage.txt @@ -2,6 +2,6 @@ Name:Rite of Passage ManaCost:2 G Types:Enchantment T:Mode$ DamageDoneOnce | ValidTarget$ Creature.YouCtrl | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever a creature you control is dealt damage, put a +1/+1 counter on it. (The damage is dealt before the counter is put on.) -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredTarget | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredTargetLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:Picture:http://www.wizards.com/global/images/magic/general/rite_of_passage.jpg Oracle:Whenever a creature you control is dealt damage, put a +1/+1 counter on it. (The damage is dealt before the counter is put on.) diff --git a/forge-gui/res/cardsfolder/s/salt_road_ambushers.txt b/forge-gui/res/cardsfolder/s/salt_road_ambushers.txt index e578eef3dc9..b3b67aa2787 100644 --- a/forge-gui/res/cardsfolder/s/salt_road_ambushers.txt +++ b/forge-gui/res/cardsfolder/s/salt_road_ambushers.txt @@ -4,7 +4,7 @@ Types:Creature Hound Warrior PT:3/3 K:Megamorph:3 G G T:Mode$ TurnFaceUp | ValidCard$ Permanent.Creature+YouCtrl+Other | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever another permanent you control is turned face up, if it's a creature, put two +1/+1 counters on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ P1P1 | CounterNum$ 2 | ConditionDefined$ TriggeredCard | ConditionPresent$ Creature +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 2 | ConditionDefined$ TriggeredCard | ConditionPresent$ Creature DeckHas:Ability$Counters SVar:Picture:http://www.wizards.com/global/images/magic/general/salt_road_ambushers.jpg Oracle:Whenever another permanent you control is turned face up, if it's a creature, put two +1/+1 counters on it.\nMegamorph {3}{G}{G} (You may cast this card face down as a 2/2 creature for {3}. Turn it face up any time for its megamorph cost and put a +1/+1 counter on it.) diff --git a/forge-gui/res/cardsfolder/s/shaman_of_the_great_hunt.txt b/forge-gui/res/cardsfolder/s/shaman_of_the_great_hunt.txt index f9785899e9d..1f0bea8a603 100644 --- a/forge-gui/res/cardsfolder/s/shaman_of_the_great_hunt.txt +++ b/forge-gui/res/cardsfolder/s/shaman_of_the_great_hunt.txt @@ -6,6 +6,6 @@ K:Haste T:Mode$ DamageDone | ValidSource$ Creature.YouCtrl | ValidTarget$ Player | CombatDamage$ True | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever a creature you control deals combat damage to a player, put a +1/+1 counter on it. A:AB$ Draw | Cost$ 2 UG UG | NumCards$ X | References$ X | IsPresent$ Creature.YouCtrl+powerGE4 | PrecostDesc$ Ferocious — | SpellDescription$ Draw a card for each creature with power 4 or greater you control. SVar:X:Count$Valid Creature.powerGE4+YouCtrl -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSource | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ P1P1 | CounterNum$ 1 SVar:Picture:http://www.wizards.com/global/images/magic/general/shaman_of_the_great_hunt.jpg Oracle:Haste\nWhenever a creature you control deals combat damage to a player, put a +1/+1 counter on it.\nFerocious — {2}{G/U}{G/U}: Draw a card for each creature you control with power 4 or greater. diff --git a/forge-gui/res/cardsfolder/s/sigil_captain.txt b/forge-gui/res/cardsfolder/s/sigil_captain.txt index a9082fa2fc5..549ad5bdc45 100644 --- a/forge-gui/res/cardsfolder/s/sigil_captain.txt +++ b/forge-gui/res/cardsfolder/s/sigil_captain.txt @@ -3,6 +3,6 @@ ManaCost:1 G W W Types:Creature Rhino Soldier PT:3/3 T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Creature.powerEQ1+toughnessEQ1+Other+YouCtrl | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever a creature enters the battlefield under your control, if that creature is 1/1, put two +1/+1 counters on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ P1P1 | CounterNum$ 2 +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 2 SVar:Picture:http://www.wizards.com/global/images/magic/general/sigil_captain.jpg Oracle:Whenever a creature enters the battlefield under your control, if that creature is 1/1, put two +1/+1 counters on it. diff --git a/forge-gui/res/cardsfolder/s/skeleton_scavengers.txt b/forge-gui/res/cardsfolder/s/skeleton_scavengers.txt index 1c92120167e..6830d232201 100644 --- a/forge-gui/res/cardsfolder/s/skeleton_scavengers.txt +++ b/forge-gui/res/cardsfolder/s/skeleton_scavengers.txt @@ -4,7 +4,7 @@ Types:Creature Skeleton PT:0/0 K:etbCounter:P1P1:1 A:AB$ Regenerate | Cost$ X | CostDesc$ Pay {1} for each +1/+1 counter on CARDNAME: | References$ X,TrigPutCounter | RegenerationTrigger$ TrigPutCounter | SpellDescription$ Regenerate CARDNAME. When it regenerates this way, put a +1/+1 counter on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ P1P1 | CounterNum$ 1 | SpellDescription$ When it regenerates this way, put a +1/+1 counter on it. +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ P1P1 | CounterNum$ 1 | SpellDescription$ When it regenerates this way, put a +1/+1 counter on it. SVar:X:Count$CardCounters.P1P1 DeckHas:Ability$Counters SVar:Picture:http://www.wizards.com/global/images/magic/general/skeleton_scavengers.jpg diff --git a/forge-gui/res/cardsfolder/s/spirit_shackle.txt b/forge-gui/res/cardsfolder/s/spirit_shackle.txt index 7e10de65d4d..622380ba88e 100644 --- a/forge-gui/res/cardsfolder/s/spirit_shackle.txt +++ b/forge-gui/res/cardsfolder/s/spirit_shackle.txt @@ -4,6 +4,6 @@ Types:Enchantment Aura K:Enchant creature A:SP$ Attach | Cost$ B B | ValidTgts$ Creature | AILogic$ Curse T:Mode$ Taps | ValidCard$ Card.AttachedBy | TriggerZones$ Battlefield | Execute$ TrigPutCounter | TriggerDescription$ Whenever enchanted creature becomes tapped, put a -0/-2 counter on it. -SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCard | CounterType$ M0M2 | CounterNum$ 1 +SVar:TrigPutCounter:DB$ PutCounter | Defined$ TriggeredCardLKICopy | CounterType$ M0M2 | CounterNum$ 1 SVar:Picture:http://www.wizards.com/global/images/magic/general/spirit_shackle.jpg Oracle:Enchant creature\nWhenever enchanted creature becomes tapped, put a -0/-2 counter on it. diff --git a/forge-gui/res/cardsfolder/s/stensia.txt b/forge-gui/res/cardsfolder/s/stensia.txt index d92457e26a2..dccfc113879 100644 --- a/forge-gui/res/cardsfolder/s/stensia.txt +++ b/forge-gui/res/cardsfolder/s/stensia.txt @@ -2,11 +2,11 @@ Name:Stensia ManaCost:no cost Types:Plane Innistrad T:Mode$ DamageDone | ValidSource$ Creature.IsNotRemembered | ValidTarget$ Player | Execute$ TrigPutCounter | TriggerZones$ Command | TriggerDescription$ Whenever a creature deals damage to one or more players for the first time each turn, put a +1/+1 counter on it. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSource | CounterType$ P1P1 | CounterNum$ 1 | RememberCards$ True +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ P1P1 | CounterNum$ 1 | RememberCards$ True T:Mode$ Phase | Phase$ End of Turn | Execute$ DBCleanup | TriggerZones$ Command | Static$ True SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True -T:Mode$ PlanarDice | Result$ Chaos | TriggerZones$ Command | Execute$ RolledChaos | TriggerDescription$ Whenever you roll {CHAOS}, each creature you control gains "{T}: This creature deals 1 damage to target player" until end of turn. -SVar:RolledChaos:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Abilities$ LVAbs | SpellDescription$ Until end of turn, creatures you control gain "{T}: This creature deals 1 damage to target player." -SVar:LVAbs:AB$ DealDamage | Cost$ T | ValidTgts$ Player | TgtPrompt$ Select target player | NumDmg$ 1 | SpellDescription$ CARDNAME deals 1 damage to target player. +T:Mode$ PlanarDice | Result$ Chaos | TriggerZones$ Command | Execute$ RolledChaos | TriggerDescription$ Whenever you roll {CHAOS}, each creature you control gains "{T}: This creature deals 1 damage to target player or planeswalker" until end of turn. +SVar:RolledChaos:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Abilities$ LVAbs | SpellDescription$ Until end of turn, creatures you control gain "{T}: This creature deals 1 damage to target player or planeswalker." +SVar:LVAbs:AB$ DealDamage | Cost$ T | ValidTgts$ Player,Planeswalker | TgtPrompt$ Select target player or planeswalker | NumDmg$ 1 | SpellDescription$ CARDNAME deals 1 damage to target player or planeswalker. SVar:Picture:http://www.wizards.com/global/images/magic/general/stensia.jpg -Oracle:Whenever a creature deals damage to one or more players for the first time each turn, put a +1/+1 counter on it.\nWhenever you roll {CHAOS}, each creature you control gains "{T}: This creature deals 1 damage to target player" until end of turn. \ No newline at end of file +Oracle:Whenever a creature deals damage to one or more players for the first time each turn, put a +1/+1 counter on it.\nWhenever you roll {CHAOS}, each creature you control gains "{T}: This creature deals 1 damage to target player or planeswalker" until end of turn. diff --git a/forge-gui/res/cardsfolder/s/stensia_masquerade.txt b/forge-gui/res/cardsfolder/s/stensia_masquerade.txt index cc399384978..0a5b69e6edc 100644 --- a/forge-gui/res/cardsfolder/s/stensia_masquerade.txt +++ b/forge-gui/res/cardsfolder/s/stensia_masquerade.txt @@ -3,7 +3,7 @@ ManaCost:2 R Types:Enchantment S:Mode$ Continuous | Affected$ Creature.attacking+YouCtrl | AddKeyword$ First Strike | Description$ Attacking creatures you control have first strike. T:Mode$ DamageDone | ValidSource$ Vampire.YouCtrl | ValidTarget$ Player | CombatDamage$ True | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever a Vampire you control deals combat damage to a player, put a +1/+1 counter on it. -SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSource | CounterType$ P1P1 | CounterNum$ 1 +SVar:TrigPutCounter:DB$PutCounter | Defined$ TriggeredSourceLKICopy | CounterType$ P1P1 | CounterNum$ 1 K:Madness:2 R SVar:PlayMain1:TRUE DeckHints:Ability$Discard & Type$Vampire diff --git a/forge-gui/res/cardsfolder/t/temporal_distortion.txt b/forge-gui/res/cardsfolder/t/temporal_distortion.txt index d90c40b768c..363aae01793 100644 --- a/forge-gui/res/cardsfolder/t/temporal_distortion.txt +++ b/forge-gui/res/cardsfolder/t/temporal_distortion.txt @@ -1,9 +1,9 @@ Name:Temporal Distortion ManaCost:3 U U Types:Enchantment -T:Mode$ Taps | ValidCard$ Creature,Land | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever a creature or land becomes tapped, put an hourglass counter on it. Each permanent with an hourglass counter on it doesn't untap during its controller's untap step. -SVar:TrigPutCounter:DB$ PutCounter | CounterType$ HOURGLASS | CounterNum$ 1 | Defined$ TriggeredCard -S:Mode$ Continuous | Affected$ Permanent.counters_GE1_HOURGLASS | AddHiddenKeyword$ CARDNAME doesn't untap during your untap step. +T:Mode$ Taps | ValidCard$ Creature,Land | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever a creature or land becomes tapped, put an hourglass counter on it. +SVar:TrigPutCounter:DB$ PutCounter | CounterType$ HOURGLASS | CounterNum$ 1 | Defined$ TriggeredCardLKICopy +S:Mode$ Continuous | Affected$ Permanent.counters_GE1_HOURGLASS | AddHiddenKeyword$ CARDNAME doesn't untap during your untap step. | Description$ Each permanent with an hourglass counter on it doesn't untap during its controller's untap step. T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ Player | Execute$ TrigRemoveCounter | TriggerZones$ Battlefield | TriggerDescription$ At the beginning of each player's upkeep, remove all hourglass counters from permanents that player controls. SVar:TrigRemoveCounter:DB$ RemoveCounterAll | CounterType$ HOURGLASS | AllCounters$ True | ValidCards$ Permanent.ActivePlayerCtrl SVar:RemRandomDeck:True diff --git a/forge-gui/res/cardsfolder/w/woolly_razorback.txt b/forge-gui/res/cardsfolder/w/woolly_razorback.txt index b39815ba5a0..7426bdb436a 100644 --- a/forge-gui/res/cardsfolder/w/woolly_razorback.txt +++ b/forge-gui/res/cardsfolder/w/woolly_razorback.txt @@ -5,7 +5,7 @@ PT:7/7 K:etbCounter:ICE:3 S:Mode$ Continuous | Affected$ Card.Self+counters_GE1_ICE | AddKeyword$ Prevent all combat damage that would be dealt by CARDNAME. & Defender | Description$ As long as CARDNAME has an ice counter on it, prevent all combat damage it would deal and it has defender. T:Mode$ Blocks | ValidCard$ Card.Self | Execute$ TrigRemoveCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME blocks, remove an ice counter from it. -SVar:TrigRemoveCounter:DB$ RemoveCounter | CounterType$ ICE | CounterNum$ 1 | Defined$ TriggeredBlocker +SVar:TrigRemoveCounter:DB$ RemoveCounter | CounterType$ ICE | CounterNum$ 1 | Defined$ TriggeredBlockerLKICopy SVar:HasBlockEffect:TRUE SVar:Picture:http://www.wizards.com/global/images/magic/general/woolly_razorback.jpg Oracle:Woolly Razorback enters the battlefield with three ice counters on it.\nAs long as Woolly Razorback has an ice counter on it, prevent all combat damage it would deal and it has defender.\nWhenever Woolly Razorback blocks, remove an ice counter from it.