From e1f70c89069ff3bc3a6584789ee4fa7ae1926edb Mon Sep 17 00:00:00 2001 From: tool4EvEr Date: Wed, 1 Feb 2023 12:24:38 +0100 Subject: [PATCH] Clean up --- forge-game/src/main/java/forge/game/card/CardProperty.java | 6 ------ .../forge/screens/home/settings/CSubmenuReleaseNotes.java | 2 -- forge-gui/res/cardsfolder/a/altar_of_the_lost.txt | 2 +- forge-gui/res/cardsfolder/m/monstrous_onslaught.txt | 2 -- forge-gui/res/cardsfolder/p/phantom_carriage.txt | 2 +- forge-gui/res/cardsfolder/q/quiet_speculation.txt | 2 +- forge-gui/res/cardsfolder/r/rootcoil_creeper.txt | 2 +- forge-gui/res/cardsfolder/r/runic_repetition.txt | 2 +- forge-gui/res/cardsfolder/rebalanced/a-phantom_carriage.txt | 2 +- forge-gui/res/cardsfolder/t/tombfire.txt | 2 +- 10 files changed, 7 insertions(+), 17 deletions(-) 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 54142f27953..20eb2cfc1fa 100644 --- a/forge-game/src/main/java/forge/game/card/CardProperty.java +++ b/forge-game/src/main/java/forge/game/card/CardProperty.java @@ -17,7 +17,6 @@ import forge.game.combat.AttackRequirement; import forge.game.combat.AttackingBand; import forge.game.combat.Combat; import forge.game.combat.CombatUtil; -import forge.game.keyword.Keyword; import forge.game.mana.Mana; import forge.game.player.Player; import forge.game.spellability.OptionalCost; @@ -1020,11 +1019,6 @@ public class CardProperty { if (!card.hasKeyword(property.substring(10))) { return false; } - } else if (property.startsWith("withFlashback")) { - boolean fb = card.hasKeyword(Keyword.FLASHBACK); - if (!fb) { - return false; - } } else if (property.startsWith("with")) { // ... Card keywords if (property.startsWith("without") && card.hasStartOfUnHiddenKeyword(property.substring(7))) { diff --git a/forge-gui-desktop/src/main/java/forge/screens/home/settings/CSubmenuReleaseNotes.java b/forge-gui-desktop/src/main/java/forge/screens/home/settings/CSubmenuReleaseNotes.java index 766a5c2c4bf..f4efe48833b 100644 --- a/forge-gui-desktop/src/main/java/forge/screens/home/settings/CSubmenuReleaseNotes.java +++ b/forge-gui-desktop/src/main/java/forge/screens/home/settings/CSubmenuReleaseNotes.java @@ -70,7 +70,6 @@ public enum CSubmenuReleaseNotes implements ICDoc { * Returns content of README.txt (release) or CHANGES.txt (snapshot). */ private static String getReleaseNotes() { - final String filename = ForgeConstants.CHANGES_FILE_NO_RELEASE; final String filePath = FileUtil.pathCombine(System.getProperty("user.dir"), filename); @@ -87,7 +86,6 @@ public enum CSubmenuReleaseNotes implements ICDoc { } else { notes = filePath + "\nis MISSING!"; } - return notes; } diff --git a/forge-gui/res/cardsfolder/a/altar_of_the_lost.txt b/forge-gui/res/cardsfolder/a/altar_of_the_lost.txt index ea6370647c0..5f880fa6f2d 100644 --- a/forge-gui/res/cardsfolder/a/altar_of_the_lost.txt +++ b/forge-gui/res/cardsfolder/a/altar_of_the_lost.txt @@ -2,6 +2,6 @@ Name:Altar of the Lost ManaCost:3 Types:Artifact K:CARDNAME enters the battlefield tapped. -A:AB$ Mana | Cost$ T | Produced$ Combo Any | Amount$ 2 | RestrictValid$ Spell.wasCastFromGraveyard+withFlashback | SpellDescription$ Add two mana in any combination of colors. Spend this mana only to cast spells with flashback from a graveyard. +A:AB$ Mana | Cost$ T | Produced$ Combo Any | Amount$ 2 | RestrictValid$ Spell.wasCastFromGraveyard+hasKeywordFlashback | SpellDescription$ Add two mana in any combination of colors. Spend this mana only to cast spells with flashback from a graveyard. AI:RemoveDeck:Random Oracle:Altar of the Lost enters the battlefield tapped.\n{T}: Add two mana in any combination of colors. Spend this mana only to cast spells with flashback from a graveyard. diff --git a/forge-gui/res/cardsfolder/m/monstrous_onslaught.txt b/forge-gui/res/cardsfolder/m/monstrous_onslaught.txt index 6aac9a41ac8..ace565fd821 100644 --- a/forge-gui/res/cardsfolder/m/monstrous_onslaught.txt +++ b/forge-gui/res/cardsfolder/m/monstrous_onslaught.txt @@ -2,8 +2,6 @@ Name:Monstrous Onslaught ManaCost:3 G G Types:Sorcery A:SP$ DealDamage | Cost$ 3 G G | ValidTgts$ Creature | TgtPrompt$ Select target creature to distribute damage to | NumDmg$ OrigPower | TargetMin$ Min | TargetMax$ OrigPower | DividedAsYouChoose$ OrigPower | SpellDescription$ CARDNAME deals X damage divided as you choose among any number of target creatures, where X is the greatest power among creatures you control as you cast this spell. -T:Mode$ SpellCast | ValidCard$ Card.Self | Static$ True | Execute$ CountPowerAtCast -SVar:CountPowerAtCast:DB$ StoreSVar | SVar$ OrigPower | Type$ Calculate | Expression$ OrigPower SVar:OrigPower:Count$Valid Creature.YouCtrl$GreatestPower SVar:Min:SVar$OrigPower/LimitMax.1 Oracle:Monstrous Onslaught deals X damage divided as you choose among any number of target creatures, where X is the greatest power among creatures you control as you cast this spell. diff --git a/forge-gui/res/cardsfolder/p/phantom_carriage.txt b/forge-gui/res/cardsfolder/p/phantom_carriage.txt index eb81b43d654..0f2fe8b892a 100644 --- a/forge-gui/res/cardsfolder/p/phantom_carriage.txt +++ b/forge-gui/res/cardsfolder/p/phantom_carriage.txt @@ -4,5 +4,5 @@ Types:Creature Spirit PT:4/4 K:Flying T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ PhantomSearch | TriggerDescription$ When CARDNAME enters the battlefield, you may search your library for a card with flashback or disturb, put it into your graveyard, then shuffle. -SVar:PhantomSearch:DB$ ChangeZone | Origin$ Library | Destination$ Graveyard | ChangeNum$ 1 | ChangeType$ Card.withFlashback+YouOwn,Card.withDisturb+YouOwn +SVar:PhantomSearch:DB$ ChangeZone | Origin$ Library | Destination$ Graveyard | ChangeNum$ 1 | ChangeType$ Card.hasKeywordFlashback+YouOwn,Card.withDisturb+YouOwn Oracle:Flying\nWhen Phantom Carriage enters the battlefield, you may search your library for a card with flashback or disturb, put it into your graveyard, then shuffle. diff --git a/forge-gui/res/cardsfolder/q/quiet_speculation.txt b/forge-gui/res/cardsfolder/q/quiet_speculation.txt index bb7341111db..a0dc17be3ae 100644 --- a/forge-gui/res/cardsfolder/q/quiet_speculation.txt +++ b/forge-gui/res/cardsfolder/q/quiet_speculation.txt @@ -1,6 +1,6 @@ Name:Quiet Speculation ManaCost:1 U Types:Sorcery -A:SP$ ChangeZone | Cost$ 1 U | Origin$ Library | Destination$ Graveyard | ValidTgts$ Player | ChangeType$ Card.withFlashback | ChangeNum$ 3 | SpellDescription$ Search target player's library for up to three cards with flashback and put them into that player's graveyard. Then the player shuffles. +A:SP$ ChangeZone | Cost$ 1 U | Origin$ Library | Destination$ Graveyard | ValidTgts$ Player | ChangeType$ Card.hasKeywordFlashback | ChangeNum$ 3 | SpellDescription$ Search target player's library for up to three cards with flashback and put them into that player's graveyard. Then the player shuffles. AI:RemoveDeck:All Oracle:Search target player's library for up to three cards with flashback and put them into that player's graveyard. Then the player shuffles. diff --git a/forge-gui/res/cardsfolder/r/rootcoil_creeper.txt b/forge-gui/res/cardsfolder/r/rootcoil_creeper.txt index 14c2f9dbd74..ea9d5dcd26b 100644 --- a/forge-gui/res/cardsfolder/r/rootcoil_creeper.txt +++ b/forge-gui/res/cardsfolder/r/rootcoil_creeper.txt @@ -4,6 +4,6 @@ Types:Creature Plant Horror PT:2/2 A:AB$ Mana | Cost$ T | Produced$ Any | SpellDescription$ Add one mana of any color. A:AB$ Mana | Cost$ T | Produced$ Any | Amount$ 2 | RestrictValid$ Spell.wasCastFromYourGraveyard | SpellDescription$ Add two mana of any one color. Spend this mana only to cast spells from your graveyard. -A:AB$ ChangeZone | Cost$ G U T Exile<1/CARDNAME> | Origin$ Exile | Destination$ Hand | ValidTgts$ Card.withFlashback+YouOwn | TgtPrompt$ Select target card with flashback you own in exile | SpellDescription$ Return target card with flashback you own in exile to your hand. +A:AB$ ChangeZone | Cost$ G U T Exile<1/CARDNAME> | Origin$ Exile | Destination$ Hand | ValidTgts$ Card.hasKeywordFlashback+YouOwn | TgtPrompt$ Select target card with flashback you own in exile | SpellDescription$ Return target card with flashback you own in exile to your hand. DeckHints:Ability$Graveyard & Keyword$Flashback Oracle:{T}: Add one mana of any color.\n{T}: Add two mana of any one color. Spend this mana only to cast spells from your graveyard.\n{G}{U}, {T}, Exile Rootcoil Creeper: Return target card with flashback you own in exile to your hand. diff --git a/forge-gui/res/cardsfolder/r/runic_repetition.txt b/forge-gui/res/cardsfolder/r/runic_repetition.txt index 8e11928b800..4a08c6281c1 100644 --- a/forge-gui/res/cardsfolder/r/runic_repetition.txt +++ b/forge-gui/res/cardsfolder/r/runic_repetition.txt @@ -1,6 +1,6 @@ Name:Runic Repetition ManaCost:2 U Types:Sorcery -A:SP$ ChangeZone | Cost$ 2 U | Origin$ Exile | Destination$ Hand | TgtPrompt$ Select target exiled card with flashback you own | ValidTgts$ Card.YouOwn+withFlashback | SpellDescription$ Return target exiled card with flashback you own to your hand. +A:SP$ ChangeZone | Cost$ 2 U | Origin$ Exile | Destination$ Hand | TgtPrompt$ Select target exiled card with flashback you own | ValidTgts$ Card.YouOwn+hasKeywordFlashback | SpellDescription$ Return target exiled card with flashback you own to your hand. AI:RemoveDeck:Random Oracle:Return target exiled card with flashback you own to your hand. diff --git a/forge-gui/res/cardsfolder/rebalanced/a-phantom_carriage.txt b/forge-gui/res/cardsfolder/rebalanced/a-phantom_carriage.txt index b0fb1da9c20..69b3f3e9cb7 100644 --- a/forge-gui/res/cardsfolder/rebalanced/a-phantom_carriage.txt +++ b/forge-gui/res/cardsfolder/rebalanced/a-phantom_carriage.txt @@ -4,5 +4,5 @@ Types:Creature Spirit PT:4/4 K:Flying T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ PhantomSearch | TriggerDescription$ When CARDNAME enters the battlefield, you may search your library for a card with flashback or disturb, put it into your graveyard, then shuffle. -SVar:PhantomSearch:DB$ ChangeZone | Origin$ Library | Destination$ Graveyard | ChangeNum$ 1 | ChangeType$ Card.withFlashback+YouOwn,Card.withDisturb+YouOwn +SVar:PhantomSearch:DB$ ChangeZone | Origin$ Library | Destination$ Graveyard | ChangeNum$ 1 | ChangeType$ Card.hasKeywordFlashback+YouOwn,Card.withDisturb+YouOwn Oracle:Flying\nWhen Phantom Carriage enters the battlefield, you may search your library for a card with flashback or disturb, put it into your graveyard, then shuffle. diff --git a/forge-gui/res/cardsfolder/t/tombfire.txt b/forge-gui/res/cardsfolder/t/tombfire.txt index f0395070f30..62303d8d583 100644 --- a/forge-gui/res/cardsfolder/t/tombfire.txt +++ b/forge-gui/res/cardsfolder/t/tombfire.txt @@ -1,6 +1,6 @@ Name:Tombfire ManaCost:B Types:Sorcery -A:SP$ ChangeZoneAll | Cost$ B | ValidTgts$ Player | TgtPrompt$ Select target player | Origin$ Graveyard | Destination$ Exile | ChangeType$ Card.withFlashback | SpellDescription$ Target player exiles all cards with flashback from their graveyard. +A:SP$ ChangeZoneAll | Cost$ B | ValidTgts$ Player | TgtPrompt$ Select target player | Origin$ Graveyard | Destination$ Exile | ChangeType$ Card.hasKeywordFlashback | SpellDescription$ Target player exiles all cards with flashback from their graveyard. AI:RemoveDeck:Random Oracle:Target player exiles all cards with flashback from their graveyard.