From d8d0c67462b49bd737fb9d12da5b68dfeac5d1c1 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 16:29:22 -0400 Subject: [PATCH 1/8] study_hall.txt --- forge-gui/res/cardsfolder/upcoming/study_hall.txt | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/study_hall.txt diff --git a/forge-gui/res/cardsfolder/upcoming/study_hall.txt b/forge-gui/res/cardsfolder/upcoming/study_hall.txt new file mode 100644 index 00000000000..8aa3e312c0f --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/study_hall.txt @@ -0,0 +1,10 @@ +Name:Study Hall +ManaCost:no cost +Types:Land +A:AB$ Mana | Cost$ T | Produced$ C | SpellDescription$ Add {C}. +A:AB$ Mana | Cost$ 1 T | Produced$ Any | Amount$ 1 | TriggersWhenSpent$ TrigSpent | SpellDescription$ Add one mana of any color. When you spend this mana to cast your commander, scry X, where X is the number of times it's been cast from the command zone this game. +SVar:TrigSpent:Mode$ SpellCast | ValidCard$ Card.IsCommander+YouOwn | ValidActivatingPlayer$ You | Execute$ TrigScry | TriggerDescription$ When you spend this mana to cast your commander, scry X, where X is the number of times it's been cast from the command zone this game. +SVar:TrigScry:DB$ Scry | ScryNum$ X +SVar:X:TriggeredCard$CommanderCastFromCommandZone +AI:RemoveDeck:NonCommander +Oracle:{T}: Add {C}.\n{1}, {T}: Add one mana of any color. When you spend this mana to cast your commander, scry X, where X is the number of times it's been cast from the command zone this game. From acf89b1e9e786532ea0b2175f7c23866b0e0db80 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 17:41:01 -0400 Subject: [PATCH 2/8] monologue_tax.txt --- forge-gui/res/cardsfolder/upcoming/monologue_tax.txt | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/monologue_tax.txt diff --git a/forge-gui/res/cardsfolder/upcoming/monologue_tax.txt b/forge-gui/res/cardsfolder/upcoming/monologue_tax.txt new file mode 100644 index 00000000000..ccf1d8c6c4b --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/monologue_tax.txt @@ -0,0 +1,7 @@ +Name:Monologue Tax +ManaCost:2 W +Types:Enchantment +T:Mode$ SpellCast | ValidActivatingPlayer$ Opponent | ActivatorThisTurnCast$ EQ2 | NoResolvingCheck$ True | TriggerZones$ Battlefield | Execute$ TrigToken | TriggerDescription$ Whenever an opponent casts their second spell each turn, you create a Treasure token. +SVar:TrigToken:DB$ Token | TokenScript$ c_a_treasure_sac +DeckHas:Ability$Token & Ability$Sacrifice +Oracle:Whenever an opponent casts their second spell each turn, you create a Treasure token. From 728afbc88760d29b04e241040f8acf644c598ea0 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 18:10:51 -0400 Subject: [PATCH 3/8] madcap_experiment.txt tidy up --- forge-gui/res/cardsfolder/m/madcap_experiment.txt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/forge-gui/res/cardsfolder/m/madcap_experiment.txt b/forge-gui/res/cardsfolder/m/madcap_experiment.txt index 4cffb368ffa..1d0c4877b9a 100644 --- a/forge-gui/res/cardsfolder/m/madcap_experiment.txt +++ b/forge-gui/res/cardsfolder/m/madcap_experiment.txt @@ -1,9 +1,10 @@ Name:Madcap Experiment ManaCost:3 R Types:Sorcery -A:SP$ DigUntil | Cost$ 3 R | Valid$ Artifact | ValidDescription$ artifact | FoundDestination$ Battlefield | RevealedDestination$ Library | RevealedLibraryPosition$ -1 | RevealRandomOrder$ True | RememberRevealed$ True | SubAbility$ DBDealDamage | SpellDescription$ Reveal cards from the top of your library until you reveal an artifact card. Put that card onto the battlefield and the rest on the bottom of your library in a random order. Madcap Experiment deals damage to you equal to the number of cards revealed this way. -SVar:DBDealDamage:DB$DealDamage | Defined$ You | NumDmg$ X | SubAbility$ DBCleanup +A:SP$ DigUntil | Cost$ 3 R | Valid$ Artifact | ValidDescription$ artifact | FoundDestination$ Battlefield | RevealedDestination$ Library | RevealedLibraryPosition$ -1 | RevealRandomOrder$ True | RememberRevealed$ True | SubAbility$ DBDealDamage | SpellDescription$ Reveal cards from the top of your library until you reveal an artifact card. Put that card onto the battlefield and the rest on the bottom of your library in a random order. CARDNAME deals damage to you equal to the number of cards revealed this way. +SVar:DBDealDamage:DB$ DealDamage | Defined$ You | NumDmg$ X | SubAbility$ DBCleanup SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True -SVar:X:Remembered$Amount -SVar:Picture:http://www.wizards.com/global/images/magic/general/madcap_experiment.jpg +SVar:X:Remembered$Amount +DeckNeeds:Type$Artifact +AI:RemoveDeck:Random Oracle:Reveal cards from the top of your library until you reveal an artifact card. Put that card onto the battlefield and the rest on the bottom of your library in a random order. Madcap Experiment deals damage to you equal to the number of cards revealed this way. From 9fe15fd8c248852aa8dbe9d7ef6e079b326181d5 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 18:11:18 -0400 Subject: [PATCH 4/8] audacious_reshapers.txt --- .../res/cardsfolder/upcoming/audacious_reshapers.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/audacious_reshapers.txt diff --git a/forge-gui/res/cardsfolder/upcoming/audacious_reshapers.txt b/forge-gui/res/cardsfolder/upcoming/audacious_reshapers.txt new file mode 100644 index 00000000000..eda4fa9e0a3 --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/audacious_reshapers.txt @@ -0,0 +1,12 @@ +Name:Audacious Reshapers +ManaCost:2 R +Types:Creature Human Artificer +PT:3/3 +A:AB$ DigUntil | Cost$ T Sac<1/Artifact> | Valid$ Artifact | ValidDescription$ artifact | FoundDestination$ Battlefield | RevealedDestination$ Library | RevealedLibraryPosition$ -1 | RevealRandomOrder$ True | RememberRevealed$ True | SubAbility$ DBDealDamage | SpellDescription$ Reveal cards from the top of your library until you reveal an artifact card. Put that card onto the battlefield and the rest on the bottom of your library in a random order. CARDNAME deals damage to you equal to the number of cards revealed this way. +SVar:DBDealDamage:DB$ DealDamage | Defined$ You | NumDmg$ X | SubAbility$ DBCleanup +SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True +SVar:X:Remembered$Amount +DeckHas:Ability$Sacrifice +DeckNeeds:Type$Artifact +AI:RemoveDeck:Random +Oracle:{T}, Sacrifice an artifact: Reveal cards from the top of your library until you reveal an artifact card. Put that card onto the battlefield and the rest on the bottom of your library in a random order. Audacious Reshapers deals damage to you equal to the number of cards revealed this way. From af8c1b2092dc1741f246801d0c650742f75e3840 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 18:45:59 -0400 Subject: [PATCH 5/8] cursed_mirror.txt --- forge-gui/res/cardsfolder/upcoming/cursed_mirror.txt | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/cursed_mirror.txt diff --git a/forge-gui/res/cardsfolder/upcoming/cursed_mirror.txt b/forge-gui/res/cardsfolder/upcoming/cursed_mirror.txt new file mode 100644 index 00000000000..2aeaffcc722 --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/cursed_mirror.txt @@ -0,0 +1,7 @@ +Name:Cursed Mirror +ManaCost:2 R +Types:Artifact +A:AB$ Mana | Cost$ T | Produced$ R | SpellDescription$ Add {R}. +K:ETBReplacement:Copy:DBCopy:Optional +SVar:DBCopy:DB$ Clone | Choices$ Creature | AddKeywords$ Haste | Duration$ UntilEndOfTurn | SpellDescription$ As CARDNAME enters the battlefield, you may have it become a copy of any creature on the battlefield until end of turn, except it has haste. +Oracle:{T}: Add {R}.\nAs Cursed Mirror enters the battlefield, you may have it become a copy of any creature on the battlefield until end of turn, except it has haste. From 3fbcf093265b472f23de670f03869288acfc7551 Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 23:04:29 -0400 Subject: [PATCH 6/8] ruin_grinder.txt --- .../res/cardsfolder/upcoming/ruin_grinder.txt | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/ruin_grinder.txt diff --git a/forge-gui/res/cardsfolder/upcoming/ruin_grinder.txt b/forge-gui/res/cardsfolder/upcoming/ruin_grinder.txt new file mode 100644 index 00000000000..8a36a724e41 --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/ruin_grinder.txt @@ -0,0 +1,14 @@ +Name:Ruin Grinder +ManaCost:5 R +Types:Artifact Creature Construct +PT:7/4 +K:Menace +T:Mode$ ChangesZone | ValidCard$ Card.Self | Origin$ Battlefield | Destination$ Graveyard | Execute$ TrigRepeatEach | TriggerDescription$ When CARDNAME dies, each player may discard their hand and draw seven cards. +SVar:TrigRepeatEach:DB$ RepeatEach | RepeatPlayers$ Player | RepeatSubAbility$ DBChoose +SVar:DBChoose:DB$ GenericChoice | Choices$ DBDiscard,Noop | Defined$ Player.IsRemembered +SVar:DBDiscard:DB$ Discard | Mode$ Hand | Defined$ Player.IsRemembered | SubAbility$ DBDraw | SpellDescription$ Discard your hand and draw seven cards. +SVar:DBDraw:DB$ Draw | Defined$ Player.IsRemembered | NumCards$ 7 +SVar:Noop:DB$ Cleanup | SpellDescription$ Do nothing. +K:TypeCycling:Mountain:2 +DeckHas:Ability$Discard +Oracle:Menace\nWhen Ruin Grinder dies, each player may discard their hand and draw seven cards.\nMountaincycling {2} ({2}, Discard this card: Search your library for a Mountain card, reveal it, put it into your hand, then shuffle.) From 3fd3a3e5aab95d9afee12d0079bb60d91b68177f Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 23:05:16 -0400 Subject: [PATCH 7/8] archaeomancers_map.txt --- forge-gui/res/cardsfolder/upcoming/archaeomancers_map.txt | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 forge-gui/res/cardsfolder/upcoming/archaeomancers_map.txt diff --git a/forge-gui/res/cardsfolder/upcoming/archaeomancers_map.txt b/forge-gui/res/cardsfolder/upcoming/archaeomancers_map.txt new file mode 100644 index 00000000000..e2addcda7b6 --- /dev/null +++ b/forge-gui/res/cardsfolder/upcoming/archaeomancers_map.txt @@ -0,0 +1,8 @@ +Name:Archaeomancer's Map +ManaCost:2 W +Types:Artifact +T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Artifact.Self | Execute$ TrigSearch | TriggerDescription$ When CARDNAME enters the battlefield, search your library for up to two basic Plains cards, reveal them, put them into your hand, then shuffle. +SVar:TrigSearch:DB$ ChangeZone | Origin$ Library | Destination$ Hand | ChangeType$ Plains.Basic | ChangeNum$ 2 | Shuffle$ True +T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Land.OppCtrl+ControllerControlsMoreLand | TriggerZones$ Battlefield | Execute$ TrigChangeZone | OptionalDecider$ You | TriggerDescription$ Whenever a land enters the battlefield under an opponent's control, if that player controls more lands than you, you may put a land card from your hand onto the battlefield. +SVar:TrigChangeZone:DB$ ChangeZone | Origin$ Hand | Destination$ Battlefield | ChangeType$ Land.YouCtrl +Oracle:When Archaeomancer's Map enters the battlefield, search your library for up to two basic Plains cards, reveal them, put them into your hand, then shuffle.\nWhenever a land enters the battlefield under an opponent's control, if that player controls more lands than you, you may put a land card from your hand onto the battlefield. From 86d72b15c526f3cef8e8d2512fa397419a1ed64d Mon Sep 17 00:00:00 2001 From: Northmoc Date: Mon, 5 Apr 2021 23:05:56 -0400 Subject: [PATCH 8/8] support for archaeomancers_map.txt --- .../src/main/java/forge/game/card/CardProperty.java | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/forge-game/src/main/java/forge/game/card/CardProperty.java b/forge-game/src/main/java/forge/game/card/CardProperty.java index 724553d6831..7574e09b340 100644 --- a/forge-game/src/main/java/forge/game/card/CardProperty.java +++ b/forge-game/src/main/java/forge/game/card/CardProperty.java @@ -341,7 +341,14 @@ public class CardProperty { } } else if (property.startsWith("ControllerControls")) { final String type = property.substring(18); - if (type.startsWith("AtLeastAsMany")) { + if (type.startsWith("More")) { + String realType = type.split("More")[1]; + CardCollectionView cards = CardLists.getType(controller.getCardsIn(ZoneType.Battlefield), realType); + CardCollectionView yours = CardLists.getType(sourceController.getCardsIn(ZoneType.Battlefield), realType); + if (cards.size() <= yours.size()) { + return false; + } + } else if (type.startsWith("AtLeastAsMany")) { String realType = type.split("AtLeastAsMany")[1]; CardCollectionView cards = CardLists.getType(controller.getCardsIn(ZoneType.Battlefield), realType); CardCollectionView yours = CardLists.getType(sourceController.getCardsIn(ZoneType.Battlefield), realType);