From 637234870c0608b97bae604d3e62357b3f0b1235 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Fri, 10 Jun 2022 12:17:41 -0400 Subject: [PATCH 01/24] sarevok_deathbringer.txt --- .../res/cardsfolder/upcoming/sarevok_deathbringer.txt | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/sarevok_deathbringer.txt diff --git a/forge-gui/res/cardsfolder/upcoming/sarevok_deathbringer.txt b/forge-gui/res/cardsfolder/upcoming/sarevok_deathbringer.txt new file mode 100644 index 00000000000..525b86881ca --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/sarevok_deathbringer.txt @@ -0,0 +1,9 @@ +Name:Sarevok, Deathbringer +ManaCost:3 B +Types:Legendary Creature Human Knight +PT:3/4 +T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ Player | Revolt$ None | Execute$ TrigLoseLife | TriggerZones$ Battlefield | TriggerDescription$ At the beginning of each player's end step, if no permanents left the battlefield this turn, that player loses X life, where X is NICKNAME's power. +SVar:TrigLoseLife:DB$ LoseLife | LifeAmount$ X | Defined$ TriggeredPlayer +SVar:X:Count$CardPower +K:Choose a Background +Oracle:At the beginning of each player's end step, if no permanents left the battlefield this turn, that player loses X life, where X is Sarevok's power.\nChoose a Background (You can have a Background as a second commander.) From d3ebc9497f7c655101d878879f0007d7669b7aba Mon Sep 17 00:00:00 2001 From: Northmoc Date: Fri, 10 Jun 2022 12:18:10 -0400 Subject: [PATCH 02/24] CardTraitBase.meetsCommonRequirements support Revolt$ None --- .../src/main/java/forge/game/CardTraitBase.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/forge-game/src/main/java/forge/game/CardTraitBase.java b/forge-game/src/main/java/forge/game/CardTraitBase.java index 1fd4d1d2aa7..652cb6b2fc8 100644 --- a/forge-game/src/main/java/forge/game/CardTraitBase.java +++ b/forge-game/src/main/java/forge/game/CardTraitBase.java @@ -259,6 +259,18 @@ public abstract class CardTraitBase extends GameObject implements IHasCardView, } if (params.containsKey("Revolt")) { if ("True".equalsIgnoreCase(params.get("Revolt")) != hostController.hasRevolt()) return false; + else if ("None".equalsIgnoreCase(params.get("Revolt"))) { + boolean none = true; + for (Player p : game.getRegisteredPlayers()) { + if (p.hasRevolt()) { + none = false; + break; + } + } + if (!none) { + return false; + } + } } if (params.containsKey("Desert")) { if ("True".equalsIgnoreCase(params.get("Desert")) != hostController.hasDesert()) return false; From 74249924da9785ab023b5d30739c49b3014f1d58 Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 08:28:25 +0300 Subject: [PATCH 03/24] - Ignore changes to Maven local settings when preparing a release --- pom.xml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pom.xml b/pom.xml index af7876966f5..6d85ab44c44 100644 --- a/pom.xml +++ b/pom.xml @@ -186,6 +186,9 @@ 2.5 true + + .mvn/local-settings.xml + From 8cc48fdfd7eed5dc6f7f372a990207dcc3fa0a6b Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 09:06:22 +0300 Subject: [PATCH 04/24] - Added puzzles PS_SNC1 and PS_SNC2. --- forge-gui/res/puzzle/PS_SNC1.pzl | 17 +++++++++++++++++ forge-gui/res/puzzle/PS_SNC2.pzl | 17 +++++++++++++++++ 2 files changed, 34 insertions(+) create mode 100644 forge-gui/res/puzzle/PS_SNC1.pzl create mode 100644 forge-gui/res/puzzle/PS_SNC2.pzl diff --git a/forge-gui/res/puzzle/PS_SNC1.pzl b/forge-gui/res/puzzle/PS_SNC1.pzl new file mode 100644 index 00000000000..9b23f9d7986 --- /dev/null +++ b/forge-gui/res/puzzle/PS_SNC1.pzl @@ -0,0 +1,17 @@ +[metadata] +Name:Possibility Storm - Streets of New Capenna #01 +URL:https://i2.wp.com/www.possibilitystorm.com/wp-content/uploads/2022/04/latest-2-scaled.jpg?ssl=1 +Goal:Win +Turns:1 +Difficulty:Uncommon +Description:Win this turn. Welcome to the Streets of New Capenna! Assume your opponent has nothing to cast, but can activate on-board abilities. Remember that your solution must satisfy all blocking possibilities. +[state] +humanlife=20 +ailife=16 +turn=1 +activeplayer=human +activephase=MAIN1 +humanhand=Cabaretti Charm;Eiganjo Uprising;Jetmir, Nexus of Revels +humanbattlefield=Devilish Valet;Targ Nar, Demon-Fang Gnoll;Hall of Oracles;Furycalm Snarl;Furycalm Snarl;Furycalm Snarl;Furycalm Snarl;Jetmir's Garden;Jetmir's Garden;Jetmir's Garden +aibattlefield=Skaab Wrangler;Geralf, Visionary Stitcher +aipersistentmana=U diff --git a/forge-gui/res/puzzle/PS_SNC2.pzl b/forge-gui/res/puzzle/PS_SNC2.pzl new file mode 100644 index 00000000000..3b8bdc520fa --- /dev/null +++ b/forge-gui/res/puzzle/PS_SNC2.pzl @@ -0,0 +1,17 @@ +[metadata] +Name:Possibility Storm - Streets of New Capenna #02 +URL:https://i1.wp.com/www.possibilitystorm.com/wp-content/uploads/2022/05/latest-scaled.jpg?ssl=1 +Goal:Win +Turns:1 +Difficulty:Uncommon +Description:Win this turn. Remember that your solution must satisfy all blocking possibilities. +[state] +humanlife=20 +ailife=9 +turn=1 +activeplayer=human +activephase=MAIN1 +humanhand=Feign Death;Hostile Takeover;Murder;Even the Score;Grisly Sigil +humanbattlefield=Behold the Unspeakable|Transformed;Cormela, Glamour Thief;Professional Face-Breaker;Stormcarved Coast;Stormcarved Coast;Stormcarved Coast;Waterfront District;Waterfront District +humanexile=Maestros Diabolist|ExiledWith:5|Owner:Human +aibattlefield=Disciplined Duelist|Counters:SHIELD=1;White Dragon;Duelcraft Trainer;Mysterious Limousine|Id:5|Remembered:5 From 5c807f1ee7d04b195edaa22f6d4c2384fd69ce9e Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 09:13:22 +0300 Subject: [PATCH 05/24] - Slight tweak to PS_SNC2. --- forge-gui/res/puzzle/PS_SNC2.pzl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/forge-gui/res/puzzle/PS_SNC2.pzl b/forge-gui/res/puzzle/PS_SNC2.pzl index 3b8bdc520fa..7c7b071a9b3 100644 --- a/forge-gui/res/puzzle/PS_SNC2.pzl +++ b/forge-gui/res/puzzle/PS_SNC2.pzl @@ -13,5 +13,5 @@ activeplayer=human activephase=MAIN1 humanhand=Feign Death;Hostile Takeover;Murder;Even the Score;Grisly Sigil humanbattlefield=Behold the Unspeakable|Transformed;Cormela, Glamour Thief;Professional Face-Breaker;Stormcarved Coast;Stormcarved Coast;Stormcarved Coast;Waterfront District;Waterfront District -humanexile=Maestros Diabolist|ExiledWith:5|Owner:Human -aibattlefield=Disciplined Duelist|Counters:SHIELD=1;White Dragon;Duelcraft Trainer;Mysterious Limousine|Id:5|Remembered:5 +humanexile=Maestros Diabolist|ExiledWith:5 +aibattlefield=Disciplined Duelist|Counters:SHIELD=1;White Dragon;Duelcraft Trainer;Mysterious Limousine|Id:5 From 4e99f80f565aba3ebf2dcae0f49bf5188d4f28c6 Mon Sep 17 00:00:00 2001 From: ZacharyDeganutti Date: Sat, 11 Jun 2022 04:56:40 -0400 Subject: [PATCH 06/24] Implement Jan Jansen, Chaos Crafter (#651) * Implement Jan Jansen, Chaos Crafter --- .../cardsfolder/upcoming/jan_jansen_chaos_crafter.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/jan_jansen_chaos_crafter.txt diff --git a/forge-gui/res/cardsfolder/upcoming/jan_jansen_chaos_crafter.txt b/forge-gui/res/cardsfolder/upcoming/jan_jansen_chaos_crafter.txt new file mode 100644 index 00000000000..d3755ac9e26 --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/jan_jansen_chaos_crafter.txt @@ -0,0 +1,10 @@ +Name:Jan Jansen, Chaos Crafter +ManaCost:R W B +Types:Legendary Creature Gnome Artificer +PT:3/3 +K:Haste +A:AB$ Token | Cost$ T Sac<1/Creature.Artifact/artifact creature> | TokenAmount$ 2 | TokenScript$ c_a_treasure_sac | SpellDescription$ Create two Treasure tokens. +A:AB$ Token | Cost$ T Sac<1/Artifact.nonCreature/noncreature artifact> | TokenAmount$ 2 | TokenScript$ c_1_1_a_construct | SpellDescription$ Create two 1/1 colorless Construct artifact creature tokens. +SVar:AIPreference:SacCost$Artifact.nonCreature+Token+powerLE1+toughnessEQ1 +DeckHas:Ability$Token|Sacrifice & Type$Treasure +Oracle:Haste\n{T}, Sacrifice an artifact creature: Create two Treasure tokens.\n{T}, Sacrifice a noncreature artifact: Create two 1/1 colorless Construct artifact creature tokens. From ede000f264f1fb0e43982103133edd56ac95810a Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 12:40:17 +0300 Subject: [PATCH 07/24] - Different (working) implementation for PS_SNC2. --- forge-gui/res/puzzle/PS_SNC2.pzl | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/forge-gui/res/puzzle/PS_SNC2.pzl b/forge-gui/res/puzzle/PS_SNC2.pzl index 7c7b071a9b3..9d6509017b3 100644 --- a/forge-gui/res/puzzle/PS_SNC2.pzl +++ b/forge-gui/res/puzzle/PS_SNC2.pzl @@ -4,7 +4,7 @@ URL:https://i1.wp.com/www.possibilitystorm.com/wp-content/uploads/2022/05/latest Goal:Win Turns:1 Difficulty:Uncommon -Description:Win this turn. Remember that your solution must satisfy all blocking possibilities. +Description:Win this turn. Remember that your solution must satisfy all blocking possibilities. Your Maestros Diabolist is exiled with the opponent's Mysterious Limousine. [state] humanlife=20 ailife=9 @@ -12,6 +12,5 @@ turn=1 activeplayer=human activephase=MAIN1 humanhand=Feign Death;Hostile Takeover;Murder;Even the Score;Grisly Sigil -humanbattlefield=Behold the Unspeakable|Transformed;Cormela, Glamour Thief;Professional Face-Breaker;Stormcarved Coast;Stormcarved Coast;Stormcarved Coast;Waterfront District;Waterfront District -humanexile=Maestros Diabolist|ExiledWith:5 -aibattlefield=Disciplined Duelist|Counters:SHIELD=1;White Dragon;Duelcraft Trainer;Mysterious Limousine|Id:5 +humanbattlefield=Behold the Unspeakable|Transformed;Cormela, Glamour Thief;Professional Face-Breaker;Stormcarved Coast;Stormcarved Coast;Stormcarved Coast;Waterfront District;Waterfront District;Maestros Diabolist|Id:1 +aibattlefield=Disciplined Duelist|Counters:SHIELD=1;White Dragon;Duelcraft Trainer;Mysterious Limousine|ExecuteScript:TrigExile->1 From 6c1fe344e1f4ddc9e8a79fba06758578e9838c8a Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 12:48:23 +0300 Subject: [PATCH 08/24] [maven-release-plugin] prepare release forge-1.6.51 --- forge-adventure/pom.xml | 4 ++-- forge-ai/pom.xml | 2 +- forge-core/pom.xml | 2 +- forge-game/pom.xml | 2 +- forge-gui-android/pom.xml | 2 +- forge-gui-desktop/pom.xml | 2 +- forge-gui-ios/pom.xml | 2 +- forge-gui-mobile-dev/pom.xml | 2 +- forge-gui-mobile/pom.xml | 2 +- forge-gui/pom.xml | 2 +- forge-lda/pom.xml | 2 +- pom.xml | 4 ++-- 12 files changed, 14 insertions(+), 14 deletions(-) diff --git a/forge-adventure/pom.xml b/forge-adventure/pom.xml index 2996e9b301a..3e8873dc49d 100644 --- a/forge-adventure/pom.xml +++ b/forge-adventure/pom.xml @@ -3,7 +3,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 4.0.0 @@ -290,7 +290,7 @@ forge forge-gui-mobile - 1.6.51-SNAPSHOT + 1.6.51 compile diff --git a/forge-ai/pom.xml b/forge-ai/pom.xml index 10f8ec032da..c71dc9baeb6 100644 --- a/forge-ai/pom.xml +++ b/forge-ai/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-ai diff --git a/forge-core/pom.xml b/forge-core/pom.xml index 3dcb90eef1d..290cac64dd5 100644 --- a/forge-core/pom.xml +++ b/forge-core/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-core diff --git a/forge-game/pom.xml b/forge-game/pom.xml index 79065683993..5df6a1dbe8e 100644 --- a/forge-game/pom.xml +++ b/forge-game/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-game diff --git a/forge-gui-android/pom.xml b/forge-gui-android/pom.xml index ab5c709706e..6c1bd65af51 100644 --- a/forge-gui-android/pom.xml +++ b/forge-gui-android/pom.xml @@ -19,7 +19,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-gui-android diff --git a/forge-gui-desktop/pom.xml b/forge-gui-desktop/pom.xml index ef6832ca82a..4f3c5e38daa 100644 --- a/forge-gui-desktop/pom.xml +++ b/forge-gui-desktop/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-gui-desktop diff --git a/forge-gui-ios/pom.xml b/forge-gui-ios/pom.xml index 5ef70e1c261..f8029132a69 100644 --- a/forge-gui-ios/pom.xml +++ b/forge-gui-ios/pom.xml @@ -12,7 +12,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-gui-ios diff --git a/forge-gui-mobile-dev/pom.xml b/forge-gui-mobile-dev/pom.xml index 54bc86464de..4a77130e071 100644 --- a/forge-gui-mobile-dev/pom.xml +++ b/forge-gui-mobile-dev/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-gui-mobile-dev diff --git a/forge-gui-mobile/pom.xml b/forge-gui-mobile/pom.xml index fd09240a7f6..e72c6be8f39 100644 --- a/forge-gui-mobile/pom.xml +++ b/forge-gui-mobile/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-gui-mobile diff --git a/forge-gui/pom.xml b/forge-gui/pom.xml index 55a0d5776d0..6db0a086d65 100644 --- a/forge-gui/pom.xml +++ b/forge-gui/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-gui diff --git a/forge-lda/pom.xml b/forge-lda/pom.xml index 8b410722b85..babac106c05 100644 --- a/forge-lda/pom.xml +++ b/forge-lda/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51-SNAPSHOT + 1.6.51 forge-lda diff --git a/pom.xml b/pom.xml index 6d85ab44c44..d4d39c6d3a0 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ forge pom Forge Parent - 1.6.51-SNAPSHOT + 1.6.51 Forge lets you play the card game Magic: The Gathering against a computer opponent using all of the rules. @@ -36,7 +36,7 @@ scm:git:https://github.com/Card-Forge/forge.git scm:git:https://github.com/Card-Forge/forge.git - HEAD + forge-1.6.51 From 20de403e6434542d86d22740d6a1f41ec4863441 Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 12:50:40 +0300 Subject: [PATCH 09/24] [maven-release-plugin] prepare for next development iteration --- forge-adventure/pom.xml | 4 ++-- forge-ai/pom.xml | 2 +- forge-core/pom.xml | 2 +- forge-game/pom.xml | 2 +- forge-gui-android/pom.xml | 2 +- forge-gui-desktop/pom.xml | 2 +- forge-gui-ios/pom.xml | 2 +- forge-gui-mobile-dev/pom.xml | 2 +- forge-gui-mobile/pom.xml | 2 +- forge-gui/pom.xml | 2 +- forge-lda/pom.xml | 2 +- pom.xml | 4 ++-- 12 files changed, 14 insertions(+), 14 deletions(-) diff --git a/forge-adventure/pom.xml b/forge-adventure/pom.xml index 3e8873dc49d..43d9166c759 100644 --- a/forge-adventure/pom.xml +++ b/forge-adventure/pom.xml @@ -3,7 +3,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT 4.0.0 @@ -290,7 +290,7 @@ forge forge-gui-mobile - 1.6.51 + 1.6.52-SNAPSHOT compile diff --git a/forge-ai/pom.xml b/forge-ai/pom.xml index c71dc9baeb6..6bc475d4957 100644 --- a/forge-ai/pom.xml +++ b/forge-ai/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-ai diff --git a/forge-core/pom.xml b/forge-core/pom.xml index 290cac64dd5..7286899e7db 100644 --- a/forge-core/pom.xml +++ b/forge-core/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-core diff --git a/forge-game/pom.xml b/forge-game/pom.xml index 5df6a1dbe8e..f9b149aa076 100644 --- a/forge-game/pom.xml +++ b/forge-game/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-game diff --git a/forge-gui-android/pom.xml b/forge-gui-android/pom.xml index 6c1bd65af51..85e3790b828 100644 --- a/forge-gui-android/pom.xml +++ b/forge-gui-android/pom.xml @@ -19,7 +19,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-gui-android diff --git a/forge-gui-desktop/pom.xml b/forge-gui-desktop/pom.xml index 4f3c5e38daa..eea95b76c5b 100644 --- a/forge-gui-desktop/pom.xml +++ b/forge-gui-desktop/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-gui-desktop diff --git a/forge-gui-ios/pom.xml b/forge-gui-ios/pom.xml index f8029132a69..a8508e53d19 100644 --- a/forge-gui-ios/pom.xml +++ b/forge-gui-ios/pom.xml @@ -12,7 +12,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-gui-ios diff --git a/forge-gui-mobile-dev/pom.xml b/forge-gui-mobile-dev/pom.xml index 4a77130e071..47b017137b2 100644 --- a/forge-gui-mobile-dev/pom.xml +++ b/forge-gui-mobile-dev/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-gui-mobile-dev diff --git a/forge-gui-mobile/pom.xml b/forge-gui-mobile/pom.xml index e72c6be8f39..94eaacde87e 100644 --- a/forge-gui-mobile/pom.xml +++ b/forge-gui-mobile/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-gui-mobile diff --git a/forge-gui/pom.xml b/forge-gui/pom.xml index 6db0a086d65..656d6808999 100644 --- a/forge-gui/pom.xml +++ b/forge-gui/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-gui diff --git a/forge-lda/pom.xml b/forge-lda/pom.xml index babac106c05..1b77b39af06 100644 --- a/forge-lda/pom.xml +++ b/forge-lda/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.51 + 1.6.52-SNAPSHOT forge-lda diff --git a/pom.xml b/pom.xml index d4d39c6d3a0..e83a585f6e1 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ forge pom Forge Parent - 1.6.51 + 1.6.52-SNAPSHOT Forge lets you play the card game Magic: The Gathering against a computer opponent using all of the rules. @@ -36,7 +36,7 @@ scm:git:https://github.com/Card-Forge/forge.git scm:git:https://github.com/Card-Forge/forge.git - forge-1.6.51 + HEAD From bd2a42b4350346b7692a7699065db7380885faf5 Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 12:55:27 +0300 Subject: [PATCH 10/24] [maven-release-plugin] prepare release forge-1.6.52 --- forge-adventure/pom.xml | 4 ++-- forge-ai/pom.xml | 2 +- forge-core/pom.xml | 2 +- forge-game/pom.xml | 2 +- forge-gui-android/pom.xml | 2 +- forge-gui-desktop/pom.xml | 2 +- forge-gui-ios/pom.xml | 2 +- forge-gui-mobile-dev/pom.xml | 2 +- forge-gui-mobile/pom.xml | 2 +- forge-gui/pom.xml | 2 +- forge-lda/pom.xml | 2 +- pom.xml | 4 ++-- 12 files changed, 14 insertions(+), 14 deletions(-) diff --git a/forge-adventure/pom.xml b/forge-adventure/pom.xml index 43d9166c759..b97746f3217 100644 --- a/forge-adventure/pom.xml +++ b/forge-adventure/pom.xml @@ -3,7 +3,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 4.0.0 @@ -290,7 +290,7 @@ forge forge-gui-mobile - 1.6.52-SNAPSHOT + 1.6.52 compile diff --git a/forge-ai/pom.xml b/forge-ai/pom.xml index 6bc475d4957..ec90a914594 100644 --- a/forge-ai/pom.xml +++ b/forge-ai/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-ai diff --git a/forge-core/pom.xml b/forge-core/pom.xml index 7286899e7db..b2da5e35e08 100644 --- a/forge-core/pom.xml +++ b/forge-core/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-core diff --git a/forge-game/pom.xml b/forge-game/pom.xml index f9b149aa076..7ec02d26087 100644 --- a/forge-game/pom.xml +++ b/forge-game/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-game diff --git a/forge-gui-android/pom.xml b/forge-gui-android/pom.xml index 85e3790b828..95c23725f2e 100644 --- a/forge-gui-android/pom.xml +++ b/forge-gui-android/pom.xml @@ -19,7 +19,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-gui-android diff --git a/forge-gui-desktop/pom.xml b/forge-gui-desktop/pom.xml index eea95b76c5b..76657e68c45 100644 --- a/forge-gui-desktop/pom.xml +++ b/forge-gui-desktop/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-gui-desktop diff --git a/forge-gui-ios/pom.xml b/forge-gui-ios/pom.xml index a8508e53d19..9d5075c6e36 100644 --- a/forge-gui-ios/pom.xml +++ b/forge-gui-ios/pom.xml @@ -12,7 +12,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-gui-ios diff --git a/forge-gui-mobile-dev/pom.xml b/forge-gui-mobile-dev/pom.xml index 47b017137b2..2a9cd6329fd 100644 --- a/forge-gui-mobile-dev/pom.xml +++ b/forge-gui-mobile-dev/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-gui-mobile-dev diff --git a/forge-gui-mobile/pom.xml b/forge-gui-mobile/pom.xml index 94eaacde87e..01af86abada 100644 --- a/forge-gui-mobile/pom.xml +++ b/forge-gui-mobile/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-gui-mobile diff --git a/forge-gui/pom.xml b/forge-gui/pom.xml index 656d6808999..00884d307aa 100644 --- a/forge-gui/pom.xml +++ b/forge-gui/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-gui diff --git a/forge-lda/pom.xml b/forge-lda/pom.xml index 1b77b39af06..27f60300293 100644 --- a/forge-lda/pom.xml +++ b/forge-lda/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52-SNAPSHOT + 1.6.52 forge-lda diff --git a/pom.xml b/pom.xml index e83a585f6e1..5ff6a898707 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ forge pom Forge Parent - 1.6.52-SNAPSHOT + 1.6.52 Forge lets you play the card game Magic: The Gathering against a computer opponent using all of the rules. @@ -36,7 +36,7 @@ scm:git:https://github.com/Card-Forge/forge.git scm:git:https://github.com/Card-Forge/forge.git - HEAD + forge-1.6.52 From 761b10eba40a62742519be520912a2343680c52d Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 12:55:35 +0300 Subject: [PATCH 11/24] [maven-release-plugin] prepare for next development iteration --- forge-adventure/pom.xml | 4 ++-- forge-ai/pom.xml | 2 +- forge-core/pom.xml | 2 +- forge-game/pom.xml | 2 +- forge-gui-android/pom.xml | 2 +- forge-gui-desktop/pom.xml | 2 +- forge-gui-ios/pom.xml | 2 +- forge-gui-mobile-dev/pom.xml | 2 +- forge-gui-mobile/pom.xml | 2 +- forge-gui/pom.xml | 2 +- forge-lda/pom.xml | 2 +- pom.xml | 4 ++-- 12 files changed, 14 insertions(+), 14 deletions(-) diff --git a/forge-adventure/pom.xml b/forge-adventure/pom.xml index b97746f3217..0c8b7275df6 100644 --- a/forge-adventure/pom.xml +++ b/forge-adventure/pom.xml @@ -3,7 +3,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT 4.0.0 @@ -290,7 +290,7 @@ forge forge-gui-mobile - 1.6.52 + 1.6.53-SNAPSHOT compile diff --git a/forge-ai/pom.xml b/forge-ai/pom.xml index ec90a914594..e420e6e06f1 100644 --- a/forge-ai/pom.xml +++ b/forge-ai/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-ai diff --git a/forge-core/pom.xml b/forge-core/pom.xml index b2da5e35e08..8b7663eb90e 100644 --- a/forge-core/pom.xml +++ b/forge-core/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-core diff --git a/forge-game/pom.xml b/forge-game/pom.xml index 7ec02d26087..33c44b42a85 100644 --- a/forge-game/pom.xml +++ b/forge-game/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-game diff --git a/forge-gui-android/pom.xml b/forge-gui-android/pom.xml index 95c23725f2e..16cb9148dd1 100644 --- a/forge-gui-android/pom.xml +++ b/forge-gui-android/pom.xml @@ -19,7 +19,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-gui-android diff --git a/forge-gui-desktop/pom.xml b/forge-gui-desktop/pom.xml index 76657e68c45..8f1796b9404 100644 --- a/forge-gui-desktop/pom.xml +++ b/forge-gui-desktop/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-gui-desktop diff --git a/forge-gui-ios/pom.xml b/forge-gui-ios/pom.xml index 9d5075c6e36..9288497a5c2 100644 --- a/forge-gui-ios/pom.xml +++ b/forge-gui-ios/pom.xml @@ -12,7 +12,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-gui-ios diff --git a/forge-gui-mobile-dev/pom.xml b/forge-gui-mobile-dev/pom.xml index 2a9cd6329fd..7e08357b91c 100644 --- a/forge-gui-mobile-dev/pom.xml +++ b/forge-gui-mobile-dev/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-gui-mobile-dev diff --git a/forge-gui-mobile/pom.xml b/forge-gui-mobile/pom.xml index 01af86abada..242aa62d9ca 100644 --- a/forge-gui-mobile/pom.xml +++ b/forge-gui-mobile/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-gui-mobile diff --git a/forge-gui/pom.xml b/forge-gui/pom.xml index 00884d307aa..8297ce81a51 100644 --- a/forge-gui/pom.xml +++ b/forge-gui/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-gui diff --git a/forge-lda/pom.xml b/forge-lda/pom.xml index 27f60300293..f6f9ffd7f1a 100644 --- a/forge-lda/pom.xml +++ b/forge-lda/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.52 + 1.6.53-SNAPSHOT forge-lda diff --git a/pom.xml b/pom.xml index 5ff6a898707..5292ceea9a9 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ forge pom Forge Parent - 1.6.52 + 1.6.53-SNAPSHOT Forge lets you play the card game Magic: The Gathering against a computer opponent using all of the rules. @@ -36,7 +36,7 @@ scm:git:https://github.com/Card-Forge/forge.git scm:git:https://github.com/Card-Forge/forge.git - forge-1.6.52 + HEAD From d3c411d097ce62f398e1e716f8aa1d97bd4c4506 Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 13:06:46 +0300 Subject: [PATCH 12/24] [maven-release-plugin] prepare release forge-1.6.53 --- forge-adventure/pom.xml | 4 ++-- forge-ai/pom.xml | 2 +- forge-core/pom.xml | 2 +- forge-game/pom.xml | 2 +- forge-gui-android/pom.xml | 2 +- forge-gui-desktop/pom.xml | 2 +- forge-gui-ios/pom.xml | 2 +- forge-gui-mobile-dev/pom.xml | 2 +- forge-gui-mobile/pom.xml | 2 +- forge-gui/pom.xml | 2 +- forge-lda/pom.xml | 2 +- pom.xml | 4 ++-- 12 files changed, 14 insertions(+), 14 deletions(-) diff --git a/forge-adventure/pom.xml b/forge-adventure/pom.xml index 0c8b7275df6..2081004168b 100644 --- a/forge-adventure/pom.xml +++ b/forge-adventure/pom.xml @@ -3,7 +3,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 4.0.0 @@ -290,7 +290,7 @@ forge forge-gui-mobile - 1.6.53-SNAPSHOT + 1.6.53 compile diff --git a/forge-ai/pom.xml b/forge-ai/pom.xml index e420e6e06f1..c14599a6fbb 100644 --- a/forge-ai/pom.xml +++ b/forge-ai/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-ai diff --git a/forge-core/pom.xml b/forge-core/pom.xml index 8b7663eb90e..58d1395686f 100644 --- a/forge-core/pom.xml +++ b/forge-core/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-core diff --git a/forge-game/pom.xml b/forge-game/pom.xml index 33c44b42a85..40d0f5da3d5 100644 --- a/forge-game/pom.xml +++ b/forge-game/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-game diff --git a/forge-gui-android/pom.xml b/forge-gui-android/pom.xml index 16cb9148dd1..6015030cb7d 100644 --- a/forge-gui-android/pom.xml +++ b/forge-gui-android/pom.xml @@ -19,7 +19,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-gui-android diff --git a/forge-gui-desktop/pom.xml b/forge-gui-desktop/pom.xml index 8f1796b9404..3ef969ae397 100644 --- a/forge-gui-desktop/pom.xml +++ b/forge-gui-desktop/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-gui-desktop diff --git a/forge-gui-ios/pom.xml b/forge-gui-ios/pom.xml index 9288497a5c2..82baf6fa208 100644 --- a/forge-gui-ios/pom.xml +++ b/forge-gui-ios/pom.xml @@ -12,7 +12,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-gui-ios diff --git a/forge-gui-mobile-dev/pom.xml b/forge-gui-mobile-dev/pom.xml index 7e08357b91c..a49efb91528 100644 --- a/forge-gui-mobile-dev/pom.xml +++ b/forge-gui-mobile-dev/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-gui-mobile-dev diff --git a/forge-gui-mobile/pom.xml b/forge-gui-mobile/pom.xml index 242aa62d9ca..9f342b01ccc 100644 --- a/forge-gui-mobile/pom.xml +++ b/forge-gui-mobile/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-gui-mobile diff --git a/forge-gui/pom.xml b/forge-gui/pom.xml index 8297ce81a51..71ec7b9680a 100644 --- a/forge-gui/pom.xml +++ b/forge-gui/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-gui diff --git a/forge-lda/pom.xml b/forge-lda/pom.xml index f6f9ffd7f1a..76973aeee2c 100644 --- a/forge-lda/pom.xml +++ b/forge-lda/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53-SNAPSHOT + 1.6.53 forge-lda diff --git a/pom.xml b/pom.xml index 5292ceea9a9..747eaf4b475 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ forge pom Forge Parent - 1.6.53-SNAPSHOT + 1.6.53 Forge lets you play the card game Magic: The Gathering against a computer opponent using all of the rules. @@ -36,7 +36,7 @@ scm:git:https://github.com/Card-Forge/forge.git scm:git:https://github.com/Card-Forge/forge.git - HEAD + forge-1.6.53 From cff5e36d9ef3971f1c3e2a590a66abcf3b92650e Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 13:06:54 +0300 Subject: [PATCH 13/24] [maven-release-plugin] prepare for next development iteration --- forge-adventure/pom.xml | 4 ++-- forge-ai/pom.xml | 2 +- forge-core/pom.xml | 2 +- forge-game/pom.xml | 2 +- forge-gui-android/pom.xml | 2 +- forge-gui-desktop/pom.xml | 2 +- forge-gui-ios/pom.xml | 2 +- forge-gui-mobile-dev/pom.xml | 2 +- forge-gui-mobile/pom.xml | 2 +- forge-gui/pom.xml | 2 +- forge-lda/pom.xml | 2 +- pom.xml | 4 ++-- 12 files changed, 14 insertions(+), 14 deletions(-) diff --git a/forge-adventure/pom.xml b/forge-adventure/pom.xml index 2081004168b..9b2fd342fe3 100644 --- a/forge-adventure/pom.xml +++ b/forge-adventure/pom.xml @@ -3,7 +3,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT 4.0.0 @@ -290,7 +290,7 @@ forge forge-gui-mobile - 1.6.53 + 1.6.54-SNAPSHOT compile diff --git a/forge-ai/pom.xml b/forge-ai/pom.xml index c14599a6fbb..cb8f95d4227 100644 --- a/forge-ai/pom.xml +++ b/forge-ai/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-ai diff --git a/forge-core/pom.xml b/forge-core/pom.xml index 58d1395686f..bf760f3a81a 100644 --- a/forge-core/pom.xml +++ b/forge-core/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-core diff --git a/forge-game/pom.xml b/forge-game/pom.xml index 40d0f5da3d5..0012361fa80 100644 --- a/forge-game/pom.xml +++ b/forge-game/pom.xml @@ -6,7 +6,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-game diff --git a/forge-gui-android/pom.xml b/forge-gui-android/pom.xml index 6015030cb7d..600f99d4238 100644 --- a/forge-gui-android/pom.xml +++ b/forge-gui-android/pom.xml @@ -19,7 +19,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-gui-android diff --git a/forge-gui-desktop/pom.xml b/forge-gui-desktop/pom.xml index 3ef969ae397..218e6410966 100644 --- a/forge-gui-desktop/pom.xml +++ b/forge-gui-desktop/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-gui-desktop diff --git a/forge-gui-ios/pom.xml b/forge-gui-ios/pom.xml index 82baf6fa208..b93708527e8 100644 --- a/forge-gui-ios/pom.xml +++ b/forge-gui-ios/pom.xml @@ -12,7 +12,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-gui-ios diff --git a/forge-gui-mobile-dev/pom.xml b/forge-gui-mobile-dev/pom.xml index a49efb91528..af58c410c50 100644 --- a/forge-gui-mobile-dev/pom.xml +++ b/forge-gui-mobile-dev/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-gui-mobile-dev diff --git a/forge-gui-mobile/pom.xml b/forge-gui-mobile/pom.xml index 9f342b01ccc..0c4ef128e59 100644 --- a/forge-gui-mobile/pom.xml +++ b/forge-gui-mobile/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-gui-mobile diff --git a/forge-gui/pom.xml b/forge-gui/pom.xml index 71ec7b9680a..b81def5a7c3 100644 --- a/forge-gui/pom.xml +++ b/forge-gui/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-gui diff --git a/forge-lda/pom.xml b/forge-lda/pom.xml index 76973aeee2c..78c56d927b1 100644 --- a/forge-lda/pom.xml +++ b/forge-lda/pom.xml @@ -4,7 +4,7 @@ forge forge - 1.6.53 + 1.6.54-SNAPSHOT forge-lda diff --git a/pom.xml b/pom.xml index 747eaf4b475..bef1b353f41 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ forge pom Forge Parent - 1.6.53 + 1.6.54-SNAPSHOT Forge lets you play the card game Magic: The Gathering against a computer opponent using all of the rules. @@ -36,7 +36,7 @@ scm:git:https://github.com/Card-Forge/forge.git scm:git:https://github.com/Card-Forge/forge.git - forge-1.6.53 + HEAD From 693152cda6bbd9836ac43ad289ff080740c8164e Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sat, 11 Jun 2022 13:18:25 +0300 Subject: [PATCH 14/24] - Prepare Forge for Android publish 1.6.53.001 [incremental]. --- forge-gui-android/AndroidManifest.xml | 2 +- forge-gui-android/pom.xml | 2 +- forge-gui-ios/pom.xml | 2 +- forge-gui-mobile/src/forge/Forge.java | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/forge-gui-android/AndroidManifest.xml b/forge-gui-android/AndroidManifest.xml index 8237552827d..5fbb2247567 100644 --- a/forge-gui-android/AndroidManifest.xml +++ b/forge-gui-android/AndroidManifest.xml @@ -2,7 +2,7 @@ + android:versionName="1.6.53" > jar -Xms1024m -Xmx1536m - 1.6.49.001 + 1.6.53.001 keystore alias storepass diff --git a/forge-gui-ios/pom.xml b/forge-gui-ios/pom.xml index b93708527e8..1d4bd7cbcb3 100644 --- a/forge-gui-ios/pom.xml +++ b/forge-gui-ios/pom.xml @@ -6,7 +6,7 @@ jar -Xms128m -Xmx2048m - 1.6.49.001 + 1.6.53.001 diff --git a/forge-gui-mobile/src/forge/Forge.java b/forge-gui-mobile/src/forge/Forge.java index f1559f292e4..40158d2d39d 100644 --- a/forge-gui-mobile/src/forge/Forge.java +++ b/forge-gui-mobile/src/forge/Forge.java @@ -59,7 +59,7 @@ import java.util.List; import java.util.Map; public class Forge implements ApplicationListener { - public static final String CURRENT_VERSION = "1.6.49.001"; + public static final String CURRENT_VERSION = "1.6.53.001"; private static ApplicationListener app = null; static Scene currentScene = null; From a19f90db50cb697a35035e9b808b7f64db1c074d Mon Sep 17 00:00:00 2001 From: tool4EvEr Date: Sat, 11 Jun 2022 14:01:54 +0200 Subject: [PATCH 15/24] Initiative fix --- forge-game/src/main/java/forge/game/player/Player.java | 2 +- .../forge/game/trigger/TriggerDamageDoneOnceByController.java | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/forge-game/src/main/java/forge/game/player/Player.java b/forge-game/src/main/java/forge/game/player/Player.java index 658cf02a6bf..73cbf35e0db 100644 --- a/forge-game/src/main/java/forge/game/player/Player.java +++ b/forge-game/src/main/java/forge/game/player/Player.java @@ -3206,7 +3206,7 @@ public class Player extends GameEntity implements Comparable { final String damageTrig = "Mode$ DamageDoneOnceByController | ValidSource$ Player | ValidTarget$ You | " + "CombatDamage$ True | TriggerZones$ Command | TriggerDescription$ Whenever one or more " + "creatures a player controls deal combat damage to you, that player takes the initiative."; - final String damageEff = "DB$ TakeInitiative | Defined$ TriggeredAttackingPlayer"; + final String damageEff = "DB$ TakeInitiative | Defined$ TriggeredSource"; final Trigger damageTrigger = TriggerHandler.parseTrigger(damageTrig, initiativeEffect, true); diff --git a/forge-game/src/main/java/forge/game/trigger/TriggerDamageDoneOnceByController.java b/forge-game/src/main/java/forge/game/trigger/TriggerDamageDoneOnceByController.java index a96243d52aa..8d118146261 100644 --- a/forge-game/src/main/java/forge/game/trigger/TriggerDamageDoneOnceByController.java +++ b/forge-game/src/main/java/forge/game/trigger/TriggerDamageDoneOnceByController.java @@ -36,7 +36,6 @@ public class TriggerDamageDoneOnceByController extends Trigger { @Override public void setTriggeringObjects(SpellAbility sa, Map runParams) { - Object target = runParams.get(AbilityKey.DamageTarget); if (target instanceof Card) { target = CardUtil.getLKICopy((Card)runParams.get(AbilityKey.DamageTarget)); From 1c65c6c3cc05601c8ceee83544285b06a186e02a Mon Sep 17 00:00:00 2001 From: tool4EvEr Date: Sat, 11 Jun 2022 17:32:42 +0200 Subject: [PATCH 16/24] Capricopian PW fix --- .../game/ability/effects/ChangeCombatantsEffect.java | 5 +++-- .../forge/game/staticability/StaticAbilityCantBeCast.java | 8 ++++---- forge-gui/res/cardsfolder/c/capricopian.txt | 4 ++-- forge-gui/res/cardsfolder/c/chronozoa.txt | 5 ++--- forge-gui/res/cardsfolder/e/epic_experiment.txt | 2 +- forge-gui/res/cardsfolder/m/martial_impetus.txt | 2 +- 6 files changed, 13 insertions(+), 13 deletions(-) diff --git a/forge-game/src/main/java/forge/game/ability/effects/ChangeCombatantsEffect.java b/forge-game/src/main/java/forge/game/ability/effects/ChangeCombatantsEffect.java index a62b98dc667..c3d65a43026 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/ChangeCombatantsEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/ChangeCombatantsEffect.java @@ -21,7 +21,7 @@ import forge.game.spellability.SpellAbilityStackInstance; import forge.game.spellability.TargetRestrictions; import forge.util.CardTranslation; import forge.util.Localizer; -import forge.util.collect.FCollectionView; +import forge.util.collect.FCollection; public class ChangeCombatantsEffect extends SpellAbilityEffect { @@ -47,7 +47,8 @@ public class ChangeCombatantsEffect extends SpellAbilityEffect { if ((tgt == null) || c.canBeTargetedBy(sa)) { final Combat combat = game.getCombat(); final GameEntity originalDefender = combat.getDefenderByAttacker(c); - final FCollectionView defs = combat.getDefenders(); + final FCollection defs = new FCollection<>(); + defs.addAll(sa.hasParam("PlayerOnly") ? combat.getDefendingPlayers() : combat.getDefenders()); String title = Localizer.getInstance().getMessage("lblChooseDefenderToAttackWithCard", CardTranslation.getTranslatedName(c.getName())); Map params = Maps.newHashMap(); diff --git a/forge-game/src/main/java/forge/game/staticability/StaticAbilityCantBeCast.java b/forge-game/src/main/java/forge/game/staticability/StaticAbilityCantBeCast.java index c158cac8b62..ed95f9ce562 100644 --- a/forge-game/src/main/java/forge/game/staticability/StaticAbilityCantBeCast.java +++ b/forge-game/src/main/java/forge/game/staticability/StaticAbilityCantBeCast.java @@ -109,7 +109,7 @@ public class StaticAbilityCantBeCast { return false; } - if (stAb.hasParam("OnlySorcerySpeed") && (activator != null) && activator.canCastSorcery()) { + if (stAb.hasParam("OnlySorcerySpeed") && activator != null && activator.canCastSorcery()) { return false; } @@ -120,12 +120,12 @@ public class StaticAbilityCantBeCast { } } - if (stAb.hasParam("NonCasterTurn") && (activator != null) + if (stAb.hasParam("NonCasterTurn") && activator != null && activator.getGame().getPhaseHandler().isPlayerTurn(activator)) { return false; } - if (stAb.hasParam("cmcGT") && (activator != null)) { + if (stAb.hasParam("cmcGT") && activator != null) { if (stAb.getParam("cmcGT").equals("Turns")) { if (card.getCMC() <= activator.getTurn()) { return false; @@ -176,7 +176,7 @@ public class StaticAbilityCantBeCast { return false; } - if (stAb.hasParam("NonActivatorTurn") && (activator != null) + if (stAb.hasParam("NonActivatorTurn") && activator != null && activator.getGame().getPhaseHandler().isPlayerTurn(activator)) { return false; } diff --git a/forge-gui/res/cardsfolder/c/capricopian.txt b/forge-gui/res/cardsfolder/c/capricopian.txt index 0f465c0f297..14a80953511 100644 --- a/forge-gui/res/cardsfolder/c/capricopian.txt +++ b/forge-gui/res/cardsfolder/c/capricopian.txt @@ -4,7 +4,7 @@ Types:Creature Goat Hydra PT:0/0 K:etbCounter:P1P1:X SVar:X:Count$xPaid -A:AB$ PutCounter | Cost$ 2 | Activator$ Player.attackedBySourceThisCombat | Defined$ Self | CounterType$ P1P1 | CounterNum$ 1 | SubAbility$ DBReselect | ActivationPhases$ Declare Attackers | AILogic$ AlwaysWithNoTgt | SpellDescription$ Put a +1/+1 counter on CARDNAME, then you may reselect which player CARDNAME is attacking. Only the player CARDNAME is attacking may activate this ability and only during the declare attackers step. (It can't attack its controller.) -SVar:DBReselect:DB$ ChangeCombatants | Defined$ Self | AILogic$ WeakestOppExceptCtrl +A:AB$ PutCounter | Cost$ 2 | Activator$ Player | IsPresent$ Card.Self+attackingYou | Defined$ Self | CounterType$ P1P1 | CounterNum$ 1 | SubAbility$ DBReselect | ActivationPhases$ Declare Attackers | AILogic$ AlwaysWithNoTgt | SpellDescription$ Put a +1/+1 counter on CARDNAME, then you may reselect which player CARDNAME is attacking. Only the player CARDNAME is attacking may activate this ability and only during the declare attackers step. (It can't attack its controller.) +SVar:DBReselect:DB$ ChangeCombatants | Defined$ Self | AILogic$ WeakestOppExceptCtrl | PlayerOnly$ True DeckHas:Ability$Counters Oracle:Capricopian enters the battlefield with X +1/+1 counters on it.\n{2}: Put a +1/+1 counter on Capricopian, then you may reselect which player Capricopian is attacking. Only the player Capricopian is attacking may activate this ability and only during the declare attackers step. (It can't attack its controller.) diff --git a/forge-gui/res/cardsfolder/c/chronozoa.txt b/forge-gui/res/cardsfolder/c/chronozoa.txt index 6c8c1fb4226..1f6e402285d 100644 --- a/forge-gui/res/cardsfolder/c/chronozoa.txt +++ b/forge-gui/res/cardsfolder/c/chronozoa.txt @@ -4,7 +4,6 @@ Types:Creature Illusion PT:3/3 K:Flying K:Vanishing:3 -T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Graveyard | Execute$ TrigCopyPermanent | TriggerDescription$ When CARDNAME dies, if it had no time counters on it, create two tokens that are copies of it. -SVar:TrigCopyPermanent:DB$ CopyPermanent | Defined$ TriggeredCard | NumCopies$ 2 | ConditionCheckSVar$ X | ConditionSVarCompare$ EQ0 -SVar:X:TriggeredCard$CardCounters.TIME +T:Mode$ ChangesZone | ValidCard$ Card.Self+counters_EQ0_TIME | Origin$ Battlefield | Destination$ Graveyard | Execute$ TrigCopyPermanent | TriggerDescription$ When CARDNAME dies, if it had no time counters on it, create two tokens that are copies of it. +SVar:TrigCopyPermanent:DB$ CopyPermanent | Defined$ TriggeredCard | NumCopies$ 2 Oracle:Flying\nVanishing 3 (This creature enters the battlefield with three time counters on it. At the beginning of your upkeep, remove a time counter from it. When the last is removed, sacrifice it.)\nWhen Chronozoa dies, if it had no time counters on it, create two tokens that are copies of it. diff --git a/forge-gui/res/cardsfolder/e/epic_experiment.txt b/forge-gui/res/cardsfolder/e/epic_experiment.txt index a7a6436bd99..115f601db46 100644 --- a/forge-gui/res/cardsfolder/e/epic_experiment.txt +++ b/forge-gui/res/cardsfolder/e/epic_experiment.txt @@ -2,7 +2,7 @@ Name:Epic Experiment ManaCost:X U R Types:Sorcery A:SP$ Dig | Cost$ X U R | Defined$ You | DigNum$ X | ChangeNum$ All | DestinationZone$ Exile | RememberChanged$ True | SubAbility$ DBPlay | SpellDescription$ Exile the top X cards of your library. You may cast instant and sorcery spells with mana value X or less from among them without paying their mana costs. Then put all cards exiled this way that weren't cast into your graveyard. -SVar:DBPlay:DB$ Play | Valid$ Instant.cmcLEX+IsRemembered+YouOwn,Sorcery.cmcLEX+IsRemembered+YouOwn | ValidZone$ Exile | ValidSA$ Spell | Controller$ You | WithoutManaCost$ True | Optional$ True | Amount$ All | SubAbility$ DBGrave +SVar:DBPlay:DB$ Play | Valid$ Card.IsRemembered+YouOwn | ValidZone$ Exile | ValidSA$ Instant.cmcLEX,Sorcery.cmcLEX | Controller$ You | WithoutManaCost$ True | Optional$ True | Amount$ All | SubAbility$ DBGrave SVar:DBGrave:DB$ ChangeZoneAll | Origin$ Exile | Destination$ Graveyard | ChangeType$ Card.IsRemembered+YouOwn | SubAbility$ DBCleanup SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True SVar:X:Count$xPaid diff --git a/forge-gui/res/cardsfolder/m/martial_impetus.txt b/forge-gui/res/cardsfolder/m/martial_impetus.txt index ab46a63bcef..00466e2b221 100644 --- a/forge-gui/res/cardsfolder/m/martial_impetus.txt +++ b/forge-gui/res/cardsfolder/m/martial_impetus.txt @@ -5,5 +5,5 @@ K:Enchant creature A:SP$ Attach | Cost$ 2 W | ValidTgts$ Creature | AILogic$ Pump S:Mode$ Continuous | Affected$ Creature.EnchantedBy | AddPower$ 1 | AddToughness$ 1 | Goad$ True | Description$ Enchanted creature gets +1/+1 and is goaded. (It attacks each combat if able and attacks a player other than you if able.) T:Mode$ Attacks | ValidCard$ Card.AttachedBy | TriggerZones$ Battlefield | Execute$ TrigPump | TriggerDescription$ Whenever enchanted creature attacks, each other creature that's attacking one of your opponents gets +1/+1 until end of turn. -SVar:TrigPump:DB$ PumpAll | ValidCards$ Creature.NotEnchantedBy+attackingOpponent | NumAtt$ +1 | NumDef$ +1 +SVar:TrigPump:DB$ PumpAll | ValidCards$ Creature.NotEnchantedBy+attacking Opponent | NumAtt$ +1 | NumDef$ +1 Oracle:Enchant creature\nEnchanted creature gets +1/+1 and is goaded. (It attacks each combat if able and attacks a player other than you if able.)\nWhenever enchanted creature attacks, each other creature that's attacking one of your opponents gets +1/+1 until end of turn. From 22c889d1e08f88a461d55dd80a1fc51e8f6b6682 Mon Sep 17 00:00:00 2001 From: Hans Mackowiak Date: Sat, 11 Jun 2022 11:29:43 +0200 Subject: [PATCH 17/24] Remove InternalETB and replace with UpdateResult --- .../src/main/java/forge/ai/SpellApiToAi.java | 1 - .../forge/ai/ability/CanPlayAsDrawbackAi.java | 35 ------------------- .../src/main/java/forge/game/GameAction.java | 2 +- .../main/java/forge/game/GameActionUtil.java | 3 +- .../java/forge/game/ability/AbilityUtils.java | 14 ++++---- .../main/java/forge/game/ability/ApiType.java | 1 - .../ability/effects/ETBReplacementEffect.java | 32 ----------------- .../java/forge/game/card/CardFactoryUtil.java | 24 +++---------- .../forge/game/replacement/ReplaceMoved.java | 2 +- .../game/replacement/ReplacementHandler.java | 5 +-- .../res/cardsfolder/b/boreal_outrider.txt | 5 ++- .../res/cardsfolder/b/brimstone_vandal.txt | 5 ++- .../res/cardsfolder/c/celestus_sanctifier.txt | 5 ++- .../res/cardsfolder/c/component_collector.txt | 5 ++- .../res/cardsfolder/f/firmament_sage.txt | 5 ++- .../res/cardsfolder/g/gavony_dawnguard.txt | 5 ++- ...n_god_of_winter_kaldring_the_rimestaff.txt | 6 ++-- .../cardsfolder/m/moritte_of_the_frost.txt | 5 ++- .../res/cardsfolder/m/mystic_reflection.txt | 5 ++- .../cardsfolder/o/obsessive_astronomer.txt | 5 ++- forge-gui/res/cardsfolder/s/semesters_end.txt | 10 +++--- forge-gui/res/cardsfolder/s/spark_double.txt | 10 +++--- forge-gui/res/cardsfolder/s/storyweave.txt | 3 +- .../res/cardsfolder/s/sunrise_cavalier.txt | 5 ++- .../res/cardsfolder/s/sunstreak_phoenix.txt | 5 ++- .../res/cardsfolder/t/teferis_time_twist.txt | 5 ++- forge-gui/res/cardsfolder/t/the_celestus.txt | 5 ++- .../res/cardsfolder/upcoming/master_chef.txt | 7 ++-- .../cardsfolder/v/vadrik_astral_archmage.txt | 5 ++- 29 files changed, 61 insertions(+), 164 deletions(-) delete mode 100644 forge-ai/src/main/java/forge/ai/ability/CanPlayAsDrawbackAi.java delete mode 100644 forge-game/src/main/java/forge/game/ability/effects/ETBReplacementEffect.java diff --git a/forge-ai/src/main/java/forge/ai/SpellApiToAi.java b/forge-ai/src/main/java/forge/ai/SpellApiToAi.java index 2d72ac56d1c..28d0ced5046 100644 --- a/forge-ai/src/main/java/forge/ai/SpellApiToAi.java +++ b/forge-ai/src/main/java/forge/ai/SpellApiToAi.java @@ -185,7 +185,6 @@ public enum SpellApiToAi { .put(ApiType.WinsGame, GameWinAi.class) .put(ApiType.DamageResolve, AlwaysPlayAi.class) - .put(ApiType.InternalEtbReplacement, CanPlayAsDrawbackAi.class) .put(ApiType.InternalLegendaryRule, LegendaryRuleAi.class) .put(ApiType.InternalIgnoreEffect, CannotPlayAi.class) .build()); diff --git a/forge-ai/src/main/java/forge/ai/ability/CanPlayAsDrawbackAi.java b/forge-ai/src/main/java/forge/ai/ability/CanPlayAsDrawbackAi.java deleted file mode 100644 index 2e303b29776..00000000000 --- a/forge-ai/src/main/java/forge/ai/ability/CanPlayAsDrawbackAi.java +++ /dev/null @@ -1,35 +0,0 @@ -package forge.ai.ability; - -import forge.ai.SpellAbilityAi; -import forge.game.player.Player; -import forge.game.spellability.SpellAbility; - -public class CanPlayAsDrawbackAi extends SpellAbilityAi { - - /* (non-Javadoc) - * @see forge.card.abilityfactory.SpellAiLogic#canPlayAI(forge.game.player.Player, java.util.Map, forge.card.spellability.SpellAbility) - */ - @Override - protected boolean canPlayAI(Player aiPlayer, SpellAbility sa) { - return false; - } - - /** - *

- * copySpellTriggerAI. - *

- * @param sa - * a {@link forge.game.spellability.SpellAbility} object. - * @param mandatory - * a boolean. - * @param af - * a {@link forge.game.ability.AbilityFactory} object. - * - * @return a boolean. - */ - @Override - protected boolean doTriggerAINoCost(Player aiPlayer, SpellAbility sa, boolean mandatory) { - return false; - } - -} diff --git a/forge-game/src/main/java/forge/game/GameAction.java b/forge-game/src/main/java/forge/game/GameAction.java index 919e35d914f..dfda9c27aa6 100644 --- a/forge-game/src/main/java/forge/game/GameAction.java +++ b/forge-game/src/main/java/forge/game/GameAction.java @@ -365,7 +365,7 @@ public class GameAction { } ReplacementResult repres = game.getReplacementHandler().run(ReplacementType.Moved, repParams); - if (repres != ReplacementResult.NotReplaced) { + if (repres != ReplacementResult.NotReplaced && repres != ReplacementResult.Updated) { // reset failed manifested Cards back to original if (c.isManifested() && !c.isInPlay()) { c.forceTurnFaceUp(); diff --git a/forge-game/src/main/java/forge/game/GameActionUtil.java b/forge-game/src/main/java/forge/game/GameActionUtil.java index 3f563ff302a..addc8e311c9 100644 --- a/forge-game/src/main/java/forge/game/GameActionUtil.java +++ b/forge-game/src/main/java/forge/game/GameActionUtil.java @@ -677,13 +677,12 @@ public final class GameActionUtil { if (!StringUtils.isNumeric(amount)) { sa.setSVar(amount, sourceCard.getSVar(amount)); } - CardFactoryUtil.setupETBReplacementAbility(sa); String desc = "It enters the battlefield with "; desc += Lang.nounWithNumeral(amount, CounterType.getType(counter).getName() + " counter"); desc += " on it."; - String repeffstr = "Event$ Moved | ValidCard$ Card.IsRemembered | Destination$ Battlefield | Description$ " + desc; + String repeffstr = "Event$ Moved | ValidCard$ Card.IsRemembered | Destination$ Battlefield | ReplacementResult$ Updated | Description$ " + desc; ReplacementEffect re = ReplacementHandler.parseReplacement(repeffstr, eff, true); re.setLayer(ReplacementLayer.Other); diff --git a/forge-game/src/main/java/forge/game/ability/AbilityUtils.java b/forge-game/src/main/java/forge/game/ability/AbilityUtils.java index 1f748ff53b2..5461441ab2d 100644 --- a/forge-game/src/main/java/forge/game/ability/AbilityUtils.java +++ b/forge-game/src/main/java/forge/game/ability/AbilityUtils.java @@ -55,6 +55,7 @@ import forge.game.phase.PhaseHandler; import forge.game.player.Player; import forge.game.player.PlayerCollection; import forge.game.player.PlayerPredicates; +import forge.game.replacement.ReplacementType; import forge.game.spellability.AbilitySub; import forge.game.spellability.LandAbility; import forge.game.spellability.OptionalCost; @@ -217,10 +218,15 @@ public class AbilityUtils { else if (defined.startsWith("Replaced") && sa instanceof SpellAbility) { final SpellAbility root = ((SpellAbility)sa).getRootAbility(); AbilityKey type = AbilityKey.fromString(defined.substring(8)); + // for Moved Effects, if it wants to know the affected Card, it might need to return the LKI + // or otherwise the timestamp does match + if (type == AbilityKey.Card && root.isReplacementAbility() && root.getReplacementEffect().getMode() == ReplacementType.Moved) { + type = AbilityKey.CardLKI; + } final Object crd = root.getReplacingObject(type); if (crd instanceof Card) { - c = game.getCardState((Card) crd); + c = (Card) crd; } else if (crd instanceof Iterable) { cards.addAll(Iterables.filter((Iterable) crd, Card.class)); } @@ -1415,11 +1421,7 @@ public class AbilityUtils { // Needed - Equip an untapped creature with Sword of the Paruns then cast Deadshot on it. Should deal 2 more damage. game.getAction().checkStaticAbilities(); // this will refresh continuous abilities for players and permanents. - if (sa.isReplacementAbility() && abSub.getApi() == ApiType.InternalEtbReplacement) { - game.getTriggerHandler().resetActiveTriggers(false); - } else { - game.getTriggerHandler().resetActiveTriggers(); - } + game.getTriggerHandler().resetActiveTriggers(!sa.isReplacementAbility()); AbilityUtils.resolveApiAbility(abSub, game); } diff --git a/forge-game/src/main/java/forge/game/ability/ApiType.java b/forge-game/src/main/java/forge/game/ability/ApiType.java index f09b5b5fffa..9016ad5f03b 100644 --- a/forge-game/src/main/java/forge/game/ability/ApiType.java +++ b/forge-game/src/main/java/forge/game/ability/ApiType.java @@ -189,7 +189,6 @@ public enum ApiType { DamageResolve (DamageResolveEffect.class), ChangeZoneResolve (ChangeZoneResolveEffect.class), - InternalEtbReplacement (ETBReplacementEffect.class), InternalLegendaryRule (CharmEffect.class), InternalIgnoreEffect (CharmEffect.class), UpdateRemember (UpdateRememberEffect.class); diff --git a/forge-game/src/main/java/forge/game/ability/effects/ETBReplacementEffect.java b/forge-game/src/main/java/forge/game/ability/effects/ETBReplacementEffect.java deleted file mode 100644 index 77241fecdac..00000000000 --- a/forge-game/src/main/java/forge/game/ability/effects/ETBReplacementEffect.java +++ /dev/null @@ -1,32 +0,0 @@ -package forge.game.ability.effects; - -import java.util.Map; - -import forge.game.Game; -import forge.game.ability.AbilityKey; -import forge.game.ability.SpellAbilityEffect; -import forge.game.card.Card; -import forge.game.spellability.SpellAbility; - -/** - * TODO: Write javadoc for this type. - * - */ -public class ETBReplacementEffect extends SpellAbilityEffect { - @Override - public void resolve(SpellAbility sa) { - final Game game = sa.getActivatingPlayer().getGame(); - final Card card = (Card) sa.getReplacingObject(AbilityKey.Card); - - Map params = AbilityKey.newMap(); - params.put(AbilityKey.CardLKI, sa.getReplacingObject(AbilityKey.CardLKI)); - params.put(AbilityKey.ReplacementEffect, sa.getReplacementEffect()); - params.put(AbilityKey.LastStateBattlefield, sa.getReplacingObject(AbilityKey.LastStateBattlefield)); - params.put(AbilityKey.LastStateGraveyard, sa.getReplacingObject(AbilityKey.LastStateGraveyard)); - - final SpellAbility root = sa.getRootAbility(); - SpellAbility cause = (SpellAbility) root.getReplacingObject(AbilityKey.Cause); - - game.getAction().moveToPlay(card, card.getController(), cause, params); - } -} \ No newline at end of file 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 1297012b5c7..00317836bd9 100644 --- a/forge-game/src/main/java/forge/game/card/CardFactoryUtil.java +++ b/forge-game/src/main/java/forge/game/card/CardFactoryUtil.java @@ -52,7 +52,6 @@ import forge.game.GameLogEntryType; import forge.game.ability.AbilityFactory; import forge.game.ability.AbilityKey; import forge.game.ability.AbilityUtils; -import forge.game.ability.ApiType; import forge.game.cost.Cost; import forge.game.keyword.Keyword; import forge.game.keyword.KeywordInterface; @@ -651,14 +650,13 @@ public class CardFactoryUtil { final boolean intrinsic, final String valid, final String zone) { Card host = card.getCard(); String desc = repAb.getDescription(); - setupETBReplacementAbility(repAb); if (!intrinsic) { repAb.setIntrinsic(false); } StringBuilder repEffsb = new StringBuilder(); repEffsb.append("Event$ Moved | ValidCard$ ").append(valid); - repEffsb.append(" | Destination$ Battlefield | Description$ ").append(desc); + repEffsb.append(" | Destination$ Battlefield | ReplacementResult$ Updated | Description$ ").append(desc); if (optional) { repEffsb.append(" | Optional$ True"); } @@ -751,13 +749,12 @@ public class CardFactoryUtil { } SpellAbility sa = AbilityFactory.getAbility(abStr, card); - setupETBReplacementAbility(sa); if (!intrinsic) { sa.setIntrinsic(false); } String repeffstr = "Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield " - + "| Secondary$ True | Description$ " + desc + (!extraparams.equals("") ? " | " + extraparams : ""); + + "| Secondary$ True | ReplacementResult$ Updated | Description$ " + desc + (!extraparams.equals("") ? " | " + extraparams : ""); ReplacementEffect re = ReplacementHandler.parseReplacement(repeffstr, card.getCard(), intrinsic, card); @@ -2055,7 +2052,7 @@ public class CardFactoryUtil { // Setup ETB replacement effects final String actualRep = "Event$ Moved | Destination$ Battlefield | ValidCard$ Card.Self |" - + " | Description$ Amplify " + amplifyMagnitude + " (" + + " | ReplacementResult$ Updated | Description$ Amplify " + amplifyMagnitude + " (" + inst.getReminderText() + ")"; final String abString = "DB$ Reveal | AnyNumber$ True | RevealValid$ " @@ -2075,7 +2072,6 @@ public class CardFactoryUtil { AbilitySub saCleanup = (AbilitySub) AbilityFactory.getAbility(dbClean, card); saPut.setSubAbility(saCleanup); - setupETBReplacementAbility(saCleanup); saReveal.setSubAbility(saPut); @@ -2168,13 +2164,12 @@ public class CardFactoryUtil { inst.addReplacement(re); } else if (keyword.equals("Daybound")) { - final String actualRep = "Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Night | Secondary$ True | Layer$ Transform | Description$ If it is night, this permanent enters the battlefield transformed."; + final String actualRep = "Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Night | Secondary$ True | Layer$ Transform | ReplacementResult$ Updated | Description$ If it is night, this permanent enters the battlefield transformed."; final String abTransform = "DB$ SetState | Defined$ ReplacedCard | Mode$ Transform | ETB$ True | Daybound$ True"; ReplacementEffect re = ReplacementHandler.parseReplacement(actualRep, host, intrinsic, card); SpellAbility saTransform = AbilityFactory.getAbility(abTransform, card); - setupETBReplacementAbility(saTransform); re.setOverridingAbility(saTransform); inst.addReplacement(re); @@ -2206,11 +2201,10 @@ public class CardFactoryUtil { AbilitySub cleanupSA = (AbilitySub) AbilityFactory.getAbility(cleanupStr, card); counterSA.setSubAbility(cleanupSA); - String repeffstr = "Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | Secondary$ True | Description$ Devour " + magnitude + " ("+ inst.getReminderText() + ")"; + String repeffstr = "Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | Secondary$ True | ReplacementResult$ Updated | Description$ Devour " + magnitude + " ("+ inst.getReminderText() + ")"; ReplacementEffect re = ReplacementHandler.parseReplacement(repeffstr, host, intrinsic, card); - setupETBReplacementAbility(cleanupSA); re.setOverridingAbility(sacrificeSA); inst.addReplacement(re); @@ -3693,14 +3687,6 @@ public class CardFactoryUtil { return altCostSA; } - private static final Map emptyMap = Maps.newTreeMap(); - public static SpellAbility setupETBReplacementAbility(SpellAbility sa) { - AbilitySub as = new AbilitySub(ApiType.InternalEtbReplacement, sa.getHostCard(), null, emptyMap); - sa.appendSubAbility(as); - return as; - // ETBReplacementMove(sa.getHostCard(), null)); - } - public static void setupAdventureAbility(Card card) { if (card.getCurrentStateName() != CardStateName.Adventure) { return; diff --git a/forge-game/src/main/java/forge/game/replacement/ReplaceMoved.java b/forge-game/src/main/java/forge/game/replacement/ReplaceMoved.java index ce068800cca..e370ca9635e 100644 --- a/forge-game/src/main/java/forge/game/replacement/ReplaceMoved.java +++ b/forge-game/src/main/java/forge/game/replacement/ReplaceMoved.java @@ -96,7 +96,7 @@ public class ReplaceMoved extends ReplacementEffect { @Override public void setReplacingObjects(Map runParams, SpellAbility sa) { sa.setReplacingObject(AbilityKey.Card, runParams.get(AbilityKey.Affected)); - sa.setReplacingObjectsFrom(runParams, AbilityKey.CardLKI, AbilityKey.Cause, AbilityKey.LastStateBattlefield, AbilityKey.LastStateGraveyard); + sa.setReplacingObjectsFrom(runParams, AbilityKey.NewCard, AbilityKey.CardLKI, AbilityKey.Cause, AbilityKey.LastStateBattlefield, AbilityKey.LastStateGraveyard); } } 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 1e72eb846ca..7ce788fd936 100644 --- a/forge-game/src/main/java/forge/game/replacement/ReplacementHandler.java +++ b/forge-game/src/main/java/forge/game/replacement/ReplacementHandler.java @@ -211,6 +211,7 @@ public class ReplacementHandler { re.setHostCard(affectedCard); } runParams.put(AbilityKey.Affected, affectedCard); + runParams.put(AbilityKey.NewCard, CardUtil.getLKICopy(affectedLKI)); } game.getAction().checkStaticAbilities(false); } @@ -418,8 +419,8 @@ public class ReplacementHandler { } } - if ("Replaced".equals(replacementEffect.getParam("ReplacementResult"))) { - return ReplacementResult.Replaced; // Event is replaced without SA. + if (replacementEffect.hasParam("ReplacementResult")) { + return ReplacementResult.valueOf(replacementEffect.getParam("ReplacementResult")); // Event is replaced without SA. } // if the spellability is a replace effect then its some new logic diff --git a/forge-gui/res/cardsfolder/b/boreal_outrider.txt b/forge-gui/res/cardsfolder/b/boreal_outrider.txt index 6f454e1f28e..21b4c26cc2f 100644 --- a/forge-gui/res/cardsfolder/b/boreal_outrider.txt +++ b/forge-gui/res/cardsfolder/b/boreal_outrider.txt @@ -4,9 +4,8 @@ Types:Snow Creature Elf Warrior PT:3/2 T:Mode$ SpellCast | ValidCard$ Creature | ValidActivatingPlayer$ You | Execute$ TrigEffect | TriggerZones$ Battlefield | SnowSpentForCardsColor$ True | TriggerDescription$ Whenever you cast a creature spell, if {S} of any of that spell's colors was spent to cast it, that creature enters the battlefield with an additional +1/+1 counter on it. ({S} is mana from a snow source.) SVar:TrigEffect:DB$ Effect | RememberObjects$ TriggeredCard | ReplacementEffects$ ETBCreat -SVar:ETBCreat:Event$ Moved | ValidCard$ Card.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | Description$ That creature enters the battlefield with an additional +1/+1 counter on it. -SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 1 | SubAbility$ ToBattlefield -SVar:ToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBExile +SVar:ETBCreat:Event$ Moved | ValidCard$ Card.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | ReplacementResult$ Updated | Description$ That creature enters the battlefield with an additional +1/+1 counter on it. +SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 1 | SubAbility$ DBExile SVar:DBExile:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile DeckHints:Type$Snow DeckHas:Ability$Counters diff --git a/forge-gui/res/cardsfolder/b/brimstone_vandal.txt b/forge-gui/res/cardsfolder/b/brimstone_vandal.txt index 22dca698de2..37cf7d81cd7 100644 --- a/forge-gui/res/cardsfolder/b/brimstone_vandal.txt +++ b/forge-gui/res/cardsfolder/b/brimstone_vandal.txt @@ -3,9 +3,8 @@ ManaCost:2 R Types:Creature Devil PT:2/3 K:Menace -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ TrigDamage | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, CARDNAME deals 1 damage to each opponent. SVar:TrigDamage:DB$ DealDamage | Defined$ Player.Opponent | NumDmg$ 1 Oracle:Menace (This creature can't be blocked except by two or more creatures.)\nIf it's neither day nor night, it becomes day as Brimstone Vandal enters the battlefield.\nWhenever day becomes night or night becomes day, Brimstone Vandal deals 1 damage to each opponent. diff --git a/forge-gui/res/cardsfolder/c/celestus_sanctifier.txt b/forge-gui/res/cardsfolder/c/celestus_sanctifier.txt index a37a6bd9326..fde2f4559e5 100644 --- a/forge-gui/res/cardsfolder/c/celestus_sanctifier.txt +++ b/forge-gui/res/cardsfolder/c/celestus_sanctifier.txt @@ -2,9 +2,8 @@ Name:Celestus Sanctifier ManaCost:2 W Types:Creature Human Cleric PT:3/2 -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ DBDig | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, look at the top two cards of your library. Put one of them into your graveyard. SVar:DBDig:DB$ Dig | DigNum$ 2 | DestinationZone$ Graveyard | LibraryPosition2$ 0 DeckHas:Ability$Graveyard diff --git a/forge-gui/res/cardsfolder/c/component_collector.txt b/forge-gui/res/cardsfolder/c/component_collector.txt index 5a61b3861e4..1122ebc3a4c 100644 --- a/forge-gui/res/cardsfolder/c/component_collector.txt +++ b/forge-gui/res/cardsfolder/c/component_collector.txt @@ -2,9 +2,8 @@ Name:Component Collector ManaCost:2 U Types:Creature Homunculus PT:1/4 -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ TrigTapOrUntap | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, you may tap or untap target nonland permanent. SVar:TrigTapOrUntap:DB$ TapOrUntap | ValidTgts$ Permanent.nonLand | TgtPrompt$ Select target nonland permanent Oracle:If it's neither day nor night, it becomes day as Component Collector enters the battlefield.\nWhenever day becomes night or night becomes day, you may tap or untap target nonland permanent. diff --git a/forge-gui/res/cardsfolder/f/firmament_sage.txt b/forge-gui/res/cardsfolder/f/firmament_sage.txt index 6e2a28fd737..41d58f743f9 100644 --- a/forge-gui/res/cardsfolder/f/firmament_sage.txt +++ b/forge-gui/res/cardsfolder/f/firmament_sage.txt @@ -2,9 +2,8 @@ Name:Firmament Sage ManaCost:3 U Types:Creature Human Wizard PT:2/3 -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ DBDraw | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, draw a card. SVar:DBDraw:DB$ Draw | Defined$ You | NumCards$ 1 Oracle:If it's neither day nor night, it becomes day as Firmament Sage enters the battlefield.\nWhenever day becomes night or night becomes day, draw a card. diff --git a/forge-gui/res/cardsfolder/g/gavony_dawnguard.txt b/forge-gui/res/cardsfolder/g/gavony_dawnguard.txt index aecacd39f08..3a94aca6777 100644 --- a/forge-gui/res/cardsfolder/g/gavony_dawnguard.txt +++ b/forge-gui/res/cardsfolder/g/gavony_dawnguard.txt @@ -3,9 +3,8 @@ ManaCost:1 W W Types:Creature Human Soldier PT:3/3 K:Ward:1 -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ TrigDig | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, look at the top four cards of your library. You may reveal a creature card with mana value 3 or less from among them and put it into your hand. Put the rest on the bottom of your library in any order. SVar:TrigDig:DB$ Dig | ForceRevealToController$ True | DigNum$ 4 | ChangeNum$ 1 | Optional$ True | ChangeValid$ Creature.cmcLE3 Oracle:Ward {1}\nIf it's neither day nor night, it becomes day as Gavony Dawnguard enters the battlefield.\nWhenever day becomes night or night becomes day, look at the top four cards of your library. You may reveal a creature card with mana value 3 or less from among them and put it into your hand. Put the rest on the bottom of your library in any order. diff --git a/forge-gui/res/cardsfolder/j/jorn_god_of_winter_kaldring_the_rimestaff.txt b/forge-gui/res/cardsfolder/j/jorn_god_of_winter_kaldring_the_rimestaff.txt index 87e0e523f17..456d500e1d0 100644 --- a/forge-gui/res/cardsfolder/j/jorn_god_of_winter_kaldring_the_rimestaff.txt +++ b/forge-gui/res/cardsfolder/j/jorn_god_of_winter_kaldring_the_rimestaff.txt @@ -18,9 +18,7 @@ Types:Legendary Snow Artifact A:AB$ Effect | Cost$ T | TgtZone$ Graveyard | ValidTgts$ Permanent.Snow+YouCtrl | TgtPrompt$ Choose target snow permanent card in your graveyard | StaticAbilities$ STPlay | RememberObjects$ Targeted | ForgetOnMoved$ Graveyard | SubAbility$ DBEffect | SpellDescription$ You may play target snow permanent card from your graveyard this turn. If you do, it enters the battlefield tapped. SVar:STPlay:Mode$ Continuous | MayPlay$ True | EffectZone$ Command | Affected$ Card.IsRemembered | AffectedZone$ Graveyard | Description$ You may play target snow permanent card from your graveyard this turn. SVar:DBEffect:DB$ Effect | RememberObjects$ ParentTarget | ForgetOnMoved$ Stack | ReplacementEffects$ ETBCreat -SVar:ETBCreat:Event$ Moved | ValidCard$ Card.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBTap | Description$ If you do, it enters the battlefield tapped. -SVar:DBTap:DB$ Tap | Defined$ ReplacedCard | ETB$ True | SubAbility$ ToBattlefield -SVar:ToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBExile +SVar:ETBCreat:Event$ Moved | ValidCard$ Card.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBTap | ReplacementResult$ Updated | Description$ If you do, it enters the battlefield tapped. +SVar:DBTap:DB$ Tap | Defined$ ReplacedCard | ETB$ True | SubAbility$ DBExile SVar:DBExile:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile -SVar:STTapped:Mode$ Continuous | Affected$ Card.IsRemembered | AddKeyword$ CARDNAME enters the battlefield tapped. Oracle:{T}: You may play target snow permanent card from your graveyard this turn. If you do, it enters the battlefield tapped. diff --git a/forge-gui/res/cardsfolder/m/moritte_of_the_frost.txt b/forge-gui/res/cardsfolder/m/moritte_of_the_frost.txt index 78665d3e564..e54cafb56e6 100644 --- a/forge-gui/res/cardsfolder/m/moritte_of_the_frost.txt +++ b/forge-gui/res/cardsfolder/m/moritte_of_the_frost.txt @@ -6,9 +6,8 @@ K:Changeling K:ETBReplacement:Copy:DBCopy:Optional SVar:DBCopy:DB$ Clone | Choices$ Permanent.Other+YouCtrl | AddTypes$ Legendary & Snow | SubAbility$ DBConditionEffect | AddKeywords$ Changeling | SpellDescription$ You may have Moritte of the Frost enter the battlefield as a copy of a permanent you control, except it's legendary and snow in addition to its other types and, if it's a creature, it enters with two additional +1/+1 counters on it and has changeling. SVar:DBConditionEffect:DB$ Effect | RememberObjects$ Self | Name$ Moritte of the Frost Effect | ReplacementEffects$ ETBCreat -SVar:ETBCreat:Event$ Moved | ValidCard$ Creature.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | Description$ If it's a creature, it enters with two additional +1/+1 counters on it. -SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 2 | SubAbility$ ToBattlefield -SVar:ToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBExile +SVar:ETBCreat:Event$ Moved | ValidCard$ Creature.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | ReplacementResult$ Updated | Description$ If it's a creature, it enters with two additional +1/+1 counters on it. +SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 2 | SubAbility$ DBExile SVar:DBExile:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile DeckHas:Ability$Counters Oracle:Changeling (This card is every creature type.)\nYou may have Moritte of the Frost enter the battlefield as a copy of a permanent you control, except it's legendary and snow in addition to its other types and, if it's a creature, it enters with two additional +1/+1 counters on it and has changeling. diff --git a/forge-gui/res/cardsfolder/m/mystic_reflection.txt b/forge-gui/res/cardsfolder/m/mystic_reflection.txt index 70e09cf7f73..3ae4e1e2627 100644 --- a/forge-gui/res/cardsfolder/m/mystic_reflection.txt +++ b/forge-gui/res/cardsfolder/m/mystic_reflection.txt @@ -2,9 +2,8 @@ Name:Mystic Reflection ManaCost:1 U Types:Instant A:SP$ Effect | ValidTgts$ Creature.nonLegendary | TgtPrompt$ Choose target nonlegendary creature | RememberObjects$ Targeted | ReplacementEffects$ ReplaceETB | Triggers$ TrigRemove | SpellDescription$ Choose target nonlegendary creature. The next time one or more creatures or planeswalkers enter the battlefield this turn, they enter as copies of the chosen creature. -SVar:ReplaceETB:Event$ Moved | Destination$ Battlefield | ValidCard$ Creature,Planeswalker | ReplaceWith$ EnterAsCopy | Description$ The next time one or more creatures or planeswalkers enter the battlefield this turn, they enter as copies of the chosen creature. -SVar:EnterAsCopy:DB$ Clone | Defined$ Remembered | CloneTarget$ ReplacedCard | SubAbility$ MoveToBattlefield -SVar:MoveToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBImprint +SVar:ReplaceETB:Event$ Moved | Destination$ Battlefield | ValidCard$ Creature,Planeswalker | ReplaceWith$ EnterAsCopy | ReplacementResult$ Updated | Description$ The next time one or more creatures or planeswalkers enter the battlefield this turn, they enter as copies of the chosen creature. +SVar:EnterAsCopy:DB$ Clone | Defined$ Remembered | CloneTarget$ ReplacedCard | SubAbility$ DBImprint SVar:DBImprint:DB$ Pump | ImprintCards$ ReplacedCard SVar:TrigRemove:Mode$ ChangesZoneAll | CheckSVar$ Z | Execute$ ExileSelf | Static$ True SVar:ExileSelf:DB$ ChangeZone | Origin$ Command | Destination$ Exile | Defined$ Self diff --git a/forge-gui/res/cardsfolder/o/obsessive_astronomer.txt b/forge-gui/res/cardsfolder/o/obsessive_astronomer.txt index f52bba4274f..db1433a96c6 100644 --- a/forge-gui/res/cardsfolder/o/obsessive_astronomer.txt +++ b/forge-gui/res/cardsfolder/o/obsessive_astronomer.txt @@ -2,9 +2,8 @@ Name:Obsessive Astronomer ManaCost:1 R Types:Creature Human Wizard PT:2/2 -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ TrigDiscard | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, discard up to two cards, then draw that many cards. SVar:TrigDiscard:DB$ Discard | Defined$ You | NumCards$ 2 | Optional$ True | Mode$ TgtChoose | RememberDiscarded$ True | SubAbility$ DBDraw SVar:DBDraw:DB$ Draw | NumCards$ Y | SubAbility$ DBCleanup diff --git a/forge-gui/res/cardsfolder/s/semesters_end.txt b/forge-gui/res/cardsfolder/s/semesters_end.txt index 5b004bcd9d3..1828d5bd732 100644 --- a/forge-gui/res/cardsfolder/s/semesters_end.txt +++ b/forge-gui/res/cardsfolder/s/semesters_end.txt @@ -5,12 +5,10 @@ A:SP$ ChangeZone | Cost$ 3 W | ValidTgts$ Creature.YouCtrl,Planeswalker.YouCtrl SVar:DelTrig:DB$ DelayedTrigger | Mode$ Phase | Phase$ End of Turn | Execute$ TrigReturn | RememberObjects$ RememberedLKI | TriggerDescription$ Return each of them to the battlefield under its owner's control. Each of them enters the battlefield with an additional +1/+1 counter on it if it's a creature and an additional loyalty counter on it if it's a planeswalker. | SubAbility$ DBCleanup SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True SVar:TrigReturn:DB$ ChangeZone | Origin$ Exile | Destination$ Battlefield | Defined$ DelayTriggerRememberedLKI | AnimateSubAbility$ DBConditionEffect -SVar:DBConditionEffect:DB$ Effect | RememberObjects$ Remembered | Name$ Semester's End Effect | ReplacementEffects$ ETBCreat,ETBPlans -SVar:ETBCreat:Event$ Moved | ValidCard$ Creature.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | Description$ It enters with an additional +1/+1 counter on it if it's a creature. -SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 1 | SubAbility$ ToBattlefield -SVar:ETBPlans:Event$ Moved | ValidCard$ Planeswalker.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutLOYALTY | Description$ It enters with an additional loyalty counter on it if it's a planeswalker. -SVar:DBPutLOYALTY:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ LOYALTY | ETB$ True | CounterNum$ 1 | SubAbility$ ToBattlefield -SVar:ToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBExile +SVar:DBConditionEffect:DB$ Effect | RememberObjects$ Remembered | Name$ Semester's End Effect | ReplacementEffects$ ETBCreatPlans +SVar:ETBCreatPlans:Event$ Moved | ValidCard$ Creature.IsRemembered,Planeswalker.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | ReplacementResult$ Updated | Description$ It enters with an additional +1/+1 counter on it if it's a creature, it enters with an additional loyalty counter on it if it's a planeswalker. +SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedNewCard.Creature | CounterType$ P1P1 | ETB$ True | CounterNum$ 1 | SubAbility$ DBPutLOYALTY +SVar:DBPutLOYALTY:DB$ PutCounter | Defined$ ReplacedNewCard.Planeswalker | CounterType$ LOYALTY | ETB$ True | CounterNum$ 1 | SubAbility$ DBExile SVar:DBExile:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile SVar:X:Count$Valid Permanent.YouCtrl DeckHas:Ability$Counters diff --git a/forge-gui/res/cardsfolder/s/spark_double.txt b/forge-gui/res/cardsfolder/s/spark_double.txt index 5ed7145ef7b..bf475c23325 100644 --- a/forge-gui/res/cardsfolder/s/spark_double.txt +++ b/forge-gui/res/cardsfolder/s/spark_double.txt @@ -4,12 +4,10 @@ Types:Creature Illusion PT:0/0 K:ETBReplacement:Copy:DBCopy:Optional SVar:DBCopy:DB$ Clone | Choices$ Creature.Other+YouCtrl,Planeswalker.Other+YouCtrl | NonLegendary$ True | SubAbility$ DBConditionEffect | SpellDescription$ You may have CARDNAME enter the battlefield as a copy of a creature or planeswalker you control, except it enters with an additional +1/+1 counter on it if it's a creature, it enters with an additional loyalty counter on it if it's a planeswalker, and it isn't legendary if that permanent is legendary. -SVar:DBConditionEffect:DB$ Effect | RememberObjects$ Self | Name$ Spark Double Effect | ReplacementEffects$ ETBCreat,ETBPlans -SVar:ETBCreat:Event$ Moved | ValidCard$ Creature.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | Description$ It enters with an additional +1/+1 counter on it if it's a creature. -SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 1 | SubAbility$ ToBattlefield -SVar:ETBPlans:Event$ Moved | ValidCard$ Planeswalker.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutLOYALTY | Description$ It enters with an additional loyalty counter on it if it's a planeswalker. -SVar:DBPutLOYALTY:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ LOYALTY | ETB$ True | CounterNum$ 1 | SubAbility$ ToBattlefield -SVar:ToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBExile +SVar:DBConditionEffect:DB$ Effect | RememberObjects$ Self | Name$ Spark Double Effect | ReplacementEffects$ ETBCreatPlans +SVar:ETBCreatPlans:Event$ Moved | ValidCard$ Creature.IsRemembered,Planeswalker.IsRemembered | Destination$ Battlefield | ReplaceWith$ DBPutP1P1 | ReplacementResult$ Updated | Description$ It enters with an additional +1/+1 counter on it if it's a creature, it enters with an additional loyalty counter on it if it's a planeswalker. +SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedNewCard.Creature | CounterType$ P1P1 | ETB$ True | CounterNum$ 1 | SubAbility$ DBPutLOYALTY +SVar:DBPutLOYALTY:DB$ PutCounter | Defined$ ReplacedNewCard.Planeswalker | CounterType$ LOYALTY | ETB$ True | CounterNum$ 1 | SubAbility$ DBExile SVar:DBExile:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile DeckHas:Ability$Counters SVar:NeedsToPlayVar:Z GE1 diff --git a/forge-gui/res/cardsfolder/s/storyweave.txt b/forge-gui/res/cardsfolder/s/storyweave.txt index 79636cd8574..16ba45fe97b 100644 --- a/forge-gui/res/cardsfolder/s/storyweave.txt +++ b/forge-gui/res/cardsfolder/s/storyweave.txt @@ -6,8 +6,7 @@ SVar:P1P1:DB$ PutCounter | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select targe SVar:Lore:DB$ PutCounter | ValidTgts$ Saga.YouCtrl | TgtPrompt$ Select target Saga you control | CounterType$ LORE | CounterNum$ 2 | SubAbility$ DBEffect | SpellDescription$ Put two lore counters on target Saga you control. The next time one or more enchantment creatures enter the battlefield under your control this turn, each enters with two additional +1/+1 counters on it. SVar:DBEffect:DB$ Effect | ReplacementEffects$ ReplaceETB | Triggers$ TrigRemove SVar:ReplaceETB:Event$ Moved | Destination$ Battlefield | ValidCard$ Creature.Enchantment | ReplaceWith$ DBPutP1P1 -SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 2 | SubAbility$ MoveToBattlefield -SVar:MoveToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBImprint +SVar:DBPutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | CounterNum$ 2 | SubAbility$ DBImprint SVar:DBImprint:DB$ Pump | ImprintCards$ ReplacedCard SVar:TrigRemove:Mode$ ChangesZoneAll | CheckSVar$ Z | Execute$ ExileSelf | Static$ True SVar:ExileSelf:DB$ ChangeZone | Origin$ Command | Destination$ Exile | Defined$ Self diff --git a/forge-gui/res/cardsfolder/s/sunrise_cavalier.txt b/forge-gui/res/cardsfolder/s/sunrise_cavalier.txt index 14ce6446a77..bd2918f4184 100644 --- a/forge-gui/res/cardsfolder/s/sunrise_cavalier.txt +++ b/forge-gui/res/cardsfolder/s/sunrise_cavalier.txt @@ -4,9 +4,8 @@ Types:Creature Human Knight PT:3/3 K:Trample K:Haste -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, put a +1/+1 counter on target creature you control. SVar:TrigPutCounter:DB$ PutCounter | ValidTgts$ Creature | TgtPrompt$ Select target creature | CounterType$ P1P1 | CounterNum$ 1 DeckHas:Ability$Counters diff --git a/forge-gui/res/cardsfolder/s/sunstreak_phoenix.txt b/forge-gui/res/cardsfolder/s/sunstreak_phoenix.txt index 43c0591b279..d6238cf91d4 100644 --- a/forge-gui/res/cardsfolder/s/sunstreak_phoenix.txt +++ b/forge-gui/res/cardsfolder/s/sunstreak_phoenix.txt @@ -3,9 +3,8 @@ ManaCost:2 R R Types:Creature Phoenix PT:4/2 K:Flying -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day T:Mode$ DayTimeChanges | Execute$ TrigReturn | TriggerZones$ Graveyard | TriggerDescription$ Whenever day becomes night or night becomes day, you may pay {1}{R}. If you do, return CARDNAME from your graveyard to the battlefield tapped. SVar:TrigReturn:AB$ ChangeZone | Cost$ 1 R | Origin$ Graveyard | Destination$ Battlefield | Tapped$ True DeckHas:Ability$Graveyard diff --git a/forge-gui/res/cardsfolder/t/teferis_time_twist.txt b/forge-gui/res/cardsfolder/t/teferis_time_twist.txt index d0168259415..66e97bfc4a1 100644 --- a/forge-gui/res/cardsfolder/t/teferis_time_twist.txt +++ b/forge-gui/res/cardsfolder/t/teferis_time_twist.txt @@ -5,9 +5,8 @@ A:SP$ ChangeZone | ValidTgts$ Permanent.YouCtrl | TgtPrompt$ Select target perma SVar:DBEffect:DB$ Effect | RememberObjects$ Remembered | Triggers$ ReturnEOT | ReplacementEffects$ EntersAsCreature | SubAbility$ DBCleanup | SpellDescription$ Return that card to the battlefield under its owner's control at the beginning of the next end step. If it enters the battlefield as a creature, it enters with an additional +1/+1 counter on it. SVar:ReturnEOT:Mode$ Phase | Phase$ End of Turn | Execute$ TrigReturn | TriggerDescription$ Return that card to the battlefield under its owner's control at the beginning of the next end step. If it enters the battlefield as a creature, it enters with an additional +1/+1 counter on it. SVar:TrigReturn:DB$ ChangeZone | Origin$ Exile | Destination$ Battlefield | Defined$ RememberedLKI -SVar:EntersAsCreature:Event$ Moved | ValidCard$ Creature.IsRemembered | Destination$ Battlefield | ReplaceWith$ PutP1P1 | Secondary$ True -SVar:PutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | SubAbility$ ToBattlefield -SVar:ToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBExile +SVar:EntersAsCreature:Event$ Moved | ValidCard$ Creature.IsRemembered | Destination$ Battlefield | ReplaceWith$ PutP1P1 | Secondary$ True | ReplacementResult$ Updated +SVar:PutP1P1:DB$ PutCounter | Defined$ ReplacedCard | CounterType$ P1P1 | ETB$ True | SubAbility$ DBExile SVar:DBExile:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True DeckHas:Ability$Counters diff --git a/forge-gui/res/cardsfolder/t/the_celestus.txt b/forge-gui/res/cardsfolder/t/the_celestus.txt index bcb87a0b289..bd1d2460da1 100644 --- a/forge-gui/res/cardsfolder/t/the_celestus.txt +++ b/forge-gui/res/cardsfolder/t/the_celestus.txt @@ -1,9 +1,8 @@ Name:The Celestus ManaCost:3 Types:Legendary Artifact -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day A:AB$ Mana | Cost$ T | Produced$ Any | SpellDescription$ Add one mana of any color. A:AB$ DayTime | Cost$ 3 T | Value$ Switch | SorcerySpeed$ True | SpellDescription$ If it's night, it becomes day. Otherwise, it becomes night. Activate only as a sorcery. T:Mode$ DayTimeChanges | Execute$ DBGainLife | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, you gain 1 life. You may draw a card. If you do, discard a card. diff --git a/forge-gui/res/cardsfolder/upcoming/master_chef.txt b/forge-gui/res/cardsfolder/upcoming/master_chef.txt index 85438fe5eb4..272815e24fe 100644 --- a/forge-gui/res/cardsfolder/upcoming/master_chef.txt +++ b/forge-gui/res/cardsfolder/upcoming/master_chef.txt @@ -2,10 +2,9 @@ Name:Master Chef ManaCost:2 G Types:Legendary Enchantment Background S:Mode$ Continuous | Affected$ Creature.IsCommander+YouOwn | AddReplacementEffects$ This & Other | Description$ Commander creatures you own have "This creature enters the battlefield with an additional +1/+1 counter on it" and "Other creatures you control enter with an additional +1/+1 counter on them." -SVar:This:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | ReplaceWith$ ExtraCounter | Description$ This creature enters the battlefield with an additional +1/+1 counter on it. -SVar:Other:Event$ Moved | ValidCard$ Creature.Other+YouCtrl | Destination$ Battlefield | ReplaceWith$ ExtraCounter | Description$ Other creatures you control enter with an additional +1/+1 counter on them. -SVar:ExtraCounter:DB$ PutCounter | ETB$ True | Defined$ ReplacedCard | CounterType$ P1P1 | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +SVar:This:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | ReplaceWith$ ExtraCounter | ReplacementResult$ Updated | Description$ This creature enters the battlefield with an additional +1/+1 counter on it. +SVar:Other:Event$ Moved | ValidCard$ Creature.Other+YouCtrl | Destination$ Battlefield | ReplaceWith$ ExtraCounter | ReplacementResult$ Updated | Description$ Other creatures you control enter with an additional +1/+1 counter on them. +SVar:ExtraCounter:DB$ PutCounter | ETB$ True | Defined$ ReplacedCard | CounterType$ P1P1 AI:RemoveDeck:NonCommander DeckHas:Ability$Counters Oracle:Commander creatures you own have "This creature enters the battlefield with an additional +1/+1 counter on it" and "Other creatures you control enter with an additional +1/+1 counter on them." diff --git a/forge-gui/res/cardsfolder/v/vadrik_astral_archmage.txt b/forge-gui/res/cardsfolder/v/vadrik_astral_archmage.txt index ef8e41c14b3..8b88309d004 100644 --- a/forge-gui/res/cardsfolder/v/vadrik_astral_archmage.txt +++ b/forge-gui/res/cardsfolder/v/vadrik_astral_archmage.txt @@ -2,9 +2,8 @@ Name:Vadrik, Astral Archmage ManaCost:1 U R Types:Legendary Creature Human Wizard PT:1/2 -R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. -SVar:DoDay:DB$ DayTime | Value$ Day | SubAbility$ ETB -SVar:ETB:DB$ InternalEtbReplacement +R:Event$ Moved | ValidCard$ Card.Self | Destination$ Battlefield | DayTime$ Neither | ReplaceWith$ DoDay | ReplacementResult$ Updated | Description$ If it's neither day nor night, it becomes day as CARDNAME enters the battlefield. +SVar:DoDay:DB$ DayTime | Value$ Day S:Mode$ ReduceCost | ValidCard$ Instant,Sorcery | Type$ Spell | Activator$ You | Amount$ X | Description$ Instant and sorcery spells you cast cost {X} less to cast, where X is NICKNAME's power. SVar:X:Count$CardPower T:Mode$ DayTimeChanges | Execute$ TrigPutCounter | TriggerZones$ Battlefield | TriggerDescription$ Whenever day becomes night or night becomes day, put a +1/+1 counter on NICKNAME. From 0b7033dbb96ec5ec67dd368622a60c50f6523a1b Mon Sep 17 00:00:00 2001 From: Northmoc <103371817+Northmoc@users.noreply.github.com> Date: Sat, 11 Jun 2022 17:55:57 -0400 Subject: [PATCH 18/24] Continuous + MayPlayWithFlash -> CastWithFlash (#661) * Continuous + MayPlayWithFlash -> CastWithFlash --- forge-gui/res/cardsfolder/b/breath_of_the_sleepless.txt | 2 +- forge-gui/res/cardsfolder/c/cherished_hatchling.txt | 2 +- .../res/cardsfolder/upcoming/renari_merchant_of_marvels.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/forge-gui/res/cardsfolder/b/breath_of_the_sleepless.txt b/forge-gui/res/cardsfolder/b/breath_of_the_sleepless.txt index dac1893ea07..77b00673dde 100644 --- a/forge-gui/res/cardsfolder/b/breath_of_the_sleepless.txt +++ b/forge-gui/res/cardsfolder/b/breath_of_the_sleepless.txt @@ -1,7 +1,7 @@ Name:Breath of the Sleepless ManaCost:3 U Types:Enchantment -S:Mode$ Continuous | EffectZone$ Battlefield | Affected$ Spirit.nonToken+YouCtrl | MayPlay$ True | MayPlayPlayer$ CardOwner | MayPlayWithFlash$ True | MayPlayDontGrantZonePermissions$ True | AffectedZone$ Hand,Graveyard,Library,Exile | Description$ You may cast Spirit spells as though they had flash. +S:Mode$ CastWithFlash | ValidCard$ Spirit | ValidSA$ Spell | EffectZone$ Battlefield | Caster$ You | Description$ You may cast Spirit spells as though they had flash. T:Mode$ SpellCast | ValidCard$ Creature | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | OpponentTurn$ True | Execute$ TrigTap | TriggerDescription$ Whenever you cast a creature spell during an opponent's turn, tap up to one target creature. SVar:TrigTap:DB$ Tap | TargetMin$ 0 | TargetMax$ 1 | ValidTgts$ Creature | TgtPrompt$ Select up to one target creature DeckHints:Type$Spirit diff --git a/forge-gui/res/cardsfolder/c/cherished_hatchling.txt b/forge-gui/res/cardsfolder/c/cherished_hatchling.txt index 2e507f1e769..cabbd4e336f 100644 --- a/forge-gui/res/cardsfolder/c/cherished_hatchling.txt +++ b/forge-gui/res/cardsfolder/c/cherished_hatchling.txt @@ -4,7 +4,7 @@ Types:Creature Dinosaur PT:2/1 T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Graveyard | Execute$ TrigEffect | TriggerDescription$ When CARDNAME dies, you may cast Dinosaur spells this turn as though they had flash, and whenever you cast a Dinosaur spell this turn, it gains "When this creature enters the battlefield, you may have it fight another target creature." SVar:TrigEffect:DB$ Effect | Name$ Cherished Hatchling Effect | StaticAbilities$ STFlash | Triggers$ HatchlingCast -SVar:STFlash:Mode$ Continuous | EffectZone$ Command | Affected$ Dinosaur.nonToken+YouCtrl | MayPlay$ True | MayPlayPlayer$ CardOwner | MayPlayWithFlash$ True | MayPlayDontGrantZonePermissions$ True | AffectedZone$ Hand,Graveyard,Library,Exile | Description$ You may cast Dinosaur spells this turn as though they had flash. +SVar:STFlash:Mode$ CastWithFlash | ValidCard$ Dinosaur | ValidSA$ Spell | EffectZone$ Command | Caster$ You | Description$ You may cast Dinosaur spells this turn as though they had flash. SVar:HatchlingCast:Mode$ SpellCast | ValidCard$ Dinosaur | ValidActivatingPlayer$ You | Execute$ TrigHatchlingAnimate | TriggerZones$ Command | TriggerDescription$ Whenever you cast a Dinosaur spell this turn, it gains "When this creature enters the battlefield, you may have it fight another target creature." SVar:TrigHatchlingAnimate:DB$ Animate | Defined$ TriggeredCard | Duration$ Permanent | Triggers$ TrigETBHatchling | sVars$ HatchlingFight SVar:TrigETBHatchling:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ HatchlingFight | OptionalDecider$ You | TriggerDescription$ When this creature enters the battlefield, you may have it fight another target creature. diff --git a/forge-gui/res/cardsfolder/upcoming/renari_merchant_of_marvels.txt b/forge-gui/res/cardsfolder/upcoming/renari_merchant_of_marvels.txt index 085308139e8..a702b1009a7 100644 --- a/forge-gui/res/cardsfolder/upcoming/renari_merchant_of_marvels.txt +++ b/forge-gui/res/cardsfolder/upcoming/renari_merchant_of_marvels.txt @@ -2,7 +2,7 @@ Name:Renari, Merchant of Marvels ManaCost:3 U Types:Legendary Creature Dragon Artificer PT:2/4 -S:Mode$ Continuous | EffectZone$ Battlefield | Affected$ Dragon.nonToken+YouCtrl,Artifact.nonToken+YouCtrl | MayPlay$ True | MayPlayPlayer$ CardOwner | MayPlayWithFlash$ True | MayPlayDontGrantZonePermissions$ True | AffectedZone$ Hand,Graveyard,Library,Exile | Description$ You may cast Dragon spells and artifact spells as though they had flash. +S:Mode$ CastWithFlash | ValidCard$ Dragon,Artifact | ValidSA$ Spell | EffectZone$ Battlefield | Caster$ You | Description$ You may cast Dragon spells and artifact spells as though they had flash. DeckHints:Type$Dragon|Artifact K:Choose a Background Oracle:You may cast Dragon spells and artifact spells as though they had flash.\nChoose a Background (You can have a Background as a second commander.) From 3c9d2e47e1f2d38c662872611045b8a0bd5b0ea3 Mon Sep 17 00:00:00 2001 From: Anthony Calosa Date: Sun, 12 Jun 2022 08:14:42 +0800 Subject: [PATCH 19/24] add default startup --- forge-gui-mobile/src/forge/Forge.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/forge-gui-mobile/src/forge/Forge.java b/forge-gui-mobile/src/forge/Forge.java index 40158d2d39d..6c264b57984 100644 --- a/forge-gui-mobile/src/forge/Forge.java +++ b/forge-gui-mobile/src/forge/Forge.java @@ -403,8 +403,12 @@ public class Forge implements ApplicationListener { } else if (selector.equals("Adventure")) { openAdventure(); clearSplashScreen(); - } else + } else if (splashScreen != null) { splashScreen.setShowModeSelector(true); + } else {//default mode in case splashscreen is null at some point as seen on resume.. + openHomeDefault(); + clearSplashScreen(); + } //start background music SoundSystem.instance.setBackgroundMusic(MusicPlaylist.MENUS); safeToClose = true; From e8c57322a3fe7c72c19c6456b160eec3adb63078 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Sat, 11 Jun 2022 22:00:40 -0400 Subject: [PATCH 20/24] scion_of_halaster.txt tighten up --- forge-gui/res/cardsfolder/upcoming/scion_of_halaster.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/forge-gui/res/cardsfolder/upcoming/scion_of_halaster.txt b/forge-gui/res/cardsfolder/upcoming/scion_of_halaster.txt index 1d3d8326ad8..3070ced3027 100644 --- a/forge-gui/res/cardsfolder/upcoming/scion_of_halaster.txt +++ b/forge-gui/res/cardsfolder/upcoming/scion_of_halaster.txt @@ -3,11 +3,11 @@ ManaCost:1 B Types:Legendary Enchantment Background S:Mode$ Continuous | Affected$ Creature.IsCommander+YouOwn | AddReplacementEffects$ Draw | Description$ Commander creatures you own have "The first time you would draw a card each turn, instead look at the top two cards of your library. Put one of them into your graveyard and the other back on top of your library. Then draw a card." SVar:Draw:Event$ Draw | ValidPlayer$ You | ReplaceWith$ DBDig | CheckSVar$ X | SVarCompare$ EQ0 | CheckSecondSVar$ Y | SecondSVarCompare$ EQ0 | Description$ The first time you would draw a card each turn, instead look at the top two cards of your library. Put one of them into your graveyard and the other back on top of your library. Then draw a card. -SVar:DBDig:DB$ Dig | DigNum$ 2 | AnyNumber$ | DestinationZone$ Graveyard | LibraryPosition2$ 0 | SubAbility$ AllowDraw +SVar:DBDig:DB$ Dig | DigNum$ 2 | DestinationZone$ Graveyard | LibraryPosition2$ 0 | SubAbility$ AllowDraw SVar:AllowDraw:DB$ StoreSVar | SVar$ Y | Type$ Number | Expression$ 1 | SubAbility$ DBDraw SVar:DBDraw:DB$ Draw | SubAbility$ Reset SVar:Reset:DB$ StoreSVar | SVar$ Y | Type$ Number | Expression$ 0 -SVar:X:PlayerCountYou$CardsDrawn +SVar:X:Count$YouDrewThisTurn SVar:Y:Number$0 DeckHas:Ability$Graveyard AI:RemoveDeck:NonCommander From 2ce6eec7b9c9b6d0d487a41f41e39e38f42397d1 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Sat, 11 Jun 2022 22:01:06 -0400 Subject: [PATCH 21/24] CardTraitBase.meetsCommonRequirements add "CheckSecondSVar" --- .../src/main/java/forge/game/CardTraitBase.java | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/forge-game/src/main/java/forge/game/CardTraitBase.java b/forge-game/src/main/java/forge/game/CardTraitBase.java index 652cb6b2fc8..7fccfb5c2df 100644 --- a/forge-game/src/main/java/forge/game/CardTraitBase.java +++ b/forge-game/src/main/java/forge/game/CardTraitBase.java @@ -434,8 +434,19 @@ public abstract class CardTraitBase extends GameObject implements IHasCardView, if (!Expressions.compare(sVar, svarOperator, operandValue)) { return false; } + if (hasParam("CheckSecondSVar")) { + final int sVar2 = AbilityUtils.calculateAmount(this.hostCard, getParam("CheckSecondSVar"), this); + final String comparator2 = getParamOrDefault("SecondSVarCompare", "GE1"); + final String svarOperator2 = comparator2.substring(0, 2); + final String svarOperand2 = comparator2.substring(2); + final int operandValue2 = AbilityUtils.calculateAmount(this.hostCard, svarOperand2, this); + if (!Expressions.compare(sVar2, svarOperator2, operandValue2)) { + return false; + } + } } + if (params.containsKey("ManaSpent")) { SpellAbility castSA = getHostCard().getCastSA(); if (castSA == null) { From 7971aa01759354703aa47244567f024fac55f7de Mon Sep 17 00:00:00 2001 From: Northmoc Date: Sat, 11 Jun 2022 22:05:34 -0400 Subject: [PATCH 22/24] remove unneeded whitespace --- forge-game/src/main/java/forge/game/CardTraitBase.java | 1 - 1 file changed, 1 deletion(-) diff --git a/forge-game/src/main/java/forge/game/CardTraitBase.java b/forge-game/src/main/java/forge/game/CardTraitBase.java index 7fccfb5c2df..f2c791042c4 100644 --- a/forge-game/src/main/java/forge/game/CardTraitBase.java +++ b/forge-game/src/main/java/forge/game/CardTraitBase.java @@ -446,7 +446,6 @@ public abstract class CardTraitBase extends GameObject implements IHasCardView, } } - if (params.containsKey("ManaSpent")) { SpellAbility castSA = getHostCard().getCastSA(); if (castSA == null) { From bbad864db1ef084c8f54d420c344869742a0db69 Mon Sep 17 00:00:00 2001 From: Michael Kamensky Date: Sun, 12 Jun 2022 09:07:26 +0300 Subject: [PATCH 23/24] - Add MTGO Khans Expanded Cube and MTGO Vintage Cube February 2022. --- .../res/cube/MTGO Khans Expanded Cube.dck | 498 ++++++++++++++++ .../cube/MTGO Vintage Cube Februrary 2022.dck | 543 ++++++++++++++++++ .../res/draft/MTGO Khans Expanded Cube.draft | 6 + .../MTGO Vintage Cube Februrary 2022.draft | 6 + 4 files changed, 1053 insertions(+) create mode 100644 forge-gui/res/cube/MTGO Khans Expanded Cube.dck create mode 100644 forge-gui/res/cube/MTGO Vintage Cube Februrary 2022.dck create mode 100644 forge-gui/res/draft/MTGO Khans Expanded Cube.draft create mode 100644 forge-gui/res/draft/MTGO Vintage Cube Februrary 2022.draft diff --git a/forge-gui/res/cube/MTGO Khans Expanded Cube.dck b/forge-gui/res/cube/MTGO Khans Expanded Cube.dck new file mode 100644 index 00000000000..1452ed368ab --- /dev/null +++ b/forge-gui/res/cube/MTGO Khans Expanded Cube.dck @@ -0,0 +1,498 @@ +[metadata] +Name=MTGO Khans Expanded Cube +[main] +1 Herald of Anafenza|KTK +1 Embodiment of Spring|KTK +1 Bloodsoaked Champion|KTK +1 Kolaghan Stormsinger|DTK +1 Experiment One|GTC +1 Taigam, Ojutai Master|C17 +1 Chronomaton|M13 +1 Arid Mesa|MH2 +1 Mardu Hateblade|KTK +1 Enclave Cryptologist|ROE +1 Cruel Sadist|M15 +1 Monastery Swiftspear|IMA +1 Gnarlwood Dryad|EMN +1 Ojutai, Soul of Winter|FRF +1 Filigree Familiar|KLD +1 Ash Barrens|2XM +1 Mardu Woe-Reaper|FRF +1 Deranged Assistant|UMA +1 Disowned Ancestor|KTK +1 Abbot of Keral Keep|ORI +1 Patron of the Wild|LGN +1 Dragonlord Silumgar|DTK +1 Pilgrim's Eye|EMA +1 Battlefield Forge|ORI +1 Ainok Bond-Kin|IMA +1 Elusive Spellfist|IMA +1 Ruthless Ripper|A25 +1 Firebrand Archer|AKR +1 Pelt Collector|GRN +1 Connive // Concoct|GRN +1 Skittering Surveyor|DOM +1 Blood Crypt|RNA +1 Daring Skyjek|GTC +1 Jeskai Elder|M21 +1 Shambling Goblin|CN2 +1 Horde Ambusher|KTK +1 Ainok Survivalist|A25 +1 Dreadhorde Butcher|WAR +1 Awakened Amalgam|RIX +1 Bloodfell Caves|NEO +1 Hidden Dragonslayer|DTK +1 Jeskai Sage|FRF +1 Battle Brawler|FRF +1 Ire Shaman|A25 +1 Broodhatch Nantuko|A25 +1 Dragonlord Kolaghan|DTK +1 Peace Strider|2XM +1 Bloodstained Mire|EXP +1 Master of Pearls|KTK +1 Plaxmanta|DIS +1 Kitesail Freebooter|M21 +1 Jeering Instigator|UGF +1 Deadly Recluse|M14 +1 Ghor-Clan Rampager|2XM +1 Rampaging Monument|GRN +1 Blooming Marsh|KLD +1 Remorseful Cleric|M19 +1 Qarsi Deceiver|DTK +1 Mardu Skullhunter|KTK +1 Kiln Fiend|IMA +1 Decorated Champion +1 Atarka, World Render|FRF +1 Solemn Simulacrum|M21 +1 Blossoming Sands|NEO +1 Seeker of the Way|IMA +1 Spellweaver Eternal|AKR +1 Silumgar Assassin|DTK +1 Mogg War Marshal|EMA +1 Den Protector|DTK +1 Knight of Autumn|GRN +1 Chamber Sentry|GRN +1 Botanical Sanctum|KLD +1 Soulfire Grand Master|FRF +1 Stratus Dancer|DTK +1 Skinthinner|LGN +1 Nef-Crop Entangler|AKR +1 Glade Watcher|DTK +1 Dromoka, the Eternal|FRF +1 Duplicant|2XM +1 Breeding Pool|RNA +1 Steward of Solidarity|AKR +1 Willbender|A25 +1 Sultai Emissary|FRF +1 Skirk Marauder|LGN +1 Heir of the Wilds|KTK +1 Chief of the Edge|KTK +1 Animation Module|KLD +1 Caves of Koilos|ORI +1 Tithe Taker|RNA +1 Echo Tracer|LGN +1 Aphetto Exterminator|LGN +1 Thermo-Alchemist|DBL +1 Obsessive Skinner|SOI +1 Chief of the Scale|KTK +1 Ghostfire Blade|UGF +1 Concealed Courtyard|KLD +1 Wall of Omens|EMA +1 Riptide Entrancer|ONS +1 Blood-Chin Fanatic|DTK +1 War-Name Aspirant|KTK +1 Rattleclaw Mystic|KTK +1 Elenda, the Dusk Rose|RIX +1 Sylvok Lifestaff|SOM +1 Dismal Backwater|NEO +1 Abzan Falconer|IMA +1 Riptide Survivor|SCG +1 Graveblade Marauder|ORI +1 Crater Elemental|DTK +1 Ilysian Caryatid|THB +1 Mortify|RNA +1 Triangle of War|VMA +1 Evolving Wilds|DBL +1 Arashin Foremost|DTK +1 Aphetto Runecaster|SCG +1 Grim Haruspex|UGF +1 Flamewake Phoenix|FRF +1 Deathmist Raptor|DTK +1 Start // Finish|AKR +1 Cranial Archive|KTK +1 Flooded Strand|EXP +1 Kor Sanctifiers|ZEN +1 Gurmag Drowner|DTK +1 Mardu Strike Leader|FRF +1 Legion Warboss|GRN +1 Springbloom Druid|MH1 +1 Utter End|KTK +1 Dream Chisel|ONS +1 Frontier Bivouac|KTK +1 Mardu Hordechief|KTK +1 Kheru Spellsnatcher|KTK +1 Necravolver|APC +1 Bonecrusher Giant|ELD +1 Tuskguard Captain|KTK +1 Castigate|GPT +1 Guild Globe|WAR +1 Godless Shrine|RNA +1 Monastery Mentor|FRF +1 Master of the Veil|LGN +1 Bane of the Living|LGN +1 Reckless Bushwhacker|OGW +1 Anavolver|APC +1 Obzedat's Aid|DGM +1 Leering Emblem|EVE +1 Grand Coliseum|VMA +1 Wingbeat Warrior|LGN +1 Mistfire Weaver|KTK +1 Bellowing Saddlebrute|KTK +1 Skirk Commando|A25 +1 Armorcraft Judge|KLD +1 Death Grasp|VMA +1 Prophetic Prism|A25 +1 Hallowed Fountain|RNA +1 Abzan Battle Priest|IMA +1 Niblis of Frost|EMN +1 Gift of Doom +1 Smelt-Ward Minotaur|GRN +1 Goreclaw, Terror of Qal Sisma|M19 +1 Campaign of Vengeance|EMN +1 Stormrider Rig|DTK +1 Hissing Quagmire|OGW +1 Aven Liberator|SCG +1 Talrand, Sky Summoner|M13 +1 Grinning Demon|ONS +1 Ashcloud Phoenix|KTK +1 Nantuko Vigilante|LGN +1 Golgari Guildmage|RAV +1 Trip Noose|SHM +1 Inspiring Vantage|KLD +1 Daru Sanctifier|LGN +1 Chromeshell Crab|LGN +1 Haunted Cadaver|ONS +1 Atarka Efreet|DTK +1 Serpentine Basilisk|ONS +1 Dreg Mangler|RTR +1 Arcane Encyclopedia|M19 +1 Jungle Hollow|NEO +1 Dragonscale General|FRF +1 Icefall Regent|DTK +1 Haunted Dead|EMN +1 Battering Craghorn|ONS +1 Sultai Flayer|IMA +1 Corpsejack Menace|IMA +1 Sickleslicer|2XM +1 Llanowar Wastes|ORI +1 High Sentinels of Arashin|KTK +1 Ixidor, Reality Sculptor|ONS +1 Mer-Ek Nightblade|IMA +1 Blistering Firecat|ONS +1 Surrak, the Hunt Caller|DTK +1 Izoni, Thousand-Eyed|GRN +1 Bonehoard|MBS +1 Lumbering Falls|BFZ +1 Ojutai Exemplars|DTK +1 Ixidron|TSP +1 Thrasher Brute +1 Erratic Cyclops|GRN +1 Thelonite Hermit|TSP +1 Assassin's Trophy|GRN +1 Obelisk of Alara|CFX +1 Marsh Flats|MH2 +1 Stonehorn Dignitary|M12 +1 Mischievous Quanar|SCG +1 Creakwood Ghoul|EVE +1 Goblin Heelcutter|FRF +1 Challenger Troll|WAR +1 Grisly Salvage|RTR +1 Misty Rainforest|MH2 +1 Elite Scaleguard|FRF +1 Soulblade Djinn|ORI +1 Rakshasa Gravecaller|DTK +1 Mardu Heart-Piercer|KTK +1 Conclave Naturalists|2XM +1 Find // Finality|GRN +1 Mystic Monastery|KTK +1 Giant Killer|ELD +1 Vesuvan Shapeshifter|A25 +1 Noosegraf Mob|EMN +1 Caldera Hellion|ALA +1 Gigapede|VMA +1 Death Frenzy|KTK +1 Needle Spires|OGW +1 Patron of the Valiant|ORI +1 Brine Elemental|A25 +1 Silent Specter|ONS +1 Charging Monstrosaur|XLN +1 Hystrodon|ONS +1 Deadbridge Chant|DGM +1 Nomad Outpost|KTK +1 Wingmate Roc|KTK +1 Quicksilver Dragon|ONS +1 Gurmag Angler|UMA +1 Dragon-Style Twins|KTK +1 Kessig Cagebreakers|ISD +1 Nyx Weaver|JOU +1 Opulent Palace|KTK +1 Daru Lancer|ONS +1 Thousand Winds|KTK +1 Tombstalker|MMA +1 Flamerush Rider|FRF +1 Pine Walker|KTK +1 Coiling Oracle|MM3 +1 Overgrown Tomb|GRN +1 Exalted Angel|ONS +1 Dive Down|XLN +1 Necropolis Fiend|KTK +1 Quakefoot Cyclops|MH1 +1 Primal Whisperer|LGN +1 Icefeather Aven|KTK +1 Polluted Delta|EXP +1 Linvala, the Preserver|OGW +1 Opt|STA +1 Ghastly Demise|ODY +1 Skarrgan Hellkite|RNA +1 Hooting Mandrills|UMA +1 Mystic Snake|A25 +1 Prismatic Vista|MH1 +1 Harm's Way|M10 +1 Stubborn Denial|KTK +1 Moment of Craving|RIX +1 Firemaw Kavu|TSP +1 Root Elemental|SCG +1 Sagu Mauler|KTK +1 Rugged Highlands|NEO +1 Path to Exile|2XM +1 Disdainful Stroke|SNC +1 Vicious Offering|DOM +1 Rockshard Elemental|LGN +1 Temur War Shaman|FRF +1 Applied Biomancy|RNA +1 Sacred Foundry|GRN +1 Sheltering Light|XLN +1 Force Away|KTK +1 Expunge|VMA +1 Bedlam Reveler|EMN +1 Hooded Hydra|KTK +1 Ethereal Ambush|FRF +1 Sandsteppe Citadel|KTK +1 Adamant Will|DBL +1 Impulse|VIS +1 Murder|SNC +1 Weapon Surge|2XM +1 Venomspout Brackus|ONS +1 Incubation // Incongruity|RNA +1 Scalding Tarn|MH2 +1 Artful Maneuver|DTK +1 Jilt|APC +1 Foul Renewal|DTK +1 Burning Oil|DKA +1 Earthbrawn|MOR +1 Urban Evolution|UMA +1 Scoured Barrens|NEO +1 Disenchant|ZNR +1 Reality Shift|FRF +1 Price of Fame|GRN +1 Lightning Strike|M19 +1 Grapple with the Past|EMN +1 Secret Plans|KTK +1 Shambling Vent|BFZ +1 Feat of Resistance|M21 +1 Think Twice|UMA +1 Murderous Cut|KTK +1 Temur Battle Rage|2XM +1 Winds of Qal Sisma|FRF +1 Yavimaya's Embrace|2XM +1 Shivan Reef|ORI +1 Feeling of Dread|ISD +1 Twisted Reflection|MH1 +1 Reach of Shadows|FRF +1 Omen of the Forge|THB +1 Crushing Canopy|DBL +1 Stormchaser Mage|OGW +1 Spirebluff Canal|KLD +1 Phalanx Tactics|THB +1 Winds of Rebuke|AKR +1 Death Wind|CN2 +1 Brimstone Volley|2XM +1 Gnaw to the Bone|ISD +1 Bloodwater Entity|HOU +1 Steam Vents|GRN +1 Valorous Stance|DBL +1 Forbidden Alchemy|UMA +1 Duress|DBL +1 Geistblast|SOI +1 Thornado|MH1 +1 Wee Dragonauts|GRN +1 Stomping Ground|RNA +1 Generous Gift|MH1 +1 Phantasmal Form|MH1 +1 Chainer's Edict|UMA +1 Risk Factor|GRN +1 Wild Hunger|UMA +1 Crackling Drake|GRN +1 Swiftwater Cliffs|NEO +1 Radiant's Judgment|ULG +1 Repulse|CN2 +1 Agonizing Remorse|STA +1 Bolt Bend|WAR +1 Become Immense|UMA +1 Hypersonic Dragon|IMA +1 Temple Garden|GRN +1 Rally the Peasants|UMA +1 Sinister Sabotage|GRN +1 Morgue Theft|ODY +1 Burn Away|CN2 +1 Savage Swipe|MH1 +1 Izzet Charm|2XM +1 Temple of Abandon|THB +1 Miraculous Recovery|UMA +1 Chemister's Insight|GRN +1 Mire Triton|THB +1 Deem Worthy|AKR +1 Epic Confrontation|A25 +1 Electrolyze|STA +1 Temple of Deceit|THB +1 Oust|ROE +1 Commit // Memory|AKR +1 Doomfall|AKR +1 Flames of the Raze-Boar|RNA +1 Savage Punch|KTK +1 Sonic Assault|GRN +1 Temple of Enlightenment|THB +1 Collective Effort|EMN +1 Icy Blast|KTK +1 Heartless Pillage|2XM +1 Faithless Looting|STA +1 Tracker's Instincts|DKA +1 Winterflame|KTK +1 Temple of Epiphany|M21 +1 Slaughter the Strong|RIX +1 Dig Through Time|UMA +1 Infest|CN2 +1 Flame Slash|CN2 +1 Winding Way|MH1 +1 Prophetic Bolt|VMA +1 Temple of Malady|M21 +1 End Hostilities|KTK +1 Callous Dismissal|WAR +1 Parting Thoughts|C16 +1 Reckless Charge|MH1 +1 Map the Wastes|FRF +1 Honored Crop-Captain|AKR +1 Temple of Malice|THB +1 Fell the Mighty|C17 +1 Chart a Course|XLN +1 Wander in Death|AKR +1 Nightbird's Clutches|UMA +1 Voracious Hydra|M20 +1 Sunhome Guildmage|MM3 +1 Temple of Mystery|M21 +1 Myth Realized|DTK +1 Strategic Planning|STA +1 Moan of the Unhallowed|UMA +1 Roast|DTK +1 Nissa's Judgment|OGW +1 Viashino Firstblade|DGM +1 Temple of Plenty|THB +1 Mastery of the Unseen|FRF +1 Write into Being|FRF +1 Smiting Helix|MH1 +1 Tormenting Voice|ZNR +1 Spider Spawning|UMA +1 Firemane Avenger|GTC +1 Temple of Silence|M21 +1 Silkwrap|DTK +1 Set Adrift|KTK +1 Vigor Mortis|RAV +1 Arc Lightning|UGF +1 See the Unwritten|KTK +1 Foundry Champion|GTC +1 Temple of Triumph|M21 +1 Suspension Field|KTK +1 Treasure Cruise|UMA +1 Crux of Fate|STA +1 Collective Defiance|EMN +1 Hardened Scales|KTK +1 Integrity // Intervention|GRN +1 Fabled Passage|M21 +1 Lightform|FRF +1 Spontaneous Mutation|EMN +1 Dead Drop|KTK +1 Repeating Barrage|XLN +1 Obscuring Aether|DTK +1 Response // Resurgence|GRN +1 Thornwood Falls|NEO +1 Stasis Snare|BFZ +1 Riddleform|AKR +1 Debilitating Injury|UGF +1 Rolling Temblor|UMA +1 Durable Handicraft|KLD +1 Ride Down|EMN +1 Tranquil Cove|NEO +1 Cast Out|AKR +1 Cloudform|FRF +1 Raiders' Spoils|KTK +1 Crater's Claws|KTK +1 Trail of Mystery|KTK +1 War Flare|FRF +1 Verdant Catacombs|MH2 +1 Righteous Cause|ONS +1 Skywise Teachings|IMA +1 Raiders' Wake|XLN +1 Rageform|FRF +1 Colossal Majesty|M19 +1 Warleader's Helix|UMA +1 Wandering Fumarole|OGW +1 Mantis Rider|KTK +1 Watery Grave|GRN +1 Shu Yun, the Silent Tempest|FRF +1 Wind-Scarred Crag|NEO +1 Elsha of the Infinite +1 Windswept Heath|EXP +1 Warden of the Eye|KTK +1 Wooded Foothills|EXP +1 Efreet Weaponmaster|KTK +1 Yavimaya Coast|ORI +1 Kykar, Wind's Fury|M20 +1 Jeskai Charm|KTK +1 Flying Crane Technique|KTK +1 Jeskai Ascendancy|KTK +1 Alesha, Who Smiles at Death|FRF +1 Butcher of the Horde|KTK +1 Ankle Shanker|KTK +1 Zurgo Helmsmasher|KTK +1 Ponyback Brigade|KTK +1 Crackling Doom|KTK +1 Mardu Charm|KTK +1 Mardu Ascendancy|KTK +1 Fervent Charge|APC +1 Anafenza, the Foremost|KTK +1 Siege Rhino|KTK +1 Armament Corps|KTK +1 Ivorytusk Fortress|KTK +1 Abzan Guide|KTK +1 Abzan Charm|KTK +1 Ready // Willing|DGM +1 Duneblast|KTK +1 Abzan Ascendancy|KTK +1 Sidisi, Brood Tyrant|KTK +1 Rakshasa Vizier|KTK +1 Sultai Soothsayer|KTK +1 Abomination of Gudul|KTK +1 Muldrotha, the Gravetide|DOM +1 Tasigur, the Golden Fang|FRF +1 Sultai Charm|KTK +1 Villainous Wealth|KTK +1 Sultai Ascendancy|KTK +1 Savage Knuckleblade|KTK +1 Yasova Dragonclaw|FRF +1 Avalanche Tusker|KTK +1 Bear's Companion|KTK +1 Surrak Dragonclaw|KTK +1 Intet, the Dreamer|PLC +1 Snowhorn Rider|KTK +1 Temur Charm|KTK +1 Temur Ascendancy|KTK diff --git a/forge-gui/res/cube/MTGO Vintage Cube Februrary 2022.dck b/forge-gui/res/cube/MTGO Vintage Cube Februrary 2022.dck new file mode 100644 index 00000000000..4e4259f7558 --- /dev/null +++ b/forge-gui/res/cube/MTGO Vintage Cube Februrary 2022.dck @@ -0,0 +1,543 @@ +[metadata] +Name=MTGO Vintage Cube Februrary 2022 +[main] +1 Abbot of Keral Keep|ORI +1 Abrade|DBL +1 Academy Ruins|2XM +1 Acidic Slime|M13 +1 Adanto Vanguard|XLN +1 Adeline, Resplendent Cathar|DBL +1 Ancestral Recall|VMA +1 Ancestral Vision|IMA +1 Ancient Tomb|UMA +1 Animate Dead|EMA +1 Arbor Elf|A25 +1 Archangel Avacyn|SOI +1 Archon of Cruelty|MH2 +1 Archon of Valor's Reach +1 Arid Mesa|MH2 +1 Armageddon|A25 +1 Ashen Rider|THS +1 Ashiok, Nightmare Weaver|THS +1 Assassin's Trophy|GRN +1 Augur of Autumn|DBL +1 Avalanche Riders|TSB +1 Avenger of Zendikar|2XM +1 Azorius Signet|MM3 +1 Badlands|VMA +1 Balance|EMA +1 Baleful Strix|2XM +1 Baneslayer Angel|M21 +1 Banishing Light|THB +1 Baral, Chief of Compliance|AER +1 Basalt Monolith|2XM +1 Batterskull|2XM +1 Bayou|VMA +1 Bazaar of Baghdad|VMA +1 Birds of Paradise|CN2 +1 Birgi, God of Storytelling|KHM +1 Birthing Pod|NPH +1 Bitterblossom|UMA +1 Black Lotus|VMA +1 Blackcleave Cliffs|SOM +1 Blade Splicer|2XM +1 Blightsteel Colossus|2XM +1 Blood Crypt|RNA +1 Bloodchief's Thirst|ZNR +1 Bloodghast|IMA +1 Bloodstained Mire|EXP +1 Bloodthirsty Adversary|DBL +1 Bloodtithe Harvester|DBL +1 Blooming Marsh|KLD +1 Bolas's Citadel|WAR +1 Bomat Courier|KLD +1 Bone Shredder|MH2 +1 Bonecrusher Giant|ELD +1 Boros Signet|MM3 +1 Boseiju, Who Endures|NEO +1 Botanical Sanctum|KLD +1 Braids, Cabal Minion|MH2 +1 Brain Freeze|VMA +1 Brainstorm|STA +1 Brazen Borrower|ELD +1 Breeding Pool|RNA +1 Bribery|8ED +1 Burst Lightning|MM2 +1 Cabal Ritual|VMA +1 Cathar Commando|DBL +1 Celestial Colonnade|UMA +1 Chain Lightning|MPS_AKH +1 Chandra, Torch of Defiance|KLD +1 Channel|STA +1 Char|RAV +1 Chart a Course|XLN +1 Chrome Mox|2XM +1 Circle of Dreams Druid|AFR +1 Coalition Relic|A25 +1 Coercive Portal|VMA +1 Collective Brutality|EMN +1 Concealed Courtyard|KLD +1 Condemn|M11 +1 Consecrated Sphinx|IMA +1 Containment Priest|M21 +1 Copperline Gorge|SOM +1 Council's Judgment|2XM +1 Counterspell|MH2 +1 Courser of Kruphix|A25 +1 Craterhoof Behemoth|MM3 +1 Creeping Tar Pit|UMA +1 Crop Rotation|2XM +1 Crucible of Worlds|M19 +1 Cryptbreaker|EMN +1 Cryptic Command|IMA +1 Cultivate|STA +1 Custodi Lich|CN2 +1 Dack Fayden|EMA +1 Damn|MH2 +1 Damnation|MPS_AKH +1 Daretti, Ingenious Iconoclast|CN2 +1 Daretti, Scrap Savant|C16 +1 Dark Confidant|2XM +1 Dark Depths|2XM +1 Dark Ritual|STA +1 Darkslick Shores|SOM +1 Dauthi Voidwalker|MH2 +1 Daze|MPS_AKH +1 Deathcap Glade|DBL +1 Deceiver Exarch|CN2 +1 Demonic Tutor|STA +1 Deranged Hermit|VMA +1 Deserted Beach|DBL +1 Desperate Ritual|UMA +1 Destructive Force|M11 +1 Devoted Druid|UMA +1 Dig Through Time|UMA +1 Dimir Signet|MM3 +1 Dire Fleet Daredevil|RIX +1 Disenchant|ZNR +1 Dismember|MM2 +1 Dockside Extortionist +1 Dragon's Rage Channeler|MH2 +1 Dreamroot Cascade|DBL +1 Duress|DBL +1 Eater of Virtue|NEO +1 Echo of Eons|MH1 +1 Edric, Spymaster of Trest|VMA +1 Eidolon of the Great Revel|A25 +1 Elder Gargaroth|M21 +1 Elesh Norn, Grand Cenobite|IMA +1 Elite Spellbinder|STX +1 Elspeth Conquers Death|THB +1 Elspeth, Knight-Errant|MMA +1 Elspeth, Sun's Champion|THS +1 Elvish Mystic|M15 +1 Elvish Reclaimer|M20 +1 Embereth Shieldbreaker|ELD +1 Empty the Warrens|MMA +1 Emrakul, the Aeons Torn|UMA +1 Emrakul, the Promised End|EMN +1 Emry, Lurker of the Loch|ELD +1 Endurance|MH2 +1 Entomb|UMA +1 Ephemerate|STA +1 Escape to the Wilds|ELD +1 Esper Sentinel|MH2 +1 Eternal Witness|UMA +1 Eureka|VMA +1 Everflowing Chalice|2XM +1 Exhume|USG +1 Expansion // Explosion|GRN +1 Expressive Iteration|STX +1 Fable of the Mirror-Breaker|NEO +1 Fact or Fiction|MH1 +1 Faithless Looting|STA +1 Fallen Shinobi|MH1 +1 Fastbond|VMA +1 Fatal Push|2XM +1 Fauna Shaman|UMA +1 Field of the Dead|M20 +1 Fiery Islet|MH1 +1 Figure of Destiny|MMA +1 Finale of Devastation|WAR +1 Fireblast|VMA +1 Firebolt|MH1 +1 Flickerwisp|2XM +1 Flooded Strand|EXP +1 Force of Negation|MH1 +1 Force of Will|2XM +1 Fractured Identity|C17 +1 Frantic Search|UMA +1 Fury|MH2 +1 Fyndhorn Elves|VMA +1 Gaea's Cradle|USG +1 Garruk Relentless|ISD +1 Garruk Wildspeaker|M11 +1 Geist of Saint Traft|2XM +1 Gideon Blackblade|WAR +1 Gideon Jura|M12 +1 Gideon, Ally of Zendikar|BFZ +1 Gilded Drake|USG +1 Gilded Lotus|DOM +1 Gitaxian Probe|NPH +1 Giver of Runes|MH1 +1 Glen Elendra Archmage|UMA +1 Goblin Bombardment|MH2 +1 Goblin Electromancer|GRN +1 Goblin Guide|2XM +1 Goblin Rabblemaster|M15 +1 Goblin Welder|ULG +1 Godless Shrine|RNA +1 Goldspan Dragon|KHM +1 Golgari Signet|MM3 +1 Golos, Tireless Pilgrim|M20 +1 Gonti, Lord of Luxury|KLD +1 Grave Titan|M12 +1 Green Sun's Zenith|EMA +1 Grief|MH2 +1 Grim Lavamancer|2XM +1 Grim Monolith|ULG +1 Griselbrand|MM3 +1 Grist, the Hunger Tide|MH2 +1 Gruul Signet|MM3 +1 Gush|VMA +1 Halana and Alena, Partners|DBL +1 Hallowed Fountain|RNA +1 Hangarback Walker|MPS_KLD +1 Haunted Ridge|DBL +1 Hazoret the Fervent|AKR +1 Heartbeat of Spring|2XM +1 Hellrider|MM3 +1 Hero of Bladehold|MBS +1 Hero's Downfall|DBL +1 Hexdrinker|MH1 +1 High Tide|VMA +1 Horizon Canopy|IMA +1 Hornet Queen|AKR +1 Hullbreaker Horror|DBL +1 Huntmaster of the Fells|DKA +1 Hydroid Krasis|RNA +1 Hymn to Tourach|EMA +1 Ignoble Hierarch|MH2 +1 Imperial Recruiter|MH2 +1 Imperial Seal|PTK +1 Incinerate|M12 +1 Infernal Grasp|DBL +1 Inferno Titan|M12 +1 Inkwell Leviathan|2XM +1 Inquisition of Kozilek|STA +1 Inspiring Vantage|KLD +1 Intrepid Adversary|DBL +1 Iona, Shield of Emeria|MM2 +1 Izzet Signet|MM3 +1 Jace, the Mind Sculptor|VMA +1 Jace, Vryn's Prodigy|ORI +1 Jin-Gitaxias, Progress Tyrant|NEO +1 Jokulhaups|6ED +1 Joraga Treespeaker|ROE +1 Karakas|UMA +1 Karmic Guide|MH2 +1 Karn Liberated|2XM +1 Karn, Scion of Urza|DOM +1 Kiki-Jiki, Mirror Breaker|IMA +1 Kitchen Finks|UMA +1 Knight of Autumn|GRN +1 Knight of the Reliquary|IMA +1 Kogla, the Titan Ape|IKO +1 Kolaghan's Command|DTK +1 Koth of the Hammer|SOM +1 Kroxa, Titan of Death's Hunger|THB +1 Kuldotha Forgemaster|2XM +1 Laelia, the Blade Reforged +1 Land Tax|2XM +1 Lavaclaw Reaches|UMA +1 Leonin Relic-Warder|C17 +1 Leovold, Emissary of Trest|UMA +1 Library of Alexandria|VMA +1 Life from the Loam|UMA +1 Light Up the Stage|RNA +1 Lightning Bolt|STA +1 Lightning Helix|STA +1 Liliana of the Veil|UMA +1 Liliana, the Last Hope|EMN +1 Lion Sash|NEO +1 Lion's Eye Diamond|MIR +1 Living Death|A25 +1 Llanowar Elves|DOM +1 Lodestone Golem|MM2 +1 Lotus Bloom|MMA +1 Lotus Petal|MPS_KLD +1 Lurrus of the Dream-Den|IKO +1 Lyra Dawnbringer|DOM +1 Maelstrom Pulse|2XM +1 Magus of the Order +1 Makeshift Mannequin|LRW +1 Mana Crypt|2XM +1 Mana Drain|IMA +1 Mana Flare|5ED +1 Mana Leak|IMA +1 Mana Tithe|STA +1 Mana Vault|UMA +1 Manamorphose|2XM +1 Marsh Flats|MH2 +1 Massacre Wurm|M21 +1 Memory Deluge|DBL +1 Memory Jar|VMA +1 Mesmeric Fiend|A25 +1 Metalworker|UDS +1 Mind Twist|MPS_AKH +1 Mind's Desire|STA +1 Mindslaver|SOM +1 Mirari's Wake|MH2 +1 Miscalculation|ULG +1 Mishra's Factory|MH2 +1 Mishra's Workshop|ATQ +1 Misty Rainforest|MH2 +1 Monastery Mentor|FRF +1 Monastery Swiftspear|IMA +1 Mother of Runes|EMA +1 Mox Diamond|TPR +1 Mox Emerald|VMA +1 Mox Jet|VMA +1 Mox Pearl|VMA +1 Mox Ruby|VMA +1 Mox Sapphire|VMA +1 Mulldrifter|MM2 +1 Murderous Rider|ELD +1 Murktide Regent|MH2 +1 Mutavault|M14 +1 Myr Battlesphere|2XM +1 Mystic Confluence|C15 +1 Mystical Tutor|EMA +1 Nahiri, the Harbinger|SOI +1 Narset, Parter of Veils|WAR +1 Nashi, Moon Sage's Scion|NEO +1 Natural Order|STA +1 Necromancy|VIS +1 Night's Whisper|EMA +1 Nighthawk Scavenger|ZNR +1 Nissa, Vastwood Seer|ORI +1 Nissa, Who Shakes the World|WAR +1 Niv-Mizzet Reborn|WAR +1 Noble Hierarch|2XM +1 Nurturing Peatland|MH1 +1 Oath of Druids|TPR +1 Oblivion Stone|2XM +1 Oko, Thief of Crowns|ELD +1 Olivia, Crimson Bride|DBL +1 Omnath, Locus of Creation|ZNR +1 Oona's Prowler|LRW +1 Ophiomancer|C13 +1 Opposition|MPS_AKH +1 Oracle of Mul Daya|ZEN +1 Orzhov Signet|MM3 +1 Oust|ROE +1 Overgrown Farmland|DBL +1 Overgrown Tomb|GRN +1 Pack Rat|RTR +1 Palace Jailer|CN2 +1 Palinchron|VMA +1 Parallax Wave|VMA +1 Past in Flames|MM3 +1 Path to Exile|2XM +1 Pest Infestation +1 Pestermite|MMA +1 Phantasmal Image|MM3 +1 Phyrexian Metamorph|2XM +1 Phyrexian Revoker|2XM +1 Pia and Kiran Nalaar|ORI +1 Plateau|VMA +1 Plow Under|8ED +1 Polluted Delta|EXP +1 Polukranos, World Eater|THS +1 Ponder|M12 +1 Porcelain Legionnaire|NPH +1 Portent|5ED +1 Preordain|M11 +1 Primeval Titan|IMA +1 Prismatic Vista|MH1 +1 Progenitus|MMA +1 Putrid Imp|VMA +1 Pyretic Ritual|M11 +1 Questing Beast|ELD +1 Ragavan, Nimble Pilferer|MH2 +1 Raging Ravine|UMA +1 Rakdos Signet|MM3 +1 Ramunap Excavator|AKR +1 Ravages of War|PTK +1 Ravenous Chupacabra|A25 +1 Razorverge Thicket|SOM +1 Reanimate|UMA +1 Reclamation Sage|2XM +1 Recruiter of the Guard|CN2 +1 Recurring Nightmare|TPR +1 Red Elemental Blast|A25 +1 Regrowth|STA +1 Relic of Progenitus|EMA +1 Remand|MM2 +1 Repeal|IMA +1 Restoration Angel|IMA +1 Retrofitter Foundry +1 Rishadan Port|A25 +1 Rockfall Vale|DBL +1 Rofellos, Llanowar Emissary|VMA +1 Rotting Regisaur|M20 +1 Runaway Steam-Kin|GRN +1 Sacred Foundry|GRN +1 Sakura-Tribe Elder|CNS +1 Satoru Umezawa|NEO +1 Savannah|VMA +1 Scalding Tarn|MH2 +1 Scavenging Ooze|M21 +1 Scrapheap Scrounger|KLD +1 Scrubland|VMA +1 Sea Gate Stormcaller|ZNR +1 Seachrome Coast|SOM +1 Seasoned Pyromancer|MH1 +1 Sedgemoor Witch|STX +1 Seething Song|9ED +1 Selesnya Signet|MM3 +1 Selfless Spirit|EMN +1 Sensei's Divining Top|EMA +1 Shallow Grave|MIR +1 Shark Typhoon|IKO +1 Shattered Sanctum|DBL +1 Shelldock Isle|LRW +1 Shipwreck Marsh|DBL +1 Show and Tell|CN2 +1 Showdown of the Skalds|KHM +1 Shriekmaw|UMA +1 Silent Clearing|MH1 +1 Silverblade Paladin|AVR +1 Simic Signet|MM3 +1 Skullclamp|VMA +1 Skyclave Apparition|ZNR +1 Skyclave Shade|ZNR +1 Smokestack|VMA +1 Smuggler's Copter|KLD +1 Snapcaster Mage|UMA +1 Sneak Attack|2XM +1 Snuff Out|MMQ +1 Sol Ring|MPS_KLD +1 Solitude|MH2 +1 Soulfire Grand Master|FRF +1 Sower of Temptation|LRW +1 Spear of Heliod|THS +1 Spectral Procession|MM2 +1 Spell Pierce|NEO +1 Spellseeker +1 Sphinx of the Steel Wind|EMA +1 Spirebluff Canal|KLD +1 Spirit-Sister's Call|NEO +1 Splinter Twin|MM2 +1 Steam Vents|GRN +1 Stomping Ground|RNA +1 Stoneforge Mystic|2XM +1 Stormcarved Coast|DBL +1 Strip Mine|EXP +1 Student of Warfare|ROE +1 Sulfuric Vortex|EMA +1 Sun Titan|M12 +1 Sunbaked Canyon|MH1 +1 Sundering Titan|2XM +1 Sundown Pass|DBL +1 Survival of the Fittest|TPR +1 Suspicious Stowaway|DBL +1 Sword of Body and Mind|2XM +1 Sword of Feast and Famine|2XM +1 Sword of Fire and Ice|2XM +1 Swords to Plowshares|STA +1 Sylvan Caryatid|THS +1 Sylvan Library|EMA +1 Taiga|VMA +1 Tamiyo, Compleated Sage|NEO +1 Tangle Wire|NMS +1 Teferi, Hero of Dominaria|DOM +1 Teferi, Time Raveler|WAR +1 Temple Garden|GRN +1 Tendrils of Agony|STA +1 Terastodon|2XM +1 Tezzeret the Seeker|MM2 +1 Thalia, Guardian of Thraben|DBL +1 Thassa's Oracle|THB +1 The Gitrog Monster|SOI +1 The Restoration of Eiganjo|NEO +1 The Scarab God|AKR +1 The Wandering Emperor|NEO +1 Thespian's Stage|2XM +1 Thieving Skydiver|ZNR +1 Thirst for Discovery|DBL +1 Thoughtseize|AKR +1 Thousand-Year Storm|GRN +1 Thraben Inspector|2XM +1 Thragtusk|2XM +1 Thran Dynamo|IMA +1 Through the Breach|UMA +1 Thundermaw Hellkite|IMA +1 Tidehollow Sculler|MMA +1 Time Spiral|USG +1 Time Walk|VMA +1 Time Warp|STA +1 Timetwister|VMA +1 Tinker|ULG +1 Tireless Tracker|SOI +1 Tolarian Academy|VMA +1 Toski, Bearer of Secrets|KHM +1 Tovolar's Huntmaster|DBL +1 Toxic Deluge|2XM +1 Treachery|UDS +1 Treasure Cruise|UMA +1 Trinket Mage|SOM +1 Tropical Island|VMA +1 Tundra|VMA +1 Turnabout|VMA +1 Ugin, the Spirit Dragon|FRF +1 Ulamog, the Ceaseless Hunger|BFZ +1 Ulamog, the Infinite Gyre|UMA +1 Umezawa's Jitte|BOK +1 Unburial Rites|UMA +1 Underground Sea|VMA +1 Underworld Breach|THB +1 Unholy Heat|MH2 +1 Upheaval|MH2 +1 Uro, Titan of Nature's Wrath|THB +1 Urza's Saga|MH2 +1 Urza, Lord High Artificer|MH1 +1 Usher of the Fallen|KHM +1 Utopia Sprawl|A25 +1 Vampire Hexmage|2XM +1 Vampiric Tutor|EMA +1 Vendilion Clique|A25 +1 Venser, Shaper Savant|MM3 +1 Verdant Catacombs|MH2 +1 Vindicate|MH2 +1 Volcanic Island|VMA +1 Volrath's Stronghold|STH +1 Voltaic Visionary|DBL +1 Vraska, Golgari Queen|GRN +1 Vryn Wingmare|M21 +1 Walking Ballista|2XM +1 Wall of Omens|EMA +1 Wall of Roots|IMA +1 Wasteland|EMA +1 Waterlogged Grove|MH1 +1 Watery Grave|GRN +1 Wear // Tear|DGM +1 Wheel of Fortune|VMA +1 Wheel of Misfortune +1 Whisperwood Elemental|FRF +1 Windswept Heath|EXP +1 Winter Orb|EMA +1 Wishclaw Talisman|ELD +1 Woe Strider|THB +1 Wooded Foothills|EXP +1 Woodfall Primus|UMA +1 Worldly Tutor|6ED +1 Worn Powerstone|EMA +1 Wrath of God|AKR +1 Wrenn and Six|MH1 +1 Wurmcoil Engine|2XM +1 Yawgmoth's Bargain|UDS +1 Yawgmoth's Will|USG +1 Yorion, Sky Nomad|IKO +1 Young Pyromancer|UMA +1 Zealous Conscripts|MM3 diff --git a/forge-gui/res/draft/MTGO Khans Expanded Cube.draft b/forge-gui/res/draft/MTGO Khans Expanded Cube.draft new file mode 100644 index 00000000000..5e47a880498 --- /dev/null +++ b/forge-gui/res/draft/MTGO Khans Expanded Cube.draft @@ -0,0 +1,6 @@ +Name:MTGO Khans Expanded Cube +DeckFile:MTGO Khans Expanded Cube +Singleton:True + +Booster: 15 Any +NumPacks: 3 diff --git a/forge-gui/res/draft/MTGO Vintage Cube Februrary 2022.draft b/forge-gui/res/draft/MTGO Vintage Cube Februrary 2022.draft new file mode 100644 index 00000000000..a9e0061d8c8 --- /dev/null +++ b/forge-gui/res/draft/MTGO Vintage Cube Februrary 2022.draft @@ -0,0 +1,6 @@ +Name:MTGO Vintage Cube Februrary 2022 +DeckFile:MTGO Vintage Cube Februrary 2022 +Singleton:True + +Booster: 15 Any +NumPacks: 3 From c6542347ea7c3f476d2112f1d0cd524fa22356d1 Mon Sep 17 00:00:00 2001 From: Hans Mackowiak Date: Sun, 12 Jun 2022 19:41:49 +0200 Subject: [PATCH 24/24] Card: add Table for ChangedSVars (#426) * Card: add Table for ChangedSVars --- .../src/main/java/forge/ai/AiController.java | 4 +- .../main/java/forge/ai/ability/AnimateAi.java | 10 +++-- .../java/forge/ai/ability/DamageDealAi.java | 3 +- .../main/java/forge/ai/ability/PumpAi.java | 2 +- .../main/java/forge/game/CardTraitBase.java | 11 +---- .../src/main/java/forge/game/GameAction.java | 9 +--- .../main/java/forge/game/StaticEffect.java | 2 + .../game/ability/SpellAbilityEffect.java | 9 ++-- .../ability/effects/AnimateAllEffect.java | 28 +++++++----- .../game/ability/effects/AnimateEffect.java | 28 +++++++----- .../ability/effects/AnimateEffectBase.java | 1 + .../ability/effects/ControlGainEffect.java | 13 +++--- .../ability/effects/DamageDealEffect.java | 2 +- .../game/ability/effects/LifeLoseEffect.java | 10 +---- .../game/ability/effects/PermanentEffect.java | 5 ++- .../game/ability/effects/RollDiceEffect.java | 6 +-- .../game/ability/effects/VoteEffect.java | 2 +- .../src/main/java/forge/game/card/Card.java | 43 ++++++++----------- .../main/java/forge/game/player/Player.java | 21 ++++++--- .../StaticAbilityContinuous.java | 5 ++- .../util/PlayerControllerForTests.java | 2 +- .../res/cardsfolder/a/abnormal_endurance.txt | 2 +- .../res/cardsfolder/a/aethermages_touch.txt | 2 +- .../res/cardsfolder/a/arm_with_aether.txt | 2 +- forge-gui/res/cardsfolder/b/brawl.txt | 2 +- .../res/cardsfolder/c/cherished_hatchling.txt | 2 +- forge-gui/res/cardsfolder/c/commando_raid.txt | 2 +- .../cosima_god_of_the_voyage_the_omenkeel.txt | 2 +- .../res/cardsfolder/c/cruel_deceiver.txt | 2 +- forge-gui/res/cardsfolder/d/demonic_gifts.txt | 2 +- .../res/cardsfolder/d/driven_despair.txt | 4 +- .../res/cardsfolder/f/flash_conscription.txt | 2 +- .../res/cardsfolder/g/genju_of_the_fields.txt | 2 +- .../res/cardsfolder/g/glyph_of_delusion.txt | 2 +- .../res/cardsfolder/g/gruesome_slaughter.txt | 2 +- .../res/cardsfolder/h/hunters_prowess.txt | 2 +- .../res/cardsfolder/l/launch_the_fleet.txt | 2 +- .../m/malakir_rebirth_malakir_mire.txt | 2 +- forge-gui/res/cardsfolder/m/martyrdom.txt | 2 +- .../res/cardsfolder/m/mindbender_spores.txt | 2 +- forge-gui/res/cardsfolder/m/musician.txt | 2 +- forge-gui/res/cardsfolder/n/necravolver.txt | 2 +- .../res/cardsfolder/n/nimble_trapfinder.txt | 2 +- .../res/cardsfolder/o/open_into_wonder.txt | 2 +- forge-gui/res/cardsfolder/r/rakavolver.txt | 2 +- .../cardsfolder/s/shackles_of_treachery.txt | 2 +- forge-gui/res/cardsfolder/s/showstopper.txt | 2 +- .../res/cardsfolder/s/simic_basilisk.txt | 2 +- .../res/cardsfolder/s/stir_the_pride.txt | 2 +- .../res/cardsfolder/s/storm_the_citadel.txt | 2 +- .../cardsfolder/s/supernatural_stamina.txt | 2 +- forge-gui/res/cardsfolder/t/tenacious_pup.txt | 10 ++--- forge-gui/res/cardsfolder/t/tower_above.txt | 2 +- .../res/cardsfolder/v/verdant_rebirth.txt | 2 +- .../cardsfolder/v/vraska_scheming_gorgon.txt | 2 +- .../res/cardsfolder/v/vraska_the_unseen.txt | 2 +- .../res/cardsfolder/w/warriors_lesson.txt | 2 +- .../res/cardsfolder/w/whipgrass_entangler.txt | 2 +- .../cardsfolder/w/whisperwood_elemental.txt | 2 +- .../java/forge/gamemodes/puzzle/Puzzle.java | 16 ++++--- 60 files changed, 162 insertions(+), 156 deletions(-) diff --git a/forge-ai/src/main/java/forge/ai/AiController.java b/forge-ai/src/main/java/forge/ai/AiController.java index 9327e9666eb..b5c10e2d612 100644 --- a/forge-ai/src/main/java/forge/ai/AiController.java +++ b/forge-ai/src/main/java/forge/ai/AiController.java @@ -1925,8 +1925,8 @@ public class AiController { return Math.min(player.getLife() -1,MyRandom.getRandom().nextInt(Math.max(player.getLife() / 3, player.getWeakestOpponent().getLife())) + 1); } else if ("HighestGetCounter".equals(logic)) { return MyRandom.getRandom().nextInt(3); - } else if (source.hasSVar("EnergyToPay")) { - return AbilityUtils.calculateAmount(source, source.getSVar("EnergyToPay"), sa); + } else if (sa.hasSVar("EnergyToPay")) { + return AbilityUtils.calculateAmount(source, sa.getSVar("EnergyToPay"), sa); } else if ("Vermin".equals(logic)) { return MyRandom.getRandom().nextInt(Math.max(player.getLife() - 5, 0)); } else if ("SweepCreatures".equals(logic)) { diff --git a/forge-ai/src/main/java/forge/ai/ability/AnimateAi.java b/forge-ai/src/main/java/forge/ai/ability/AnimateAi.java index 762585f8bdb..7f3a22dc133 100644 --- a/forge-ai/src/main/java/forge/ai/ability/AnimateAi.java +++ b/forge-ai/src/main/java/forge/ai/ability/AnimateAi.java @@ -500,17 +500,19 @@ public class AnimateAi extends SpellAbilityAi { } // give sVars - if (sVars.size() > 0) { - for (final String s : sVars) { - String actualsVar = source.getSVar(s); + if (sa.hasParam("sVars")) { + Map sVarsMap = Maps.newHashMap(); + for (final String s : sa.getParam("sVars").split(",")) { + String actualsVar = AbilityUtils.getSVar(sa, s); String name = s; if (actualsVar.startsWith("SVar:")) { actualsVar = actualsVar.split("SVar:")[1]; name = actualsVar.split(":")[0]; actualsVar = actualsVar.split(":")[1]; } - card.setSVar(name, actualsVar); + sVarsMap.put(name, actualsVar); } + card.addChangedSVars(sVarsMap, timestamp, 0); } ComputerUtilCard.applyStaticContPT(game, card, null); } diff --git a/forge-ai/src/main/java/forge/ai/ability/DamageDealAi.java b/forge-ai/src/main/java/forge/ai/ability/DamageDealAi.java index c8394b33d4b..420a4be32b7 100644 --- a/forge-ai/src/main/java/forge/ai/ability/DamageDealAi.java +++ b/forge-ai/src/main/java/forge/ai/ability/DamageDealAi.java @@ -53,6 +53,7 @@ import forge.util.MyRandom; public class DamageDealAi extends DamageAiBase { @Override public boolean chkAIDrawback(SpellAbility sa, Player ai) { + final SpellAbility root = sa.getRootAbility(); final String damage = sa.getParam("NumDmg"); Card source = sa.getHostCard(); int dmg = AbilityUtils.calculateAmount(source, damage, sa); @@ -76,7 +77,7 @@ public class DamageDealAi extends DamageAiBase { if (dmg > energy || dmg < 1) { continue; // in case the calculation gets messed up somewhere } - source.setSVar("EnergyToPay", "Number$" + dmg); + root.setSVar("EnergyToPay", "Number$" + dmg); return true; } } diff --git a/forge-ai/src/main/java/forge/ai/ability/PumpAi.java b/forge-ai/src/main/java/forge/ai/ability/PumpAi.java index 4db53dcaf13..e5705d72927 100644 --- a/forge-ai/src/main/java/forge/ai/ability/PumpAi.java +++ b/forge-ai/src/main/java/forge/ai/ability/PumpAi.java @@ -731,7 +731,7 @@ public class PumpAi extends PumpAiBase { if (minus > energy || minus < 1) { continue; // in case the calculation gets messed up somewhere } - source.setSVar("EnergyToPay", "Number$" + minus); + root.setSVar("EnergyToPay", "Number$" + minus); return true; } } diff --git a/forge-game/src/main/java/forge/game/CardTraitBase.java b/forge-game/src/main/java/forge/game/CardTraitBase.java index f2c791042c4..c10cc1a01d2 100644 --- a/forge-game/src/main/java/forge/game/CardTraitBase.java +++ b/forge-game/src/main/java/forge/game/CardTraitBase.java @@ -55,15 +55,13 @@ public abstract class CardTraitBase extends GameObject implements IHasCardView, /** Keys of descriptive (text) parameters. */ private static final ImmutableList descriptiveKeys = ImmutableList.builder() .add("Description", "SpellDescription", "StackDescription", "TriggerDescription").build(); - /** Keys to be followed as SVar names when changing text. */ - private static final ImmutableList mutableKeys = ImmutableList.builder() - .add("AddAbility").build(); /** * Keys that should not changed */ private static final ImmutableList noChangeKeys = ImmutableList.builder() - .add("TokenScript", "LegacyImage", "TokenImage", "NewName", "ChooseFromList").build(); + .add("TokenScript", "LegacyImage", "TokenImage", "NewName", "ChooseFromList") + .add("AddAbility").build(); /** *

@@ -511,11 +509,6 @@ public abstract class CardTraitBase extends GameObject implements IHasCardView, } else if (descriptiveKeys.contains(key)) { // change descriptions differently newValue = AbilityUtils.applyDescriptionTextChangeEffects(value, this); - } else if (mutableKeys.contains(key)) { - // follow SVar and change it - final String originalSVarValue = hostCard.getSVar(value); - hostCard.changeSVar(value, AbilityUtils.applyAbilityTextChangeEffects(originalSVarValue, this)); - newValue = null; } else if (this.getHostCard().hasSVar(value)) { // don't change literal SVar names! newValue = null; diff --git a/forge-game/src/main/java/forge/game/GameAction.java b/forge-game/src/main/java/forge/game/GameAction.java index dfda9c27aa6..8e650d1ae22 100644 --- a/forge-game/src/main/java/forge/game/GameAction.java +++ b/forge-game/src/main/java/forge/game/GameAction.java @@ -233,13 +233,6 @@ public class GameAction { } } - // Clean up the temporary Dash/Blitz SVar when the card leaves the battlefield - // Clean up the temporary AtEOT SVar - String endofTurn = c.getSVar("EndOfTurnLeavePlay"); - if (fromBattlefield && (endofTurn.equals("Dash") || endofTurn.equals("Blitz") || endofTurn.equals("AtEOT"))) { - c.removeSVar("EndOfTurnLeavePlay"); - } - if (fromBattlefield && !toBattlefield) { c.getController().setRevolt(true); } @@ -337,7 +330,7 @@ public class GameAction { CardCollectionView comCards = c.getOwner().getCardsIn(ZoneType.Command); for (final Card effCard : comCards) { for (final ReplacementEffect re : effCard.getReplacementEffects()) { - if (re.hasSVar("CommanderMoveReplacement") && effCard.getEffectSource().getName().equals(c.getRealCommander().getName())) { + if (re.hasParam("CommanderMoveReplacement") && effCard.getEffectSource().getName().equals(c.getRealCommander().getName())) { commanderEffect = effCard; break; } diff --git a/forge-game/src/main/java/forge/game/StaticEffect.java b/forge-game/src/main/java/forge/game/StaticEffect.java index 05bed4adb7a..639f13588cd 100644 --- a/forge-game/src/main/java/forge/game/StaticEffect.java +++ b/forge-game/src/main/java/forge/game/StaticEffect.java @@ -288,6 +288,8 @@ public class StaticEffect { affectedCard.removeCanBlockAdditional(getTimestamp()); } + affectedCard.removeChangedSVars(getTimestamp(), ability.getId()); + affectedCard.updateAbilityTextForView(); // only update keywords and text for view to avoid flickering } return affectedCards; diff --git a/forge-game/src/main/java/forge/game/ability/SpellAbilityEffect.java b/forge-game/src/main/java/forge/game/ability/SpellAbilityEffect.java index da91b969bef..9cd9c20eade 100644 --- a/forge-game/src/main/java/forge/game/ability/SpellAbilityEffect.java +++ b/forge-game/src/main/java/forge/game/ability/SpellAbilityEffect.java @@ -300,13 +300,12 @@ public abstract class SpellAbilityEffect { delTrig.append("| TriggerDescription$ ").append(desc); final Trigger trig = TriggerHandler.parseTrigger(delTrig.toString(), CardUtil.getLKICopy(sa.getHostCard()), intrinsic); + long ts = sa.getHostCard().getGame().getNextTimestamp(); for (final Card c : crds) { trig.addRemembered(c); // Svar for AI - if (!c.hasSVar("EndOfTurnLeavePlay")) { - c.setSVar("EndOfTurnLeavePlay", "AtEOT"); - } + c.addChangedSVars(Collections.singletonMap("EndOfTurnLeavePlay", "AtEOT"), ts, 0); } String trigSA = ""; if (location.equals("Hand")) { @@ -346,9 +345,7 @@ public abstract class SpellAbilityEffect { card.addTrigger(trig); // Svar for AI - if (!card.hasSVar("EndOfTurnLeavePlay")) { - card.setSVar("EndOfTurnLeavePlay", "AtEOT"); - } + card.addChangedSVars(Collections.singletonMap("EndOfTurnLeavePlay", "AtEOT"), card.getGame().getNextTimestamp(), 0); } protected static SpellAbility getForgetSpellAbility(final Card card) { diff --git a/forge-game/src/main/java/forge/game/ability/effects/AnimateAllEffect.java b/forge-game/src/main/java/forge/game/ability/effects/AnimateAllEffect.java index efd631c5773..d79bb6d4502 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/AnimateAllEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/AnimateAllEffect.java @@ -1,10 +1,12 @@ package forge.game.ability.effects; -import java.util.ArrayList; import java.util.Arrays; import java.util.List; +import java.util.Map; import com.google.common.collect.ImmutableList; +import com.google.common.collect.Lists; +import com.google.common.collect.Maps; import forge.GameCommand; import forge.card.CardType; @@ -64,17 +66,17 @@ public class AnimateAllEffect extends AnimateEffectBase { types.add(host.getChosenType2()); } - final List keywords = new ArrayList<>(); + final List keywords = Lists.newArrayList(); if (sa.hasParam("Keywords")) { keywords.addAll(Arrays.asList(sa.getParam("Keywords").split(" & "))); } - final List removeKeywords = new ArrayList<>(); + final List removeKeywords = Lists.newArrayList(); if (sa.hasParam("RemoveKeywords")) { removeKeywords.addAll(Arrays.asList(sa.getParam("RemoveKeywords").split(" & "))); } - final List hiddenKeywords = new ArrayList<>(); + final List hiddenKeywords = Lists.newArrayList(); if (sa.hasParam("HiddenKeywords")) { hiddenKeywords.addAll(Arrays.asList(sa.getParam("HiddenKeywords").split(" & "))); } @@ -99,27 +101,32 @@ public class AnimateAllEffect extends AnimateEffectBase { } // abilities to add to the animated being - final List abilities = new ArrayList<>(); + final List abilities = Lists.newArrayList(); if (sa.hasParam("Abilities")) { abilities.addAll(Arrays.asList(sa.getParam("Abilities").split(","))); } // replacement effects to add to the animated being - final List replacements = new ArrayList<>(); + final List replacements = Lists.newArrayList(); if (sa.hasParam("Replacements")) { replacements.addAll(Arrays.asList(sa.getParam("Replacements").split(","))); } // triggers to add to the animated being - final List triggers = new ArrayList<>(); + final List triggers = Lists.newArrayList(); if (sa.hasParam("Triggers")) { triggers.addAll(Arrays.asList(sa.getParam("Triggers").split(","))); } // sVars to add to the animated being - final List sVars = new ArrayList<>(); + final List sVars = Lists.newArrayList(); if (sa.hasParam("sVars")) { sVars.addAll(Arrays.asList(sa.getParam("sVars").split(","))); } + Map sVarsMap = Maps.newHashMap(); + for (final String s : sVars) { + sVarsMap.put(s, AbilityUtils.getSVar(sa, s)); + } + final String valid = sa.getParamOrDefault("ValidCards", ""); CardCollectionView list; @@ -139,9 +146,10 @@ public class AnimateAllEffect extends AnimateEffectBase { timestamp); // give sVars - for (final String s : sVars) { - c.setSVar(s, AbilityUtils.getSVar(sa, s)); + if (!sVarsMap.isEmpty() ) { + c.addChangedSVars(sVarsMap, timestamp, 0); } + game.fireEvent(new GameEventCardStatsChanged(c)); final GameCommand unanimate = new GameCommand() { diff --git a/forge-game/src/main/java/forge/game/ability/effects/AnimateEffect.java b/forge-game/src/main/java/forge/game/ability/effects/AnimateEffect.java index f2c37658ead..bc166d03de7 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/AnimateEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/AnimateEffect.java @@ -2,7 +2,9 @@ package forge.game.ability.effects; import java.util.Arrays; import java.util.List; +import java.util.Map; +import com.google.common.collect.Maps; import com.google.common.collect.Lists; import forge.card.CardType; @@ -138,11 +140,22 @@ public class AnimateEffect extends AnimateEffectBase { } // sVars to add to the animated being - final List sVars = Lists.newArrayList(); + Map sVarsMap = Maps.newHashMap(); if (sa.hasParam("sVars")) { - sVars.addAll(Arrays.asList(sa.getParam("sVars").split(","))); + for (final String s : sa.getParam("sVars").split(",")) { + String actualsVar = AbilityUtils.getSVar(sa, s); + String name = s; + if (actualsVar.startsWith("SVar:")) { + actualsVar = actualsVar.split("SVar:")[1]; + name = actualsVar.split(":")[0]; + actualsVar = actualsVar.split(":")[1]; + } + sVarsMap.put(name, actualsVar); + } } + + List tgts = getCardsfromTargets(sa); if (sa.hasParam("Optional")) { @@ -166,15 +179,8 @@ public class AnimateEffect extends AnimateEffectBase { } // give sVars - for (final String s : sVars) { - String actualsVar = AbilityUtils.getSVar(sa, s); - String name = s; - if (actualsVar.startsWith("SVar:")) { - actualsVar = actualsVar.split("SVar:")[1]; - name = actualsVar.split(":")[0]; - actualsVar = actualsVar.split(":")[1]; - } - c.setSVar(name, actualsVar); + if (!sVarsMap.isEmpty()) { + c.addChangedSVars(sVarsMap, timestamp, 0); } // give Remembered diff --git a/forge-game/src/main/java/forge/game/ability/effects/AnimateEffectBase.java b/forge-game/src/main/java/forge/game/ability/effects/AnimateEffectBase.java index 70ac1823195..6df27fae809 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/AnimateEffectBase.java +++ b/forge-game/src/main/java/forge/game/ability/effects/AnimateEffectBase.java @@ -137,6 +137,7 @@ public abstract class AnimateEffectBase extends SpellAbilityEffect { public void run() { doUnanimate(c, timestamp); + c.removeChangedSVars(timestamp, 0); c.removeChangedName(timestamp, 0); c.updateStateForView(); diff --git a/forge-game/src/main/java/forge/game/ability/effects/ControlGainEffect.java b/forge-game/src/main/java/forge/game/ability/effects/ControlGainEffect.java index 28881ebb355..a7133e10f6a 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/ControlGainEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/ControlGainEffect.java @@ -1,5 +1,9 @@ package forge.game.ability.effects; +import java.util.Arrays; +import java.util.Collections; +import java.util.List; + import com.google.common.collect.Lists; import forge.GameCommand; @@ -16,9 +20,6 @@ import forge.game.spellability.SpellAbility; import forge.game.zone.ZoneType; import forge.util.Localizer; -import java.util.Arrays; -import java.util.List; - public class ControlGainEffect extends SpellAbilityEffect { @Override @@ -210,11 +211,11 @@ public class ControlGainEffect extends SpellAbilityEffect { } if (lose.contains("EOT")) { game.getEndOfTurn().addUntil(loseControl); - tgtC.setSVar("SacMe", "6"); + tgtC.addChangedSVars(Collections.singletonMap("SacMe", "6"), tStamp, 0); } if (lose.contains("EndOfCombat")) { game.getEndOfCombat().addUntil(loseControl); - tgtC.setSVar("SacMe", "6"); + tgtC.addChangedSVars(Collections.singletonMap("SacMe", "6"), tStamp, 0); } if (lose.contains("StaticCommandCheck")) { String leftVar = sa.getSVar(sa.getParam("StaticCommandCheckSVar")); @@ -276,7 +277,7 @@ public class ControlGainEffect extends SpellAbilityEffect { @Override public void run() { doLoseControl(c, hostCard, bTapOnLose, tStamp); - c.removeSVar("SacMe"); + c.removeChangedSVars(tStamp, 0); } }; diff --git a/forge-game/src/main/java/forge/game/ability/effects/DamageDealEffect.java b/forge-game/src/main/java/forge/game/ability/effects/DamageDealEffect.java index 6591ceaeb6e..bb1d424d7f6 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/DamageDealEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/DamageDealEffect.java @@ -299,7 +299,7 @@ public class DamageDealEffect extends DamageBaseEffect { } else { damageMap.put(sourceLKI, c, dmg); if (sa.hasParam("ExcessSVar")) { - hostCard.setSVar(sa.getParam("ExcessSVar"), Integer.toString(excess)); + sa.setSVar(sa.getParam("ExcessSVar"), Integer.toString(excess)); } } } diff --git a/forge-game/src/main/java/forge/game/ability/effects/LifeLoseEffect.java b/forge-game/src/main/java/forge/game/ability/effects/LifeLoseEffect.java index fa1334fffa6..136a70e7c3f 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/LifeLoseEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/LifeLoseEffect.java @@ -2,7 +2,6 @@ package forge.game.ability.effects; import forge.game.ability.AbilityUtils; -import forge.game.ability.ApiType; import forge.game.ability.SpellAbilityEffect; import forge.game.player.Player; import forge.game.spellability.SpellAbility; @@ -41,14 +40,7 @@ public class LifeLoseEffect extends SpellAbilityEffect { lifeLost += p.loseLife(lifeAmount, false, false); } } - sa.getHostCard().setSVar("AFLifeLost", "Number$" + lifeLost); - - // Exceptional case for Extort: must propagate the amount of life lost to subability, - // otherwise the first Extort trigger per game won't work - if (sa.getSubAbility() != null && ApiType.GainLife.equals(sa.getSubAbility().getApi())) { - sa.getSubAbility().setSVar("AFLifeLost", "Number$" + lifeLost); - } - + sa.setSVar("AFLifeLost", "Number$" + lifeLost); } } diff --git a/forge-game/src/main/java/forge/game/ability/effects/PermanentEffect.java b/forge-game/src/main/java/forge/game/ability/effects/PermanentEffect.java index ddb356c4da1..e985b309554 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/PermanentEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/PermanentEffect.java @@ -1,5 +1,6 @@ package forge.game.ability.effects; +import java.util.Collections; import java.util.Map; import com.google.common.collect.Lists; @@ -42,12 +43,12 @@ public class PermanentEffect extends SpellAbilityEffect { // some extra for Dashing if (sa.isDash() && c.isInPlay()) { - c.setSVar("EndOfTurnLeavePlay", "Dash"); + c.addChangedSVars(Collections.singletonMap("EndOfTurnLeavePlay", "Dash"), c.getGame().getNextTimestamp(), 0); registerDelayedTrigger(sa, "Hand", Lists.newArrayList(c)); } // similar for Blitz keyword if (sa.isBlitz() && c.isInPlay()) { - c.setSVar("EndOfTurnLeavePlay", "Blitz"); + c.addChangedSVars(Collections.singletonMap("EndOfTurnLeavePlay", "Blitz"), c.getGame().getNextTimestamp(), 0); registerDelayedTrigger(sa, "Sacrifice", Lists.newArrayList(c)); } diff --git a/forge-game/src/main/java/forge/game/ability/effects/RollDiceEffect.java b/forge-game/src/main/java/forge/game/ability/effects/RollDiceEffect.java index 2931da09e9f..fb0a99ace99 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/RollDiceEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/RollDiceEffect.java @@ -126,13 +126,13 @@ public class RollDiceEffect extends SpellAbilityEffect { total += modifier; if (sa.hasParam("ResultSVar")) { - host.setSVar(sa.getParam("ResultSVar"), Integer.toString(total)); + sa.setSVar(sa.getParam("ResultSVar"), Integer.toString(total)); } if (sa.hasParam("ChosenSVar")) { int chosen = player.getController().chooseNumber(sa, Localizer.getInstance().getMessage("lblChooseAResult"), rolls, player); String message = Localizer.getInstance().getMessage("lblPlayerChooseValue", player, chosen); player.getGame().getAction().notifyOfValue(sa, player, message, player); - host.setSVar(sa.getParam("ChosenSVar"), Integer.toString(chosen)); + sa.setSVar(sa.getParam("ChosenSVar"), Integer.toString(chosen)); if (sa.hasParam("OtherSVar")) { int other = rolls.get(0); for (int i = 1; i < rolls.size(); ++i) { @@ -141,7 +141,7 @@ public class RollDiceEffect extends SpellAbilityEffect { break; } } - host.setSVar(sa.getParam("OtherSVar"), Integer.toString(other)); + sa.setSVar(sa.getParam("OtherSVar"), Integer.toString(other)); } } diff --git a/forge-game/src/main/java/forge/game/ability/effects/VoteEffect.java b/forge-game/src/main/java/forge/game/ability/effects/VoteEffect.java index 5ef63f3ba3b..2305418b22a 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/VoteEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/VoteEffect.java @@ -126,7 +126,7 @@ public class VoteEffect extends SpellAbilityEffect { } if (sa.hasParam("StoreVoteNum")) { for (final Object type : voteType) { - host.setSVar("VoteNum" + type, "Number$" + votes.get(type).size()); + sa.setSVar("VoteNum" + type, "Number$" + votes.get(type).size()); } } else { for (final String subAb : subAbs) { 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 4dd21525c89..927454d398e 100644 --- a/forge-game/src/main/java/forge/game/card/Card.java +++ b/forge-game/src/main/java/forge/game/card/Card.java @@ -159,6 +159,8 @@ public class Card extends GameEntity implements Comparable, IHasSVars { private final NavigableMap clonedStates = Maps.newTreeMap(); // Layer 1 + private final Table> changedSVars = TreeBasedTable.create(); + private final Map mayLook = Maps.newHashMap(); private final PlayerCollection mayLookFaceDownExile = new PlayerCollection(); private final PlayerCollection mayLookTemp = new PlayerCollection(); @@ -175,9 +177,6 @@ public class Card extends GameEntity implements Comparable, IHasSVars { private final CardChangedWords changedTextColors = new CardChangedWords(); private final CardChangedWords changedTextTypes = new CardChangedWords(); - /** Original values of SVars changed by text changes. */ - private Map originalSVars = Maps.newHashMap(); - private final Set rememberedObjects = Sets.newLinkedHashSet(); private Map flipResult; @@ -1586,10 +1585,20 @@ public class Card extends GameEntity implements Comparable, IHasSVars { } public final String getSVar(final String var) { + for (Map map : changedSVars.values()) { + if (map.containsKey(var)) { + return map.get(var); + } + } return currentState.getSVar(var); } public final boolean hasSVar(final String var) { + for (Map map : changedSVars.values()) { + if (map.containsKey(var)) { + return true; + } + } return currentState.hasSVar(var); } @@ -1615,6 +1624,13 @@ public class Card extends GameEntity implements Comparable, IHasSVars { currentState.removeSVar(var); } + public final void addChangedSVars(Map map, long timestamp, long staticId) { + this.changedSVars.put(timestamp, staticId, map); + } + public final void removeChangedSVars(long timestamp, long staticId) { + this.changedSVars.remove(timestamp, staticId); + } + public final int getTurnInZone() { return turnInZone; } @@ -4596,7 +4612,6 @@ public class Card extends GameEntity implements Comparable, IHasSVars { * Update the changed text of the intrinsic spell abilities and keywords. */ public void updateChangedText() { - resetChangedSVars(); // update type List toAdd = Lists.newArrayList(); @@ -4664,26 +4679,6 @@ public class Card extends GameEntity implements Comparable, IHasSVars { changedTextTypes.copyFrom(other.changedTextTypes); } - /** - * Change a SVar due to a text change effect. Change is volatile and will be - * reverted upon refreshing text changes (unless it is changed again at that - * time). - * - * @param key the SVar name. - * @param value the new SVar value. - */ - public final void changeSVar(final String key, final String value) { - originalSVars.put(key, getSVar(key)); - setSVar(key, value); - } - - private void resetChangedSVars() { - for (final Entry svar : originalSVars.entrySet()) { - setSVar(svar.getKey(), svar.getValue()); - } - originalSVars.clear(); - } - public final KeywordInterface addIntrinsicKeyword(final String s) { KeywordInterface inst = currentState.addIntrinsicKeyword(s, true); if (inst != null) { diff --git a/forge-game/src/main/java/forge/game/player/Player.java b/forge-game/src/main/java/forge/game/player/Player.java index 73cbf35e0db..9165616a5a2 100644 --- a/forge-game/src/main/java/forge/game/player/Player.java +++ b/forge-game/src/main/java/forge/game/player/Player.java @@ -98,6 +98,7 @@ import forge.game.keyword.KeywordsChange; import forge.game.mana.ManaPool; import forge.game.phase.PhaseHandler; import forge.game.phase.PhaseType; +import forge.game.replacement.ReplacementEffect; import forge.game.replacement.ReplacementHandler; import forge.game.replacement.ReplacementResult; import forge.game.replacement.ReplacementType; @@ -3032,7 +3033,9 @@ public class Player extends GameEntity implements Comparable { String addToHandAbility = "Mode$ Continuous | EffectZone$ Command | Affected$ Card.YouOwn+EffectSource | AffectedZone$ Command | AddAbility$ MoveToHand"; String moveToHand = "ST$ ChangeZone | Cost$ 3 | Defined$ Self | Origin$ Command | Destination$ Hand | SorcerySpeed$ True | ActivationZone$ Command | SpellDescription$ Companion - Put CARDNAME in to your hand"; - eff.setSVar("MoveToHand", moveToHand); + + StaticAbility stAb = StaticAbility.create(addToHandAbility, eff, eff.getCurrentState(), true); + stAb.setSVar("MoveToHand", moveToHand); eff.addStaticAbility(addToHandAbility); return eff; @@ -3044,11 +3047,13 @@ public class Player extends GameEntity implements Comparable { if (game.getRules().hasAppliedVariant(GameType.Oathbreaker) && commander.getRules().canBeSignatureSpell()) { //signature spells can only reside on the stack or in the command zone - eff.setSVar("SignatureSpellMoveReplacement", "DB$ ChangeZone | Origin$ Stack | Destination$ Command | Defined$ ReplacedCard"); + String effStr = "DB$ ChangeZone | Origin$ Stack | Destination$ Command | Defined$ ReplacedCard"; - String moved = "Event$ Moved | ValidCard$ Card.EffectSource+YouOwn | Secondary$ True | ReplaceWith$ SignatureSpellMoveReplacement | Destination$ Graveyard,Exile,Hand,Library | " + + String moved = "Event$ Moved | ValidCard$ Card.EffectSource+YouOwn | Secondary$ True | Destination$ Graveyard,Exile,Hand,Library | " + "Description$ If a signature spell would be put into another zone from the stack, put it into the command zone instead."; - eff.addReplacementEffect(ReplacementHandler.parseReplacement(moved, eff, true)); + ReplacementEffect re = ReplacementHandler.parseReplacement(moved, eff, true); + re.setOverridingAbility(AbilityFactory.getAbility(eff, effStr)); + eff.addReplacementEffect(re); //signature spells can only be cast if your oathbreaker is in on the battlefield under your control String castRestriction = "Mode$ CantBeCast | ValidCard$ Card.EffectSource+YouOwn | EffectZone$ Command | IsPresent$ Card.IsCommander+YouOwn+YouCtrl | PresentZone$ Battlefield | PresentCompare$ EQ0 | " + @@ -3056,9 +3061,9 @@ public class Player extends GameEntity implements Comparable { eff.addStaticAbility(castRestriction); } else { - eff.setSVar("CommanderMoveReplacement", "DB$ ChangeZone | Origin$ Battlefield,Graveyard,Exile,Library,Hand | Destination$ Command | Defined$ ReplacedCard"); + String effStr = "DB$ ChangeZone | Origin$ Battlefield,Graveyard,Exile,Library,Hand | Destination$ Command | Defined$ ReplacedCard"; - String moved = "Event$ Moved | ValidCard$ Card.EffectSource+YouOwn | Secondary$ True | Optional$ True | OptionalDecider$ You | ReplaceWith$ CommanderMoveReplacement "; + String moved = "Event$ Moved | ValidCard$ Card.EffectSource+YouOwn | Secondary$ True | Optional$ True | OptionalDecider$ You | CommanderMoveReplacement$ True "; if (game.getRules().hasAppliedVariant(GameType.TinyLeaders)) { moved += " | Destination$ Graveyard,Exile | Description$ If a commander would be put into its owner's graveyard or exile from anywhere, that player may put it into the command zone instead."; } @@ -3068,7 +3073,9 @@ public class Player extends GameEntity implements Comparable { // rule 903.9b moved += " | Destination$ Hand,Library | Description$ If a commander would be put into its owner's hand or library from anywhere, its owner may put it into the command zone instead."; } - eff.addReplacementEffect(ReplacementHandler.parseReplacement(moved, eff, true)); + ReplacementEffect re = ReplacementHandler.parseReplacement(moved, eff, true); + re.setOverridingAbility(AbilityFactory.getAbility(eff, effStr)); + eff.addReplacementEffect(re); } String mayBePlayedAbility = "Mode$ Continuous | EffectZone$ Command | MayPlay$ True | Affected$ Card.YouOwn+EffectSource | AffectedZone$ Command"; diff --git a/forge-game/src/main/java/forge/game/staticability/StaticAbilityContinuous.java b/forge-game/src/main/java/forge/game/staticability/StaticAbilityContinuous.java index 8c112ab1ab0..1a32a81b354 100644 --- a/forge-game/src/main/java/forge/game/staticability/StaticAbilityContinuous.java +++ b/forge-game/src/main/java/forge/game/staticability/StaticAbilityContinuous.java @@ -30,6 +30,7 @@ import com.google.common.base.Predicate; import com.google.common.collect.ImmutableList; import com.google.common.collect.Iterables; import com.google.common.collect.Lists; +import com.google.common.collect.Maps; import forge.GameCommand; import forge.card.CardStateName; @@ -779,6 +780,7 @@ public final class StaticAbilityContinuous { // add SVars if (addSVars != null) { + Map map = Maps.newHashMap(); for (final String sVar : addSVars) { String actualSVar = AbilityUtils.getSVar(stAb, sVar); String name = sVar; @@ -787,8 +789,9 @@ public final class StaticAbilityContinuous { name = actualSVar.split(":")[0]; actualSVar = actualSVar.split(":")[1]; } - affectedCard.setSVar(name, actualSVar); + map.put(name, actualSVar); } + affectedCard.addChangedSVars(map, se.getTimestamp(), stAb.getId()); } if (layer == StaticAbilityLayer.ABILITIES) { diff --git a/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java b/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java index 44d641d8591..e67b9483cec 100644 --- a/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java +++ b/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java @@ -52,7 +52,7 @@ import forge.util.MyRandom; import forge.util.collect.FCollectionView; import org.apache.commons.lang3.tuple.ImmutablePair; import org.apache.commons.lang3.tuple.Pair; -import org.testng.collections.Lists; +import com.google.common.collect.Lists; import java.util.Collection; import java.util.HashMap; diff --git a/forge-gui/res/cardsfolder/a/abnormal_endurance.txt b/forge-gui/res/cardsfolder/a/abnormal_endurance.txt index 369205343f0..78c15d70fa5 100644 --- a/forge-gui/res/cardsfolder/a/abnormal_endurance.txt +++ b/forge-gui/res/cardsfolder/a/abnormal_endurance.txt @@ -2,7 +2,7 @@ Name:Abnormal Endurance ManaCost:1 B Types:Instant A:SP$ Pump | Cost$ 1 B | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ +2 | SpellDescription$ Until end of turn, target creature gets +2/+0 and gains "When this creature dies, return it to the battlefield tapped under its owner's control." | SubAbility$ DBAnimate -SVar:DBAnimate:DB$ Animate | Triggers$ AbnormalEnduranceChangeZone | sVars$ AbnormalEnduranceTrigChangeZone | Defined$ ParentTarget +SVar:DBAnimate:DB$ Animate | Triggers$ AbnormalEnduranceChangeZone | Defined$ ParentTarget SVar:AbnormalEnduranceChangeZone:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ AbnormalEnduranceTrigChangeZone | TriggerController$ TriggeredCardController | TriggerDescription$ When this creature dies, return it to the battlefield tapped under its owner's control. SVar:AbnormalEnduranceTrigChangeZone:DB$ ChangeZone | Origin$ Graveyard | Destination$ Battlefield | Tapped$ True | Defined$ TriggeredNewCardLKICopy Oracle:Until end of turn, target creature gets +2/+0 and gains "When this creature dies, return it to the battlefield tapped under its owner's control." diff --git a/forge-gui/res/cardsfolder/a/aethermages_touch.txt b/forge-gui/res/cardsfolder/a/aethermages_touch.txt index 34ed3b01913..40e27282291 100644 --- a/forge-gui/res/cardsfolder/a/aethermages_touch.txt +++ b/forge-gui/res/cardsfolder/a/aethermages_touch.txt @@ -2,7 +2,7 @@ Name:Aethermage's Touch ManaCost:2 W U Types:Instant A:SP$ Dig | Cost$ 2 W U | DigNum$ 4 | Reveal$ True | ChangeNum$ 1 | Optional$ True | ChangeValid$ Creature | DestinationZone$ Battlefield | RememberChanged$ True | SubAbility$ DBAnimate | SpellDescription$ Reveal the top four cards of your library. You may put a creature card from among them onto the battlefield. It gains "At the beginning of your end step, return this creature to its owner's hand." Then put the rest of the cards revealed this way on the bottom of your library in any order. | StackDescription$ SpellDescription -SVar:DBAnimate:DB$ Animate | Defined$ Remembered | Duration$ Permanent | Triggers$ TrigAethermage | sVars$ BounceAethermage | SubAbility$ DBCleanup | StackDescription$ None +SVar:DBAnimate:DB$ Animate | Defined$ Remembered | Duration$ Permanent | Triggers$ TrigAethermage | SubAbility$ DBCleanup | StackDescription$ None SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True SVar:TrigAethermage:Mode$ Phase | Phase$ End of Turn | TriggerZones$ Battlefield | ValidPlayer$ You | Execute$ BounceAethermage | TriggerDescription$ At the beginning of your end step, return CARDNAME to its owner's hand. SVar:BounceAethermage:DB$ ChangeZone | Defined$ Self | Origin$ Battlefield | Destination$ Hand diff --git a/forge-gui/res/cardsfolder/a/arm_with_aether.txt b/forge-gui/res/cardsfolder/a/arm_with_aether.txt index 831d42bc32f..f1b73ae2bb9 100644 --- a/forge-gui/res/cardsfolder/a/arm_with_aether.txt +++ b/forge-gui/res/cardsfolder/a/arm_with_aether.txt @@ -1,7 +1,7 @@ Name:Arm with Aether ManaCost:2 U Types:Sorcery -A:SP$ AnimateAll | Cost$ 2 U | ValidCards$ Creature.YouCtrl | Triggers$ Trig | sVars$ Eff | SpellDescription$ Until end of turn, creatures you control gain "Whenever this creature deals damage to an opponent, you may return target creature that player controls to its owner's hand." +A:SP$ AnimateAll | Cost$ 2 U | ValidCards$ Creature.YouCtrl | Triggers$ Trig | SpellDescription$ Until end of turn, creatures you control gain "Whenever this creature deals damage to an opponent, you may return target creature that player controls to its owner's hand." SVar:Trig:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Opponent | OptionalDecider$ You | Execute$ Eff | TriggerDescription$ Whenever this creature deals damage to an opponent, you may return target creature that player controls to its owner's hand. SVar:Eff:DB$ ChangeZone | ValidTgts$ Creature | TargetsWithDefinedController$ TriggeredTarget | TgtPrompt$ Select target creature that player controls. | Origin$ Battlefield | Destination$ Hand Oracle:Until end of turn, creatures you control gain "Whenever this creature deals damage to an opponent, you may return target creature that player controls to its owner's hand." diff --git a/forge-gui/res/cardsfolder/b/brawl.txt b/forge-gui/res/cardsfolder/b/brawl.txt index b3307e6301e..bca9e3a2c2b 100644 --- a/forge-gui/res/cardsfolder/b/brawl.txt +++ b/forge-gui/res/cardsfolder/b/brawl.txt @@ -1,7 +1,7 @@ Name:Brawl ManaCost:3 R R Types:Instant -A:SP$ AnimateAll | Cost$ 3 R R | ValidCards$ Creature | Abilities$ ThrowPunch | sVars$ BrawlX | SpellDescription$ Until end of turn, all creatures gain "{T}: This creature deals damage equal to its power to target creature." +A:SP$ AnimateAll | Cost$ 3 R R | ValidCards$ Creature | Abilities$ ThrowPunch | SpellDescription$ Until end of turn, all creatures gain "{T}: This creature deals damage equal to its power to target creature." SVar:ThrowPunch:AB$ DealDamage | Cost$ T | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumDmg$ BrawlX | SpellDescription$ This creature deals damage equal to its power to target creature. SVar:BrawlX:Count$CardPower AI:RemoveDeck:All diff --git a/forge-gui/res/cardsfolder/c/cherished_hatchling.txt b/forge-gui/res/cardsfolder/c/cherished_hatchling.txt index cabbd4e336f..81cea1e9301 100644 --- a/forge-gui/res/cardsfolder/c/cherished_hatchling.txt +++ b/forge-gui/res/cardsfolder/c/cherished_hatchling.txt @@ -6,7 +6,7 @@ T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ SVar:TrigEffect:DB$ Effect | Name$ Cherished Hatchling Effect | StaticAbilities$ STFlash | Triggers$ HatchlingCast SVar:STFlash:Mode$ CastWithFlash | ValidCard$ Dinosaur | ValidSA$ Spell | EffectZone$ Command | Caster$ You | Description$ You may cast Dinosaur spells this turn as though they had flash. SVar:HatchlingCast:Mode$ SpellCast | ValidCard$ Dinosaur | ValidActivatingPlayer$ You | Execute$ TrigHatchlingAnimate | TriggerZones$ Command | TriggerDescription$ Whenever you cast a Dinosaur spell this turn, it gains "When this creature enters the battlefield, you may have it fight another target creature." -SVar:TrigHatchlingAnimate:DB$ Animate | Defined$ TriggeredCard | Duration$ Permanent | Triggers$ TrigETBHatchling | sVars$ HatchlingFight +SVar:TrigHatchlingAnimate:DB$ Animate | Defined$ TriggeredCard | Duration$ Permanent | Triggers$ TrigETBHatchling SVar:TrigETBHatchling:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ HatchlingFight | OptionalDecider$ You | TriggerDescription$ When this creature enters the battlefield, you may have it fight another target creature. SVar:HatchlingFight:DB$ Fight | Defined$ TriggeredCardLKICopy | ValidTgts$ Creature.Other | TgtPrompt$ Select another target creature DeckHints:Type$Dinosaur diff --git a/forge-gui/res/cardsfolder/c/commando_raid.txt b/forge-gui/res/cardsfolder/c/commando_raid.txt index 89496c5a5b6..72252541fe3 100644 --- a/forge-gui/res/cardsfolder/c/commando_raid.txt +++ b/forge-gui/res/cardsfolder/c/commando_raid.txt @@ -1,7 +1,7 @@ Name:Commando Raid ManaCost:2 R Types:Instant -A:SP$ Animate | Cost$ 2 R | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select target creature you control | Triggers$ TrigDamage | sVars$ Damage,CommandoRaidX | SpellDescription$ Until end of turn, target creature you control gains "When this creature deals combat damage to a player, you may have it deal damage equal to its power to target creature that player controls." +A:SP$ Animate | Cost$ 2 R | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select target creature you control | Triggers$ TrigDamage | SpellDescription$ Until end of turn, target creature you control gains "When this creature deals combat damage to a player, you may have it deal damage equal to its power to target creature that player controls." SVar:TrigDamage:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | CombatDamage$ True | Execute$ Damage | OptionalDecider$ You | TriggerDescription$ When this creature deals combat damage to a player, you may have it deal damage equal to its power to target creature that player controls. SVar:Damage:DB$ DealDamage | ValidTgts$ Creature.ControlledBy TriggeredDefendingPlayer | TgtPrompt$ Select target creature defending player controls | NumDmg$ CommandoRaidX SVar:CommandoRaidX:Count$CardPower diff --git a/forge-gui/res/cardsfolder/c/cosima_god_of_the_voyage_the_omenkeel.txt b/forge-gui/res/cardsfolder/c/cosima_god_of_the_voyage_the_omenkeel.txt index c1f7c178abc..dddde364c2e 100644 --- a/forge-gui/res/cardsfolder/c/cosima_god_of_the_voyage_the_omenkeel.txt +++ b/forge-gui/res/cardsfolder/c/cosima_god_of_the_voyage_the_omenkeel.txt @@ -4,7 +4,7 @@ Types:Legendary Creature God PT:2/4 T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | Execute$ TrigExile | TriggerZones$ Battlefield | OptionalDecider$ You | TriggerDescription$ At the beginning of your upkeep, you may exile NICKNAME. If you do, it gains "Whenever a land enters the battlefield under your control, if Cosima is exiled, you may put a voyage counter on it. If you don't, return Cosima to the battlefield with X +1/+1 counters on it and draw X cards, where X is the number of voyage counters on it." SVar:TrigExile:DB$ ChangeZone | Origin$ Battlefield | Destination$ Exile | RememberChanged$ True | SubAbility$ DBAnimate -SVar:DBAnimate:DB$ Animate | Defined$ Remembered | Triggers$ LandEnter | Duration$ Permanent | sVars$ TrigReturn,DBDraw,X | SubAbility$ DBCleanup +SVar:DBAnimate:DB$ Animate | Defined$ Remembered | Triggers$ LandEnter | Duration$ Permanent | SubAbility$ DBCleanup SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True SVar:LandEnter:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | TriggerZones$ Exile | ValidCard$ Land.YouCtrl | Execute$ TrigAddCounter | TriggerDescription$ Whenever a land enters the battlefield under your control, if NICKNAME is exiled, you may put a voyage counter on it. If you don't, return NICKNAME to the battlefield with X +1/+1 counters on it and draw X cards, where X is the number of voyage counters on it. SVar:TrigAddCounter:DB$ PutCounter | Optional$ True | Defined$ Self | CounterType$ VOYAGE | CounterNum$ 1 | RememberAmount$ True | SubAbility$ DBReturn diff --git a/forge-gui/res/cardsfolder/c/cruel_deceiver.txt b/forge-gui/res/cardsfolder/c/cruel_deceiver.txt index f49bee0b38f..290a98c91ca 100644 --- a/forge-gui/res/cardsfolder/c/cruel_deceiver.txt +++ b/forge-gui/res/cardsfolder/c/cruel_deceiver.txt @@ -4,7 +4,7 @@ Types:Creature Spirit PT:2/1 A:AB$ PeekAndReveal | Cost$ 1 | NoReveal$ True | SpellDescription$ Look at the top card of your library. A:AB$ PeekAndReveal | Cost$ 2 | ActivationLimit$ 1 | NoPeek$ True | RememberRevealed$ True | SubAbility$ DBAnimate | SpellDescription$ Reveal the top card of your library. -SVar:DBAnimate:DB$ Animate | Defined$ Self | Triggers$ TrigDamage | sVars$ TrigDestroy | ConditionDefined$ Remembered | ConditionPresent$ Card.Land | SubAbility$ DBCleanup | StackDescription$ SpellDescription | SpellDescription$ If it's a land card, CARDNAME gains "Whenever CARDNAME deals damage to a creature, destroy that creature" until end of turn. +SVar:DBAnimate:DB$ Animate | Defined$ Self | Triggers$ TrigDamage | ConditionDefined$ Remembered | ConditionPresent$ Card.Land | SubAbility$ DBCleanup | StackDescription$ SpellDescription | SpellDescription$ If it's a land card, CARDNAME gains "Whenever CARDNAME deals damage to a creature, destroy that creature" until end of turn. SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True | StackDescription$ None | SpellDescription$ Activate only once each turn. SVar:TrigDamage:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Creature | TriggerZones$ Battlefield | Execute$ TrigDestroy | TriggerDescription$ Whenever CARDNAME deals damage to a creature, destroy that creature. SVar:TrigDestroy:DB$ Destroy | Defined$ TriggeredTargetLKICopy diff --git a/forge-gui/res/cardsfolder/d/demonic_gifts.txt b/forge-gui/res/cardsfolder/d/demonic_gifts.txt index 960d0d43aa1..c7c213ae913 100644 --- a/forge-gui/res/cardsfolder/d/demonic_gifts.txt +++ b/forge-gui/res/cardsfolder/d/demonic_gifts.txt @@ -2,7 +2,7 @@ Name:Demonic Gifts ManaCost:1 B Types:Instant A:SP$ Pump | Cost$ 1 B | ValidTgts$ Creature | TgtPrompt$ Choose target creature | NumAtt$ +2 | SubAbility$ DBAnimate | SpellDescription$ Until end of turn, target creature gets +2/+0 and gains "When this creature dies, return it to the battlefield under its owner's control." | StackDescription$ Spelldescription -SVar:DBAnimate:DB$ Animate | Triggers$ TrigDies | sVars$ TrigReturn | Defined$ ParentTarget | StackDescription$ None +SVar:DBAnimate:DB$ Animate | Triggers$ TrigDies | Defined$ ParentTarget | StackDescription$ None SVar:TrigDies:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Graveyard | Execute$ TrigReturn | TriggerDescription$ When CARDNAME dies, return it to the battlefield under its owner's control. SVar:TrigReturn:DB$ ChangeZone | DB$ ChangeZone | Defined$ TriggeredNewCardLKICopy | Origin$ Graveyard | Destination$ Battlefield Oracle:Until end of turn, target creature gets +2/+0 and gains "When this creature dies, return it to the battlefield under its owner's control." diff --git a/forge-gui/res/cardsfolder/d/driven_despair.txt b/forge-gui/res/cardsfolder/d/driven_despair.txt index dcadc2919fc..315a702bf61 100644 --- a/forge-gui/res/cardsfolder/d/driven_despair.txt +++ b/forge-gui/res/cardsfolder/d/driven_despair.txt @@ -1,7 +1,7 @@ Name:Driven ManaCost:1 G Types:Sorcery -A:SP$ AnimateAll | Cost$ 1 G | ValidCards$ Creature.YouCtrl | Keywords$ Trample | Triggers$ Trig1 | sVars$ Eff1 | StackDescription$ SpellDescription | SpellDescription$ Until end of turn, creatures you control gain trample and "Whenever this creature deals combat damage to a player, draw a card." +A:SP$ AnimateAll | Cost$ 1 G | ValidCards$ Creature.YouCtrl | Keywords$ Trample | Triggers$ Trig1 | StackDescription$ SpellDescription | SpellDescription$ Until end of turn, creatures you control gain trample and "Whenever this creature deals combat damage to a player, draw a card." SVar:Trig1:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | Execute$ Eff1 | CombatDamage$ True | TriggerDescription$ Whenever this creature deals combat damage to a player, draw a card. SVar:Eff1:DB$ Draw | NumCards$ 1 AlternateMode:Split @@ -13,7 +13,7 @@ Name:Despair ManaCost:1 B Types:Sorcery K:Aftermath -A:SP$ AnimateAll | Cost$ 1 B | ValidCards$ Creature.YouCtrl | Keywords$ Menace | Triggers$ Trig2 | sVars$ Eff2 | StackDescription$ SpellDescription | SpellDescription$ Until end of turn, creatures you control gain menace and "Whenever this creature deals combat damage to a player, that player discards a card." +A:SP$ AnimateAll | Cost$ 1 B | ValidCards$ Creature.YouCtrl | Keywords$ Menace | Triggers$ Trig2 | StackDescription$ SpellDescription | SpellDescription$ Until end of turn, creatures you control gain menace and "Whenever this creature deals combat damage to a player, that player discards a card." SVar:Trig2:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | Execute$ Eff2 | CombatDamage$ True | TriggerDescription$ Whenever this creature deals combat damage to a player, that player discards a card. SVar:Eff2:DB$ Discard | Defined$ TriggeredTarget | NumCards$ 1 | Mode$ TgtChoose Oracle:Aftermath (Cast this spell only from your graveyard. Then exile it.)\nUntil end of turn, creatures you control gain menace and "Whenever this creature deals combat damage to a player, that player discards a card." diff --git a/forge-gui/res/cardsfolder/f/flash_conscription.txt b/forge-gui/res/cardsfolder/f/flash_conscription.txt index a136f6a19a9..2123790c872 100644 --- a/forge-gui/res/cardsfolder/f/flash_conscription.txt +++ b/forge-gui/res/cardsfolder/f/flash_conscription.txt @@ -2,7 +2,7 @@ Name:Flash Conscription ManaCost:5 R Types:Instant A:SP$ GainControl | Cost$ 5 R | ValidTgts$ Creature | TgtPrompt$ Select target creature | AddKWs$ Haste | LoseControl$ EOT | Untap$ True | SubAbility$ DBAnimate | SpellDescription$ Untap target creature and gain control of it until end of turn. That creature gains haste until end of turn. If {W} was spent to cast this spell, the creature gains "Whenever this creature deals combat damage, you gain that much life" until end of turn. -SVar:DBAnimate:DB$ Animate | Defined$ Targeted | Triggers$ TrigDamage | sVars$ GainLife,X | ConditionManaSpent$ W +SVar:DBAnimate:DB$ Animate | Defined$ Targeted | Triggers$ TrigDamage | ConditionManaSpent$ W SVar:TrigDamage:Mode$ DamageDealtOnce | CombatDamage$ True | ValidSource$ Card.Self | Execute$ GainLife | TriggerZones$ Battlefield | TriggerDescription$ Whenever this creature deals combat damage, you gain that much life. SVar:GainLife:DB$ GainLife | LifeAmount$ X SVar:X:TriggerCount$DamageAmount diff --git a/forge-gui/res/cardsfolder/g/genju_of_the_fields.txt b/forge-gui/res/cardsfolder/g/genju_of_the_fields.txt index eef60aac1c5..a5f0e89940f 100644 --- a/forge-gui/res/cardsfolder/g/genju_of_the_fields.txt +++ b/forge-gui/res/cardsfolder/g/genju_of_the_fields.txt @@ -3,7 +3,7 @@ ManaCost:W Types:Enchantment Aura K:Enchant Plains A:SP$ Attach | Cost$ W | ValidTgts$ Plains | AILogic$ Pump -A:AB$ Animate | Cost$ 2 | Defined$ Enchanted | Power$ 2 | Toughness$ 5 | Types$ Creature,Spirit | Colors$ White | Triggers$ PseudoLifelink | sVars$ GenjuTrigGain,GenjuX | SpellDescription$ Until end of turn, enchanted Plains becomes a 2/5 white Spirit creature with "Whenever this creature deals damage, its controller gains that much life." It's still a land. +A:AB$ Animate | Cost$ 2 | Defined$ Enchanted | Power$ 2 | Toughness$ 5 | Types$ Creature,Spirit | Colors$ White | Triggers$ PseudoLifelink | SpellDescription$ Until end of turn, enchanted Plains becomes a 2/5 white Spirit creature with "Whenever this creature deals damage, its controller gains that much life." It's still a land. T:Mode$ ChangesZone | ValidCard$ Card.AttachedBy | Origin$ Battlefield | Destination$ Graveyard | TriggerZones$ Battlefield | Execute$ TrigReturnOwner | OptionalDecider$ You | TriggerDescription$ When enchanted Plains is put into a graveyard, you may return CARDNAME from your graveyard to your hand. SVar:TrigReturnOwner:DB$ ChangeZone | Defined$ Self | Origin$ Graveyard | Destination$ Hand SVar:PseudoLifelink:Mode$ DamageDealtOnce | ValidSource$ Card.Self | Execute$ GenjuTrigGain | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME deals damage, you gain that much life. diff --git a/forge-gui/res/cardsfolder/g/glyph_of_delusion.txt b/forge-gui/res/cardsfolder/g/glyph_of_delusion.txt index fa50238cd5b..be7577bfaac 100644 --- a/forge-gui/res/cardsfolder/g/glyph_of_delusion.txt +++ b/forge-gui/res/cardsfolder/g/glyph_of_delusion.txt @@ -4,7 +4,7 @@ Types:Instant A:SP$ Pump | Cost$ U | ValidTgts$ Wall.blockedThisTurn | TgtPrompt$ Select target Wall that blocked this turn | SubAbility$ DBPutCounter | StackDescription$ SpellDescription | SpellDescription$ Put X glyph counters on target creature that target Wall blocked this turn, where X is the power of that blocked creature. The creature gains "This creature doesn't untap during your untap step if it has a glyph counter on it" and "At the beginning of your upkeep, remove a glyph counter from this creature." SVar:DBPutCounter:DB$ PutCounter | CounterType$ GLYPH | CounterNum$ X | ValidTgts$ Creature.blockedByValidThisTurn ParentTarget | TgtPrompt$ Select target creature blocked by target Wall this turn to put counters on | SubAbility$ Delude | IsCurse$ True SVar:X:Targeted$CardPower -SVar:Delude:DB$ Animate | Defined$ ParentTarget | staticAbilities$ Delusional | Triggers$ TrigGlyphUpkeep | sVars$ LoseGlyph | Duration$ Permanent | StackDescription$ None +SVar:Delude:DB$ Animate | Defined$ ParentTarget | staticAbilities$ Delusional | Triggers$ TrigGlyphUpkeep | Duration$ Permanent | StackDescription$ None SVar:Delusional:Mode$ Continuous | Affected$ Card.Self+counters_GE1_GLYPH | AddHiddenKeyword$ CARDNAME doesn't untap during your untap step. | Description$ CARDNAME doesn't untap during your untap step if it has a glyph counter on it. SVar:TrigGlyphUpkeep:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ LoseGlyph | TriggerDescription$ At the beginning of your upkeep, remove a glyph counter from CARDNAME. SVar:LoseGlyph:DB$ RemoveCounter | CounterType$ GLYPH | CounterNum$ 1 diff --git a/forge-gui/res/cardsfolder/g/gruesome_slaughter.txt b/forge-gui/res/cardsfolder/g/gruesome_slaughter.txt index e35e236d82d..c3a8e0455ea 100644 --- a/forge-gui/res/cardsfolder/g/gruesome_slaughter.txt +++ b/forge-gui/res/cardsfolder/g/gruesome_slaughter.txt @@ -1,7 +1,7 @@ Name:Gruesome Slaughter ManaCost:6 Types:Sorcery -A:SP$ AnimateAll | Cost$ 6 | ValidCards$ Creature.Colorless+YouCtrl | Abilities$ ThrowPunch | sVars$ GruesomeX | SpellDescription$ Until end of turn, colorless creatures you control gain "{T}: This creature deals damage equal to its power to target creature." +A:SP$ AnimateAll | Cost$ 6 | ValidCards$ Creature.Colorless+YouCtrl | Abilities$ ThrowPunch | SpellDescription$ Until end of turn, colorless creatures you control gain "{T}: This creature deals damage equal to its power to target creature." SVar:ThrowPunch:AB$ DealDamage | Cost$ T | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumDmg$ GruesomeX | SpellDescription$ This creature deals damage equal to its power to target creature. SVar:GruesomeX:Count$CardPower AI:RemoveDeck:Random diff --git a/forge-gui/res/cardsfolder/h/hunters_prowess.txt b/forge-gui/res/cardsfolder/h/hunters_prowess.txt index 28e7bca469b..b78b935ad28 100644 --- a/forge-gui/res/cardsfolder/h/hunters_prowess.txt +++ b/forge-gui/res/cardsfolder/h/hunters_prowess.txt @@ -2,7 +2,7 @@ Name:Hunter's Prowess ManaCost:4 G Types:Sorcery A:SP$ Pump | Cost$ 4 G | ValidTgts$ Creature | NumAtt$ 3 | NumDef$ 3 | KW$ Trample | SubAbility$ DBAnimate | SpellDescription$ Until end of turn, target creature gets +3/+3 and gains trample and "Whenever this creature deals combat damage to a player, draw that many cards." | StackDescription$ SpellDescription -SVar:DBAnimate:DB$ Animate | Defined$ ParentTarget | Triggers$ HunterProwessTrig | sVars$ HunterProwessX,HunterProwessY | StackDescription$ None +SVar:DBAnimate:DB$ Animate | Defined$ ParentTarget | Triggers$ HunterProwessTrig | StackDescription$ None SVar:HunterProwessTrig:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | CombatDamage$ True | Execute$ HunterProwessX | TriggerDescription$ Whenever CARDNAME deals combat damage to a player, draw that many cards. SVar:HunterProwessX:DB$ Draw | Defined$ You | NumCards$ HunterProwessY SVar:HunterProwessY:TriggerCount$DamageAmount diff --git a/forge-gui/res/cardsfolder/l/launch_the_fleet.txt b/forge-gui/res/cardsfolder/l/launch_the_fleet.txt index 280d10ddf90..ab1045278a7 100644 --- a/forge-gui/res/cardsfolder/l/launch_the_fleet.txt +++ b/forge-gui/res/cardsfolder/l/launch_the_fleet.txt @@ -2,7 +2,7 @@ Name:Launch the Fleet ManaCost:W Types:Sorcery K:Strive:1 -A:SP$ Animate | Cost$ W | TargetMin$ 0 | TargetMax$ MaxTargets | AILogic$ Attacking | ValidTgts$ Creature | Triggers$ AttackTrigger | sVars$ LaunchTokenAttacking | SpellDescription$ Until end of turn, any number of target creatures each gain "Whenever this creature attacks, create a 1/1 white Soldier creature token that's tapped and attacking." +A:SP$ Animate | Cost$ W | TargetMin$ 0 | TargetMax$ MaxTargets | AILogic$ Attacking | ValidTgts$ Creature | Triggers$ AttackTrigger | SpellDescription$ Until end of turn, any number of target creatures each gain "Whenever this creature attacks, create a 1/1 white Soldier creature token that's tapped and attacking." SVar:AttackTrigger:Mode$ Attacks | ValidCard$ Card.Self | Execute$ LaunchTokenAttacking | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME attacks, create a 1/1 white Soldier creature token that's tapped and attacking. SVar:LaunchTokenAttacking:DB$ Token | TokenAmount$ 1 | TokenScript$ w_1_1_soldier | TokenOwner$ You | TokenAttacking$ True | TokenTapped$ True SVar:MaxTargets:Count$Valid Creature diff --git a/forge-gui/res/cardsfolder/m/malakir_rebirth_malakir_mire.txt b/forge-gui/res/cardsfolder/m/malakir_rebirth_malakir_mire.txt index 906201dae88..4ede1408b67 100644 --- a/forge-gui/res/cardsfolder/m/malakir_rebirth_malakir_mire.txt +++ b/forge-gui/res/cardsfolder/m/malakir_rebirth_malakir_mire.txt @@ -2,7 +2,7 @@ Name:Malakir Rebirth ManaCost:B Types:Instant A:SP$ LoseLife | Cost$ B | Defined$ You | LifeAmount$ 2 | SubAbility$ DBAnimate | SpellDescription$ Choose target creature. You lose 2 life. Until end of turn, that creature gains "When this creature dies, return it to the battlefield tapped under its owner's control." -SVar:DBAnimate:DB$ Animate | ValidTgts$ Creature | TgtPrompt$ Choose target creature | Triggers$ TrigDies | sVars$ TrigReturn | StackDescription$ Until end of turn, {c:Targeted} gains "When this creature dies, return it to the battlefield tapped under its owner's control." +SVar:DBAnimate:DB$ Animate | ValidTgts$ Creature | TgtPrompt$ Choose target creature | Triggers$ TrigDies | StackDescription$ Until end of turn, {c:Targeted} gains "When this creature dies, return it to the battlefield tapped under its owner's control." SVar:TrigDies:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Graveyard | Execute$ TrigReturn | TriggerDescription$ When CARDNAME dies, return it to the battlefield tapped under its owner's control. SVar:TrigReturn:DB$ ChangeZone | DB$ ChangeZone | Defined$ TriggeredNewCardLKICopy | Origin$ Graveyard | Destination$ Battlefield | Tapped$ True AlternateMode:Modal diff --git a/forge-gui/res/cardsfolder/m/martyrdom.txt b/forge-gui/res/cardsfolder/m/martyrdom.txt index 7c86d17580e..7e3542d529e 100644 --- a/forge-gui/res/cardsfolder/m/martyrdom.txt +++ b/forge-gui/res/cardsfolder/m/martyrdom.txt @@ -1,7 +1,7 @@ Name:Martyrdom ManaCost:1 W W Types:Instant -A:SP$ Animate | Cost$ 1 W W | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select target creature you control | Abilities$ Martyr | sVars$ DamageEvent,DamageEventDmg,IsCreature | StackDescription$ Until end of turn, {c:Targeted} gains "{0}: The next 1 damage that would be dealt to target creature, planeswalker, or player this turn is dealt to this creature instead." | SpellDescription$ Until end of turn, target creature you control gains "{0}: The next 1 damage that would be dealt to target creature, planeswalker, or player this turn is dealt to this creature instead." Only you may activate this ability. +A:SP$ Animate | Cost$ 1 W W | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select target creature you control | Abilities$ Martyr | StackDescription$ Until end of turn, {c:Targeted} gains "{0}: The next 1 damage that would be dealt to target creature, planeswalker, or player this turn is dealt to this creature instead." | SpellDescription$ Until end of turn, target creature you control gains "{0}: The next 1 damage that would be dealt to target creature, planeswalker, or player this turn is dealt to this creature instead." Only you may activate this ability. SVar:Martyr:AB$ Effect | Name$ Martyrdom Effect | Cost$ 0 | Activator$ Player.IsRemembered | ValidTgts$ Creature,Player,Planeswalker | TgtPrompt$ Select any target to redirect damage from | Amount$ 1 | ReplacementEffects$ DamageEvent | Duration$ UntilHostLeavesPlayOrEOT | RememberObjects$ You,Targeted | ImprintCards$ Self | ExileOnMoved$ Battlefield | StackDescription$ The next 1 damage that would be dealt to {c:Targeted}{p:Targeted} this turn is dealt to {c:Self} instead. | SpellDescription$ The next 1 damage that would be dealt to target creature, planeswalker, or player this turn is dealt to CARDNAME instead. SVar:DamageEvent:Event$ DamageDone | IsPresent$ Card.IsImprinted+Creature | ValidTarget$ Player.IsRemembered,Card.IsRemembered | ReplaceWith$ DamageEventDmg | DamageTarget$ Imprinted | Description$ The next 1 damage that would be dealt to this target this turn is dealt to EFFECTSOURCE instead. SVar:DamageEventDmg:DB$ ReplaceSplitDamage | DamageTarget$ Imprinted diff --git a/forge-gui/res/cardsfolder/m/mindbender_spores.txt b/forge-gui/res/cardsfolder/m/mindbender_spores.txt index 72156e7329f..988909535f4 100644 --- a/forge-gui/res/cardsfolder/m/mindbender_spores.txt +++ b/forge-gui/res/cardsfolder/m/mindbender_spores.txt @@ -6,7 +6,7 @@ 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$ TriggeredAttackerLKICopy | SubAbility$ AddFungalEffects -SVar:AddFungalEffects:DB$ Animate | Defined$ TriggeredAttacker | staticAbilities$ FungalFunk | Triggers$ TrigSporeUpkeep | sVars$ LoseSpores | Duration$ Permanent +SVar:AddFungalEffects:DB$ Animate | Defined$ TriggeredAttacker | staticAbilities$ FungalFunk | Triggers$ TrigSporeUpkeep | Duration$ Permanent 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. SVar:LoseSpores:DB$ RemoveCounter | CounterType$ FUNGUS | CounterNum$ 1 diff --git a/forge-gui/res/cardsfolder/m/musician.txt b/forge-gui/res/cardsfolder/m/musician.txt index b7f5d2b55d1..4640fdc1bbc 100644 --- a/forge-gui/res/cardsfolder/m/musician.txt +++ b/forge-gui/res/cardsfolder/m/musician.txt @@ -4,7 +4,7 @@ Types:Creature Human Wizard PT:1/3 K:Cumulative upkeep:1 A:AB$ PutCounter | Cost$ T | ValidTgts$ Creature | TgtPrompt$ Select target creature | IsCurse$ True | CounterType$ MUSIC | CounterNum$ 1 | SubAbility$ PayThePiper | SpellDescription$ Put a music counter on target creature. If it doesn't have "At the beginning of your upkeep, destroy this creature unless you pay {1} for each music counter on it," it gains that ability. -SVar:PayThePiper:DB$ Animate | Defined$ Targeted | Duration$ Permanent | Keywords$ At the beginning of your upkeep, destroy this creature unless you pay {1} for each music counter on it | Triggers$ TrigMusicianPay | sVars$ MusiciansSpite,MusicX | ConditionDefined$ Targeted | ConditionPresent$ Card.withoutAt the beginning of your upkeep, destroy this creature unless you pay {1} for each music counter on it | ConditionCompare$ GE1 +SVar:PayThePiper:DB$ Animate | Defined$ Targeted | Duration$ Permanent | Keywords$ At the beginning of your upkeep, destroy this creature unless you pay {1} for each music counter on it | Triggers$ TrigMusicianPay | ConditionDefined$ Targeted | ConditionPresent$ Card.withoutAt the beginning of your upkeep, destroy this creature unless you pay {1} for each music counter on it | ConditionCompare$ GE1 #The keyword added does nothing itself other than create a keyword string to check against in the conditional SVar:TrigMusicianPay:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ MusiciansSpite | Secondary$ True | TriggerDescription$ At the beginning of your upkeep, destroy this creature unless you pay 1 for each music counter on it. SVar:MusiciansSpite:DB$ Destroy | Defined$ Self | UnlessCost$ MusicX | UnlessPayer$ You diff --git a/forge-gui/res/cardsfolder/n/necravolver.txt b/forge-gui/res/cardsfolder/n/necravolver.txt index b4640161e02..17552bec7c1 100644 --- a/forge-gui/res/cardsfolder/n/necravolver.txt +++ b/forge-gui/res/cardsfolder/n/necravolver.txt @@ -8,7 +8,7 @@ K:ETBReplacement:Other:VolverPumped:Mandatory::Card.Self+kicked 2 SVar:VolverStrength:DB$ PutCounter | Defined$ Self | CounterType$ P1P1 | CounterNum$ 2 | ETB$ True | SubAbility$ VolverStomp | SpellDescription$ If CARDNAME was kicked with its {1}{G} kicker, it enters the battlefield with two +1/+1 counters on it and with trample. SVar:VolverStomp:DB$ Animate | Defined$ Self | Keywords$ Trample | Duration$ Permanent SVar:VolverPumped:DB$ PutCounter | Defined$ Self | CounterType$ P1P1 | CounterNum$ 1 | ETB$ True | SubAbility$ VolverLife | SpellDescription$ If CARDNAME was kicked with its {W} kicker, it enters the battlefield with a +1/+1 counter on it and with "Whenever CARDNAME deals damage, you gain that much life." -SVar:VolverLife:DB$ Animate | Defined$ Self | Triggers$ PseudoLifelink | sVars$ VolverTrigGain,VolverX | Duration$ Permanent +SVar:VolverLife:DB$ Animate | Defined$ Self | Triggers$ PseudoLifelink | Duration$ Permanent SVar:PseudoLifelink:Mode$ DamageDealtOnce | ValidSource$ Card.Self | Execute$ VolverTrigGain | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME deals damage, you gain that much life. SVar:VolverTrigGain:DB$ GainLife | Defined$ You | LifeAmount$ VolverX SVar:VolverX:TriggerCount$DamageAmount diff --git a/forge-gui/res/cardsfolder/n/nimble_trapfinder.txt b/forge-gui/res/cardsfolder/n/nimble_trapfinder.txt index 383c5b2b219..da333a1829f 100644 --- a/forge-gui/res/cardsfolder/n/nimble_trapfinder.txt +++ b/forge-gui/res/cardsfolder/n/nimble_trapfinder.txt @@ -5,7 +5,7 @@ PT:2/1 S:Mode$ Continuous | Affected$ Card.Self | AddHiddenKeyword$ Unblockable | CheckSVar$ JoinedParty | SVarCompare$ GE1 | Description$ CARDNAME can't be blocked if you had another Cleric, Rogue, Warrior, or Wizard enter the battlefield under your control this turn. SVar:JoinedParty:Count$ThisTurnEntered_Battlefield_Cleric.YouCtrl+Other,Rogue.YouCtrl+Other,Warrior.YouCtrl+Other,Wizard.YouCtrl+Other T:Mode$ Phase | Phase$ BeginCombat | ValidPlayer$ You | TriggerZones$ Battlefield | CheckSVar$ X | SVarCompare$ EQ4 | Execute$ TrigAnimateAll | TriggerDescription$ At the beginning of combat on your turn, if you have a full party, creatures you control gain "Whenever this creature deals combat damage to a player, draw a card" until end of turn. -SVar:TrigAnimateAll:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Triggers$ TrigCDPlayer | sVars$ TrigDraw +SVar:TrigAnimateAll:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Triggers$ TrigCDPlayer SVar:TrigCDPlayer:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | CombatDamage$ True | Execute$ TrigDraw | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME deals combat damage to a player, draw a card. SVar:TrigDraw:DB$ Draw | NumCards$ 1 SVar:X:Count$Party diff --git a/forge-gui/res/cardsfolder/o/open_into_wonder.txt b/forge-gui/res/cardsfolder/o/open_into_wonder.txt index ca3add5e32b..cfbf55598b5 100644 --- a/forge-gui/res/cardsfolder/o/open_into_wonder.txt +++ b/forge-gui/res/cardsfolder/o/open_into_wonder.txt @@ -2,7 +2,7 @@ Name:Open into Wonder ManaCost:X U U Types:Sorcery A:SP$ Pump | Cost$ X U U | ValidTgts$ Creature | KW$ HIDDEN Unblockable | AILogic$ Pump | TargetMin$ X | TargetMax$ X | TgtPrompt$ Select X target creatures | SubAbility$ DBAnimate | StackDescription$ X target creatures [{c:Targeted}] can't be blocked this turn. Until end of turn, those creatures gain "Whenever this creature deals combat damage to a player, draw a card." | SpellDescription$ X target creatures can't be blocked this turn. Until end of turn, those creatures gain "Whenever this creature deals combat damage to a player, draw a card." -SVar:DBAnimate:DB$ Animate | Defined$ Targeted | Triggers$ OpenIntoWonderTrigger | sVars$ OpenIntoWonderDraw | StackDescription$ None +SVar:DBAnimate:DB$ Animate | Defined$ Targeted | Triggers$ OpenIntoWonderTrigger | StackDescription$ None SVar:OpenIntoWonderTrigger:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | Execute$ OpenIntoWonderDraw | CombatDamage$ True | TriggerDescription$ Whenever this creature deals combat damage to a player, draw a card. SVar:OpenIntoWonderDraw:DB$ Draw | NumCards$ 1 SVar:X:Count$xPaid diff --git a/forge-gui/res/cardsfolder/r/rakavolver.txt b/forge-gui/res/cardsfolder/r/rakavolver.txt index 4722f7c397b..520d1714eb5 100644 --- a/forge-gui/res/cardsfolder/r/rakavolver.txt +++ b/forge-gui/res/cardsfolder/r/rakavolver.txt @@ -6,7 +6,7 @@ K:Kicker:1 W:U K:ETBReplacement:Other:VolverStrength:Mandatory::Card.Self+kicked 1 K:ETBReplacement:Other:VolverPumped:Mandatory::Card.Self+kicked 2 SVar:VolverStrength:DB$ PutCounter | Defined$ Self | CounterType$ P1P1 | CounterNum$ 2 | ETB$ True | SubAbility$ VolverLife | SpellDescription$ If CARDNAME was kicked with its {1}{W} kicker, it enters the battlefield with two +1/+1 counters on it and with "Whenever CARDNAME deals damage, you gain that much life." -SVar:VolverLife:DB$ Animate | Defined$ Self | Triggers$ PseudoLifelink | sVars$ VolverTrigGain,VolverX | Duration$ Permanent +SVar:VolverLife:DB$ Animate | Defined$ Self | Triggers$ PseudoLifelink | Duration$ Permanent SVar:PseudoLifelink:Mode$ DamageDealtOnce | ValidSource$ Card.Self | Execute$ VolverTrigGain | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME deals damage, you gain that much life. SVar:VolverTrigGain:DB$ GainLife | Defined$ You | LifeAmount$ VolverX SVar:VolverX:TriggerCount$DamageAmount diff --git a/forge-gui/res/cardsfolder/s/shackles_of_treachery.txt b/forge-gui/res/cardsfolder/s/shackles_of_treachery.txt index 5a2bf5fcea6..f3e5596c493 100644 --- a/forge-gui/res/cardsfolder/s/shackles_of_treachery.txt +++ b/forge-gui/res/cardsfolder/s/shackles_of_treachery.txt @@ -2,7 +2,7 @@ Name:Shackles of Treachery ManaCost:2 R Types:Sorcery A:SP$ GainControl | Cost$ 2 R | ValidTgts$ Creature | TgtPrompt$ Select target creature | LoseControl$ EOT | Untap$ True | AddKWs$ Haste | SubAbility$ DBAnimate | SpellDescription$ Gain control of target creature until end of turn. Untap that creature. Until end of turn, it gains haste and "Whenever this creature deals damage, destroy target Equipment attached to it." -SVar:DBAnimate:DB$ Animate | Defined$ ParentTarget | Triggers$ Shackles | sVars$ TrigDestroy +SVar:DBAnimate:DB$ Animate | Defined$ ParentTarget | Triggers$ Shackles SVar:Shackles:Mode$ DamageDone | ValidSource$ Card.Self | Execute$ TrigDestroy | TriggerDescription$ Whenever this creature deals damage, destroy target Equipment attached to it. SVar:TrigDestroy:DB$ Destroy | ValidTgts$ Equipment.Attached | TgtPrompt$ Select target Equipment attached to the creature Oracle:Gain control of target creature until end of turn. Untap that creature. Until end of turn, it gains haste and "Whenever this creature deals damage, destroy target Equipment attached to it." diff --git a/forge-gui/res/cardsfolder/s/showstopper.txt b/forge-gui/res/cardsfolder/s/showstopper.txt index c3e937b03fc..cdb30f04798 100644 --- a/forge-gui/res/cardsfolder/s/showstopper.txt +++ b/forge-gui/res/cardsfolder/s/showstopper.txt @@ -1,7 +1,7 @@ Name:Showstopper ManaCost:1 B R Types:Instant -A:SP$ AnimateAll | Cost$ 1 B R | ValidCards$ Creature.YouCtrl | Triggers$ DiesTrigger | sVars$ ShowstopperTrigDamage | SpellDescription$ Until end of turn, creatures you control gain "When this creature dies, it deals 2 damage to target creature an opponent controls." +A:SP$ AnimateAll | Cost$ 1 B R | ValidCards$ Creature.YouCtrl | Triggers$ DiesTrigger | SpellDescription$ Until end of turn, creatures you control gain "When this creature dies, it deals 2 damage to target creature an opponent controls." SVar:DiesTrigger:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ ShowstopperTrigDamage | TriggerController$ TriggeredCardController | TriggerDescription$ When CARDNAME dies, it deals 2 damage to target creature an opponent controls. SVar:ShowstopperTrigDamage:DB$ DealDamage | ValidTgts$ Creature.OppCtrl | TgtPrompt$ Select target creature an opponent controls | NumDmg$ 2 AI:RemoveDeck:All diff --git a/forge-gui/res/cardsfolder/s/simic_basilisk.txt b/forge-gui/res/cardsfolder/s/simic_basilisk.txt index 2313c1bb12f..f94abb44ab8 100644 --- a/forge-gui/res/cardsfolder/s/simic_basilisk.txt +++ b/forge-gui/res/cardsfolder/s/simic_basilisk.txt @@ -3,7 +3,7 @@ ManaCost:4 G G Types:Creature Basilisk Mutant PT:0/0 K:Graft:3 -A:AB$ Animate | Cost$ 1 G | ValidTgts$ Creature.counters_GE1_P1P1 | TgtPrompt$ Select target creature with a +1/+1 counter on it | Triggers$ DestroyTrigger | sVars$ DelTrigSimic,TrigDestroySimic | SpellDescription$ Until end of turn, target creature with a +1/+1 counter on it gains "Whenever this creature deals combat damage to a creature, destroy that creature at end of combat." +A:AB$ Animate | Cost$ 1 G | ValidTgts$ Creature.counters_GE1_P1P1 | TgtPrompt$ Select target creature with a +1/+1 counter on it | Triggers$ DestroyTrigger | SpellDescription$ Until end of turn, target creature with a +1/+1 counter on it gains "Whenever this creature deals combat damage to a creature, destroy that creature at end of combat." SVar:DestroyTrigger:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Creature | CombatDamage$ True | TriggerZones$ Battlefield | Execute$ DelTrig | TriggerDescription$ Whenever CARDNAME deals combat damage to a creature, destroy that creature at end of combat. SVar:DelTrigSimic:DB$ DelayedTrigger | Mode$ Phase | Phase$ EndCombat | ValidPlayer$ Player | Execute$ TrigDestroySimic | RememberObjects$ TriggeredTargetLKICopy | TriggerDescription$ Destroy damaged creature at end of combat. SVar:TrigDestroySimic:DB$ Destroy | Defined$ DelayTriggerRememberedLKI diff --git a/forge-gui/res/cardsfolder/s/stir_the_pride.txt b/forge-gui/res/cardsfolder/s/stir_the_pride.txt index 315fa61b9db..7510b798651 100644 --- a/forge-gui/res/cardsfolder/s/stir_the_pride.txt +++ b/forge-gui/res/cardsfolder/s/stir_the_pride.txt @@ -4,7 +4,7 @@ Types:Instant K:Entwine:1 W A:SP$ Charm | Cost$ 4 W | Choices$ DBPumpAll,DBAnimateAll | CharmNum$ 1 SVar:DBPumpAll:DB$ PumpAll | NumAtt$ 2 | NumDef$ 2 | ValidCards$ Creature.YouCtrl | SpellDescription$ Creatures you control get +2/+2 until end of turn. -SVar:DBAnimateAll:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Triggers$ TrigPrideDamage | sVars$ GainLife,GainLifeX | SpellDescription$ Until end of turn, creatures you control gain "Whenever this creature deals damage, you gain that much life." +SVar:DBAnimateAll:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Triggers$ TrigPrideDamage | SpellDescription$ Until end of turn, creatures you control gain "Whenever this creature deals damage, you gain that much life." SVar:TrigPrideDamage:Mode$ DamageDealtOnce | ValidSource$ Card.Self | Execute$ GainLife | TriggerZones$ Battlefield | TriggerDescription$ Whenever CARDNAME deals damage, you gain that much life. SVar:GainLife:DB$ GainLife | LifeAmount$ GainLifeX SVar:GainLifeX:TriggerCount$DamageAmount diff --git a/forge-gui/res/cardsfolder/s/storm_the_citadel.txt b/forge-gui/res/cardsfolder/s/storm_the_citadel.txt index 6cd8a430994..4fc471ee9a1 100644 --- a/forge-gui/res/cardsfolder/s/storm_the_citadel.txt +++ b/forge-gui/res/cardsfolder/s/storm_the_citadel.txt @@ -2,7 +2,7 @@ Name:Storm the Citadel ManaCost:4 G Types:Sorcery A:SP$ PumpAll | Cost$ 4 G | ValidCards$ Creature.YouCtrl | NumAtt$ 2 | NumDef$ 2 | SubAbility$ DBAnimateAll | SpellDescription$ Until end of turn, creatures you control get +2/+2 and gain "Whenever this creature deals combat damage to a player or planeswalker, destroy target artifact or enchantment defending player controls." -SVar:DBAnimateAll:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Triggers$ Trig | sVars$ Eff +SVar:DBAnimateAll:DB$ AnimateAll | ValidCards$ Creature.YouCtrl | Triggers$ Trig SVar:Trig:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player,Planeswalker | CombatDamage$ True | Execute$ Eff | TriggerDescription$ Whenever this creature deals combat damage to a player or planeswalker, destroy target artifact or enchantment defending player controls. SVar:Eff:DB$ Destroy | ValidTgts$ Artifact,Enchantment | TargetsWithDefinedController$ TriggeredDefendingPlayer | TargetMin$ 0 | TargetMax$ 1 | TgtPrompt$ Select target artifact or enchantment defending player controls. SVar:PlayMain1:TRUE diff --git a/forge-gui/res/cardsfolder/s/supernatural_stamina.txt b/forge-gui/res/cardsfolder/s/supernatural_stamina.txt index f4ad6b71214..298a3f96ebf 100644 --- a/forge-gui/res/cardsfolder/s/supernatural_stamina.txt +++ b/forge-gui/res/cardsfolder/s/supernatural_stamina.txt @@ -2,7 +2,7 @@ Name:Supernatural Stamina ManaCost:B Types:Instant A:SP$ Pump | Cost$ B | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ +2 | SpellDescription$ Until end of turn, target creature gets +2/+0 and gains "When this creature dies, return it to the battlefield tapped under its owner's control." | SubAbility$ DBAnimate -SVar:DBAnimate:DB$ Animate | Triggers$ SupernaturalStaminaChangeZone | sVars$ SupernaturalStaminaTrigChangeZone | Defined$ ParentTarget +SVar:DBAnimate:DB$ Animate | Triggers$ SupernaturalStaminaChangeZone | Defined$ ParentTarget SVar:SupernaturalStaminaChangeZone:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ SupernaturalStaminaTrigChangeZone | TriggerController$ TriggeredCardController | TriggerDescription$ When this creature dies, return it to the battlefield tapped under its owner's control. SVar:SupernaturalStaminaTrigChangeZone:DB$ ChangeZone | Origin$ Graveyard | Destination$ Battlefield | Tapped$ True | Defined$ TriggeredNewCardLKICopy Oracle:Until end of turn, target creature gets +2/+0 and gains "When this creature dies, return it to the battlefield tapped under its owner's control." diff --git a/forge-gui/res/cardsfolder/t/tenacious_pup.txt b/forge-gui/res/cardsfolder/t/tenacious_pup.txt index 8142f67aceb..981c17ee6ec 100644 --- a/forge-gui/res/cardsfolder/t/tenacious_pup.txt +++ b/forge-gui/res/cardsfolder/t/tenacious_pup.txt @@ -5,10 +5,10 @@ PT:1/2 T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigGainLife | TriggerDescription$ When CARDNAME enters the battlefield, you gain 1 life. When you cast your next creature spell, that creature enters the battlefield with an additional +1/+1 counter, trample counter, and vigilance counter on it. SVar:TrigGainLife:DB$ GainLife | LifeAmount$ 1 | SubAbility$ DBDelayedTrigger SVar:DBDelayedTrigger:DB$ DelayedTrigger | Execute$ TrigAddAPI | Mode$ SpellCast | ValidCard$ Creature | ValidActivatingPlayer$ You | TriggerDescription$ When you cast your next creature spell, that creature enters the battlefield with an additional +1/+1 counter, trample counter, and vigilance counter on it. -SVar:TrigAddAPI:DB$ Animate | Defined$ TriggeredCard | sVars$ AddExtraCounter,DBTrample,DBVigilance | SubAbility$ DBAddETBRep -SVar:DBAddETBRep:DB$ Animate | Defined$ TriggeredCard | Keywords$ ETBReplacement:Other:AddExtraCounter:Mandatory:Battlefield:Card.Self -SVar:AddExtraCounter:DB$ PutCounter | ETB$ True | Defined$ ReplacedCard | CounterType$ P1P1 | CounterNum$ 1 | SubAbility$ DBTrample -SVar:DBTrample:DB$ PutCounter | ETB$ True | Defined$ ReplacedCard | CounterType$ Trample | CounterNum$ 1 | SubAbility$ DBVigilance -SVar:DBVigilance:DB$ PutCounter | ETB$ True | Defined$ ReplacedCard | CounterType$ Vigilance | CounterNum$ 1 +SVar:TrigAddAPI:DB$ Effect | RememberObjects$ TriggeredCard | ForgetOnMoved$ Stack | ReplacementEffects$ ReplaceEnter +SVar:ReplaceEnter:Event$ Moved | ValidCard$ Card.IsRemembered | Destination$ Battlefield | ReplaceWith$ AddExtraCounter | Description$ That creature enters the battlefield with an additional +1/+1 counter, trample counter, and vigilance counter on it. +SVar:AddExtraCounter:DB$ PutCounter | ETB$ True | Defined$ ReplacedCard | CounterTypes$ P1P1,Trample,Vigilance | CounterNum$ 1 | SubAbility$ ToBattlefield +SVar:ToBattlefield:DB$ InternalEtbReplacement | SubAbility$ DBExile +SVar:DBExile:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile DeckHas:Ability$LifeGain|Counters Oracle:When Tenacious Pup enters the battlefield, you gain 1 life. When you cast your next creature spell, that creature enters the battlefield with an additional +1/+1 counter, trample counter, and vigilance counter on it. diff --git a/forge-gui/res/cardsfolder/t/tower_above.txt b/forge-gui/res/cardsfolder/t/tower_above.txt index d623ff5da41..b700778e426 100644 --- a/forge-gui/res/cardsfolder/t/tower_above.txt +++ b/forge-gui/res/cardsfolder/t/tower_above.txt @@ -2,7 +2,7 @@ Name:Tower Above ManaCost:2/G 2/G 2/G Types:Sorcery A:SP$ Pump | Cost$ 2G 2G 2G | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ 4 | NumDef$ 4 | KW$ Trample & Wither | SubAbility$ DBAnimate | SpellDescription$ Until end of turn, target creature gets +4/+4 and gains trample, wither, and "When this creature attacks, target creature blocks it this turn if able." (It deals damage to creatures in the form of -1/-1 counters.) -SVar:DBAnimate:DB$ Animate | Defined$ Targeted | Triggers$ TrigAttack | sVars$ TowerAboveTrigBlock +SVar:DBAnimate:DB$ Animate | Defined$ Targeted | Triggers$ TrigAttack SVar:TrigAttack:Mode$ Attacks | ValidCard$ Creature.Self | Execute$ TowerAboveTrigBlock | TriggerDescription$ Whenever CARDNAME attacks, target creature blocks it this turn if able SVar:TowerAboveTrigBlock:DB$ MustBlock | ValidTgts$ Creature | TgtPrompt$ Select target creature | SpellDescription$ Target creature blocks CARDNAME this turn if able. Oracle:({2/G} can be paid with any two mana or with {G}. This card's mana value is 6.)\nUntil end of turn, target creature gets +4/+4 and gains trample, wither, and "When this creature attacks, target creature blocks it this turn if able." (It deals damage to creatures in the form of -1/-1 counters.) diff --git a/forge-gui/res/cardsfolder/v/verdant_rebirth.txt b/forge-gui/res/cardsfolder/v/verdant_rebirth.txt index da62320eef9..e3f6a2b917e 100644 --- a/forge-gui/res/cardsfolder/v/verdant_rebirth.txt +++ b/forge-gui/res/cardsfolder/v/verdant_rebirth.txt @@ -1,7 +1,7 @@ Name:Verdant Rebirth ManaCost:1 G Types:Instant -A:SP$ Animate | Cost$ 1 G | ValidTgts$ Creature | TgtPrompt$ Select target creature | Triggers$ VerdantRebirthChangeZone | sVars$ VerdantRebirthTrigChangeZone | SubAbility$ DBDraw | SpellDescription$ Until end of turn, target creature gains "When this creature dies, return it to its owner's hand." Draw a card. +A:SP$ Animate | Cost$ 1 G | ValidTgts$ Creature | TgtPrompt$ Select target creature | Triggers$ VerdantRebirthChangeZone | SubAbility$ DBDraw | SpellDescription$ Until end of turn, target creature gains "When this creature dies, return it to its owner's hand." Draw a card. SVar:VerdantRebirthChangeZone:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ VerdantRebirthTrigChangeZone | TriggerController$ TriggeredCardController | TriggerDescription$ When this creature dies, return it to its owner's hand. SVar:VerdantRebirthTrigChangeZone:DB$ ChangeZone | Origin$ Graveyard | Destination$ Hand | Defined$ TriggeredNewCardLKICopy SVar:DBDraw:DB$ Draw | NumCards$ 1 diff --git a/forge-gui/res/cardsfolder/v/vraska_scheming_gorgon.txt b/forge-gui/res/cardsfolder/v/vraska_scheming_gorgon.txt index fc033db1321..adc8bae1c3a 100644 --- a/forge-gui/res/cardsfolder/v/vraska_scheming_gorgon.txt +++ b/forge-gui/res/cardsfolder/v/vraska_scheming_gorgon.txt @@ -4,7 +4,7 @@ Types:Legendary Planeswalker Vraska Loyalty:5 A:AB$ PumpAll | Cost$ AddCounter<2/LOYALTY> | Planeswalker$ True | ValidCards$ Creature.YouCtrl | NumAtt$ +1 | SpellDescription$ Creatures you control get +1/+0 until end of turn. A:AB$ Destroy | Cost$ SubCounter<3/LOYALTY> | Planeswalker$ True | ValidTgts$ Creature | TgtPrompt$ Select target creature | SpellDescription$ Destroy target creature. -A:AB$ AnimateAll | Cost$ SubCounter<10/LOYALTY> | Planeswalker$ True | Ultimate$ True | ValidCards$ Creature.YouCtrl | Keywords$ Deathtouch | Triggers$ Trig | sVars$ Eff | SpellDescription$ Until end of turn, creatures you control gain deathtouch and "Whenever this creature deals damage to an opponent, that player loses the game." +A:AB$ AnimateAll | Cost$ SubCounter<10/LOYALTY> | Planeswalker$ True | Ultimate$ True | ValidCards$ Creature.YouCtrl | Keywords$ Deathtouch | Triggers$ Trig | SpellDescription$ Until end of turn, creatures you control gain deathtouch and "Whenever this creature deals damage to an opponent, that player loses the game." SVar:Trig:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Opponent | Execute$ Eff | TriggerDescription$ Whenever this creature deals damage to an opponent, that player loses the game. SVar:Eff:DB$ LosesGame | Defined$ TriggeredTarget SVar:PlayMain1:TRUE diff --git a/forge-gui/res/cardsfolder/v/vraska_the_unseen.txt b/forge-gui/res/cardsfolder/v/vraska_the_unseen.txt index dc18dd105c2..8af952e8eb6 100644 --- a/forge-gui/res/cardsfolder/v/vraska_the_unseen.txt +++ b/forge-gui/res/cardsfolder/v/vraska_the_unseen.txt @@ -2,7 +2,7 @@ Name:Vraska the Unseen ManaCost:3 B G Types:Legendary Planeswalker Vraska Loyalty:5 -A:AB$ Animate | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | Defined$ Self | Triggers$ TrigVraska | sVars$ VraskaGaze | Duration$ UntilYourNextTurn | AILogic$ EOT | SpellDescription$ Until your next turn, whenever a creature deals combat damage to CARDNAME, destroy that creature. | StackDescription$ Until your next turn, whenever a creature deals combat damage to CARDNAME, destroy that creature. +A:AB$ Animate | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | Defined$ Self | Triggers$ TrigVraska | Duration$ UntilYourNextTurn | AILogic$ EOT | SpellDescription$ Until your next turn, whenever a creature deals combat damage to CARDNAME, destroy that creature. | StackDescription$ Until your next turn, whenever a creature deals combat damage to CARDNAME, destroy that creature. SVar:TrigVraska:Mode$ DamageDone | ValidSource$ Creature | ValidTarget$ Card.Self | TriggerZones$ Battlefield | CombatDamage$ True | Execute$ VraskaGaze | TriggerDescription$ Until your next turn, whenever a creature deals combat damage to CARDNAME, destroy that creature. SVar:VraskaGaze:DB$ Destroy | Defined$ TriggeredSourceLKICopy A:AB$ Destroy | Cost$ SubCounter<3/LOYALTY> | Planeswalker$ True | ValidTgts$ Permanent.nonLand | TgtPrompt$ Select target nonland permanent | SpellDescription$ Destroy target nonland permanent. diff --git a/forge-gui/res/cardsfolder/w/warriors_lesson.txt b/forge-gui/res/cardsfolder/w/warriors_lesson.txt index a70d6ecb3aa..3ed0d0de144 100644 --- a/forge-gui/res/cardsfolder/w/warriors_lesson.txt +++ b/forge-gui/res/cardsfolder/w/warriors_lesson.txt @@ -1,7 +1,7 @@ Name:Warriors' Lesson ManaCost:G Types:Instant -A:SP$ Animate | Cost$ G | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select up to two target creatures you control | TargetMin$ 0 | TargetMax$ 2 | Triggers$ WarriorLessonDmg | sVars$ WarriorLessonDraw | SpellDescription$ Until end of turn, up to two target creatures you control each gain "Whenever this creature deals combat damage to a player, draw a card." +A:SP$ Animate | ValidTgts$ Creature.YouCtrl | TgtPrompt$ Select up to two target creatures you control | TargetMin$ 0 | TargetMax$ 2 | Triggers$ WarriorLessonDmg | SpellDescription$ Until end of turn, up to two target creatures you control each gain "Whenever this creature deals combat damage to a player, draw a card." SVar:WarriorLessonDmg:Mode$ DamageDone | ValidSource$ Card.Self | ValidTarget$ Player | CombatDamage$ True | Execute$ WarriorLessonDraw | TriggerDescription$ Whenever this creature deals combat damage to a player, draw a card. SVar:WarriorLessonDraw:DB$ Draw | Defined$ You | NumCards$ 1 AI:RemoveDeck:All diff --git a/forge-gui/res/cardsfolder/w/whipgrass_entangler.txt b/forge-gui/res/cardsfolder/w/whipgrass_entangler.txt index 52d0caa6d92..a27a22b878a 100644 --- a/forge-gui/res/cardsfolder/w/whipgrass_entangler.txt +++ b/forge-gui/res/cardsfolder/w/whipgrass_entangler.txt @@ -2,7 +2,7 @@ Name:Whipgrass Entangler ManaCost:2 W Types:Creature Human Cleric PT:1/3 -A:AB$ Animate | Cost$ 1 W | ValidTgts$ Creature | staticAbilities$ WhipgrassCantAttack,WhipgrassCantBlock | sVars$ WhipgrassClericNum | SpellDescription$ Until end of turn, target creature gains "This creature can't attack or block unless its controller pays {1} for each Cleric on the battlefield." +A:AB$ Animate | Cost$ 1 W | ValidTgts$ Creature | staticAbilities$ WhipgrassCantAttack,WhipgrassCantBlock | SpellDescription$ Until end of turn, target creature gains "This creature can't attack or block unless its controller pays {1} for each Cleric on the battlefield." SVar:WhipgrassCantAttack:Mode$ CantAttackUnless | ValidCard$ Card.Self | Cost$ WhipgrassClericNum | Description$ CARDNAME can't attack or block unless you pay 1 for each Cleric on the battlefield. SVar:WhipgrassCantBlock:Mode$ CantBlockUnless | ValidCard$ Card.Self | Cost$ WhipgrassClericNum SVar:WhipgrassClericNum:Count$Valid Cleric diff --git a/forge-gui/res/cardsfolder/w/whisperwood_elemental.txt b/forge-gui/res/cardsfolder/w/whisperwood_elemental.txt index 83c143bc5fc..89eb4458473 100644 --- a/forge-gui/res/cardsfolder/w/whisperwood_elemental.txt +++ b/forge-gui/res/cardsfolder/w/whisperwood_elemental.txt @@ -4,7 +4,7 @@ Types:Creature Elemental PT:4/4 T:Mode$ Phase | Phase$ End of Turn | ValidPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigManifest | TriggerDescription$ At the beginning of your end step, manifest the top card of your library. (Put it onto the battlefield face down as a 2/2 creature. Turn it face up any time for its mana cost if it's a creature card) SVar:TrigManifest:DB$ Manifest | Amount$ 1 | Defined$ TopOfLibrary -A:AB$ AnimateAll | Cost$ Sac<1/CARDNAME> | ValidCards$ Creature.YouCtrl+nonToken+faceUp | Triggers$ Trig | sVars$ WhisperwoodElementalEff | SpellDescription$ Until end of turn, face-up, nontoken creatures you control gain "When this creature dies, manifest the top card of your library." +A:AB$ AnimateAll | Cost$ Sac<1/CARDNAME> | ValidCards$ Creature.YouCtrl+nonToken+faceUp | Triggers$ Trig | SpellDescription$ Until end of turn, face-up, nontoken creatures you control gain "When this creature dies, manifest the top card of your library." SVar:Trig:Mode$ ChangesZone | Origin$ Battlefield | Destination$ Graveyard | ValidCard$ Card.Self | Execute$ WhisperwoodElementalEff | TriggerDescription$ When this creature dies, manifest the top card of your library. SVar:WhisperwoodElementalEff:DB$ Manifest | Amount$ 1 | Defined$ TopOfLibrary Oracle:At the beginning of your end step, manifest the top card of your library. (Put it onto the battlefield face down as a 2/2 creature. Turn it face up any time for its mana cost if it's a creature card.)\nSacrifice Whisperwood Elemental: Until end of turn, face-up nontoken creatures you control gain "When this creature dies, manifest the top card of your library." diff --git a/forge-gui/src/main/java/forge/gamemodes/puzzle/Puzzle.java b/forge-gui/src/main/java/forge/gamemodes/puzzle/Puzzle.java index d4b34e04c56..f0f2c8764ea 100644 --- a/forge-gui/src/main/java/forge/gamemodes/puzzle/Puzzle.java +++ b/forge-gui/src/main/java/forge/gamemodes/puzzle/Puzzle.java @@ -14,6 +14,7 @@ import forge.game.ability.AbilityFactory; import forge.game.card.Card; import forge.game.phase.PhaseType; import forge.game.player.Player; +import forge.game.spellability.SpellAbility; import forge.game.trigger.Trigger; import forge.game.trigger.TriggerHandler; import forge.game.zone.ZoneType; @@ -156,11 +157,12 @@ public class Puzzle extends GameState implements InventoryItem, Comparable