diff --git a/Mage.Sets/src/mage/cards/a/ActOfAuthority.java b/Mage.Sets/src/mage/cards/a/ActOfAuthority.java index d288540ba90..ece46dd7974 100644 --- a/Mage.Sets/src/mage/cards/a/ActOfAuthority.java +++ b/Mage.Sets/src/mage/cards/a/ActOfAuthority.java @@ -89,6 +89,7 @@ class ActOfAuthorityGainControlEffect extends ContinuousEffectImpl { public ActOfAuthorityGainControlEffect(Duration duration, UUID controller) { super(duration, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); this.controller = controller; + this.staticText = "Gain control of {this}"; } private ActOfAuthorityGainControlEffect(final ActOfAuthorityGainControlEffect effect) { @@ -114,9 +115,4 @@ class ActOfAuthorityGainControlEffect extends ContinuousEffectImpl { return permanent.changeControllerId(controller, game, source); } - - @Override - public String getText(Mode mode) { - return "Gain control of {this}"; - } } diff --git a/Mage.Sets/src/mage/cards/a/AetherBurst.java b/Mage.Sets/src/mage/cards/a/AetherBurst.java index 93f54054468..6557751c6c6 100644 --- a/Mage.Sets/src/mage/cards/a/AetherBurst.java +++ b/Mage.Sets/src/mage/cards/a/AetherBurst.java @@ -27,7 +27,7 @@ public final class AetherBurst extends CardImpl { super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{U}"); // Return up to X target creatures to their owners' hands, where X is one plus the number of cards named Aether Burst in all graveyards as you cast Aether Burst. - this.getSpellAbility().addEffect(new DynamicReturnToHandTargetEffect()); + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect().setText("Return up to X target creatures to their owners' hands, where X is one plus the number of cards named Aether Burst in all graveyards as you cast Aether Burst")); this.getSpellAbility().addTarget(new DynamicTargetCreaturePermanent()); this.getSpellAbility().setTargetAdjuster(AetherBurstAdjuster.instance); } @@ -91,28 +91,3 @@ class DynamicTargetCreaturePermanent extends TargetPermanent { } } - -/** - * We extend ReturnToHandTargetEffect class just to override the rules. - */ -class DynamicReturnToHandTargetEffect extends ReturnToHandTargetEffect { - - public DynamicReturnToHandTargetEffect() { - super(); - } - - public DynamicReturnToHandTargetEffect(final DynamicReturnToHandTargetEffect effect) { - super(effect); - } - - @Override - public DynamicReturnToHandTargetEffect copy() { - return new DynamicReturnToHandTargetEffect(this); - } - - @Override - public String getText(Mode mode) { - return "Return up to X target creatures to their owners' hands, where X is one plus the number of cards named Aether Burst in all graveyards as you cast Aether Burst"; - } - -} diff --git a/Mage.Sets/src/mage/cards/a/AkroanHorse.java b/Mage.Sets/src/mage/cards/a/AkroanHorse.java index 2e741b5ea85..dc8dd9b9210 100644 --- a/Mage.Sets/src/mage/cards/a/AkroanHorse.java +++ b/Mage.Sets/src/mage/cards/a/AkroanHorse.java @@ -95,6 +95,7 @@ class AkroanHorseGainControlEffect extends ContinuousEffectImpl { public AkroanHorseGainControlEffect(Duration duration, UUID controller) { super(duration, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); this.controller = controller; + this.staticText = "Gain control of Akroan Horse"; } public AkroanHorseGainControlEffect(final AkroanHorseGainControlEffect effect) { @@ -122,11 +123,6 @@ class AkroanHorseGainControlEffect extends ContinuousEffectImpl { return permanent.changeControllerId(controller, game, source); } - - @Override - public String getText(Mode mode) { - return "Gain control of Akroan Horse"; - } } class AkroanHorseCreateTokenEffect extends OneShotEffect { diff --git a/Mage.Sets/src/mage/cards/a/AnZerrinRuins.java b/Mage.Sets/src/mage/cards/a/AnZerrinRuins.java index a28f9e225b2..14952d8b733 100644 --- a/Mage.Sets/src/mage/cards/a/AnZerrinRuins.java +++ b/Mage.Sets/src/mage/cards/a/AnZerrinRuins.java @@ -46,6 +46,7 @@ class AnZerrinRuinsDontUntapEffect extends DontUntapInControllersUntapStepAllEff public AnZerrinRuinsDontUntapEffect() { super(Duration.WhileOnBattlefield, TargetController.ANY, new FilterCreaturePermanent()); + this.staticText = "Creatures of the chosen type don't untap during their controllers' untap steps"; } public AnZerrinRuinsDontUntapEffect(final AnZerrinRuinsDontUntapEffect effect) { @@ -69,9 +70,4 @@ class AnZerrinRuinsDontUntapEffect extends DontUntapInControllersUntapStepAllEff } return false; } - - @Override - public String getText(Mode mode) { - return "Creatures of the chosen type don't untap during their controllers' untap steps"; - } } diff --git a/Mage.Sets/src/mage/cards/a/AncientRunes.java b/Mage.Sets/src/mage/cards/a/AncientRunes.java index 624a3171d31..7b3ea494662 100644 --- a/Mage.Sets/src/mage/cards/a/AncientRunes.java +++ b/Mage.Sets/src/mage/cards/a/AncientRunes.java @@ -42,17 +42,13 @@ class AncientRunesDamageTargetEffect extends OneShotEffect { public AncientRunesDamageTargetEffect() { super(Outcome.Damage); + this.staticText = "{this} deals damage to that player equal to the number of artifacts they control"; } public AncientRunesDamageTargetEffect(AncientRunesDamageTargetEffect copy) { super(copy); } - @Override - public String getText(Mode mode) { - return "{this} deals damage to that player equal to the number of artifacts they control"; - } - @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(targetPointer.getFirst(game, source)); diff --git a/Mage.Sets/src/mage/cards/a/AwakenerDruid.java b/Mage.Sets/src/mage/cards/a/AwakenerDruid.java index 825cd5d7c8e..b343bf81c21 100644 --- a/Mage.Sets/src/mage/cards/a/AwakenerDruid.java +++ b/Mage.Sets/src/mage/cards/a/AwakenerDruid.java @@ -54,6 +54,7 @@ class AwakenerDruidBecomesCreatureEffect extends BecomesCreatureTargetEffect { public AwakenerDruidBecomesCreatureEffect() { super(new AwakenerDruidToken(), false, true, Duration.WhileOnBattlefield); + this.staticText = "target Forest becomes a 4/5 green Treefolk creature for as long as {this} remains on the battlefield. It's still a land"; } public AwakenerDruidBecomesCreatureEffect(final AwakenerDruidBecomesCreatureEffect effect) { @@ -74,11 +75,6 @@ class AwakenerDruidBecomesCreatureEffect extends BecomesCreatureTargetEffect { } return super.apply(layer, sublayer, source, game); } - - @Override - public String getText(Mode mode) { - return "target Forest becomes a 4/5 green Treefolk creature for as long as {this} remains on the battlefield. It's still a land"; - } } class AwakenerDruidToken extends TokenImpl { diff --git a/Mage.Sets/src/mage/cards/b/BanewaspAffliction.java b/Mage.Sets/src/mage/cards/b/BanewaspAffliction.java index 8fa21d533f4..8fb9815a456 100644 --- a/Mage.Sets/src/mage/cards/b/BanewaspAffliction.java +++ b/Mage.Sets/src/mage/cards/b/BanewaspAffliction.java @@ -56,6 +56,7 @@ class BanewaspAfflictionLoseLifeEffect extends OneShotEffect { public BanewaspAfflictionLoseLifeEffect() { super(Outcome.LoseLife); + this.staticText = "that creature's controller loses life equal to its toughness"; } public BanewaspAfflictionLoseLifeEffect(BanewaspAfflictionLoseLifeEffect copy) { @@ -80,10 +81,4 @@ class BanewaspAfflictionLoseLifeEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "that creature's controller loses life equal to its toughness"; - } - } diff --git a/Mage.Sets/src/mage/cards/c/CartoucheOfStrength.java b/Mage.Sets/src/mage/cards/c/CartoucheOfStrength.java index d89bff5cb90..753feadaddc 100644 --- a/Mage.Sets/src/mage/cards/c/CartoucheOfStrength.java +++ b/Mage.Sets/src/mage/cards/c/CartoucheOfStrength.java @@ -69,8 +69,11 @@ public final class CartoucheOfStrength extends CardImpl { * @author stravant */ class FightEnchantedTargetEffect extends OneShotEffect { + public FightEnchantedTargetEffect() { super(Outcome.Damage); + this.staticText = "you may have enchanted creature fight target creature an opponent controls. " + + "(Each deals damage equal to its power to the other.)"; } public FightEnchantedTargetEffect(final FightEnchantedTargetEffect effect) { @@ -105,11 +108,4 @@ class FightEnchantedTargetEffect extends OneShotEffect { public FightEnchantedTargetEffect copy() { return new FightEnchantedTargetEffect(this); } - - @Override - public String getText(Mode mode) { - return "you may have enchanted creature fight target creature an opponent controls. " + - "(Each deals damage equal to its power to the other.)"; - } - } \ No newline at end of file diff --git a/Mage.Sets/src/mage/cards/c/ChainOfSilence.java b/Mage.Sets/src/mage/cards/c/ChainOfSilence.java index d6112076c97..1e08583244b 100644 --- a/Mage.Sets/src/mage/cards/c/ChainOfSilence.java +++ b/Mage.Sets/src/mage/cards/c/ChainOfSilence.java @@ -50,6 +50,7 @@ class ChainOfSilenceEffect extends OneShotEffect { public ChainOfSilenceEffect() { super(Outcome.PreventDamage); + this.staticText = "Prevent all damage target creature would deal this turn. That creature's controller may sacrifice a land. If the player does, they may copy this spell and may choose a new target for that copy"; } public ChainOfSilenceEffect(final ChainOfSilenceEffect effect) { @@ -90,10 +91,4 @@ class ChainOfSilenceEffect extends OneShotEffect { return false; } - - @Override - public String getText(Mode mode) { - return "Prevent all damage target creature would deal this turn. That creature's controller may sacrifice a land. If the player does, they may copy this spell and may choose a new target for that copy"; - } - } diff --git a/Mage.Sets/src/mage/cards/c/ChainOfVapor.java b/Mage.Sets/src/mage/cards/c/ChainOfVapor.java index 908da1164f4..4688b136cf8 100644 --- a/Mage.Sets/src/mage/cards/c/ChainOfVapor.java +++ b/Mage.Sets/src/mage/cards/c/ChainOfVapor.java @@ -47,6 +47,7 @@ class ChainOfVaporEffect extends OneShotEffect { public ChainOfVaporEffect() { super(Outcome.ReturnToHand); + this.staticText = "Return target nonland permanent to its owner's hand. Then that permanent's controller may sacrifice a land. If the player does, they may copy this spell and may choose a new target for that copy"; } public ChainOfVaporEffect(final ChainOfVaporEffect effect) { @@ -86,10 +87,4 @@ class ChainOfVaporEffect extends OneShotEffect { return false; } - - @Override - public String getText(Mode mode) { - return "Return target nonland permanent to its owner's hand. Then that permanent's controller may sacrifice a land. If the player does, they may copy this spell and may choose a new target for that copy"; - } - } diff --git a/Mage.Sets/src/mage/cards/c/ChainStasis.java b/Mage.Sets/src/mage/cards/c/ChainStasis.java index b6267743afa..b1af86d837a 100644 --- a/Mage.Sets/src/mage/cards/c/ChainStasis.java +++ b/Mage.Sets/src/mage/cards/c/ChainStasis.java @@ -49,6 +49,7 @@ class ChainStasisEffect extends OneShotEffect { public ChainStasisEffect() { super(Outcome.Benefit); + this.staticText = "You may tap or untap target creature. Then that creature's controller may pay {2}{U}. If the player does, they may copy this spell and may choose a new target for that copy"; } public ChainStasisEffect(final ChainStasisEffect effect) { @@ -90,11 +91,4 @@ class ChainStasisEffect extends OneShotEffect { return false; } - - @Override - public String getText(Mode mode - ) { - return "You may tap or untap target creature. Then that creature's controller may pay {2}{U}. If the player does, they may copy this spell and may choose a new target for that copy"; - } - } diff --git a/Mage.Sets/src/mage/cards/c/Chastise.java b/Mage.Sets/src/mage/cards/c/Chastise.java index 9a70b50d93a..6559f57a68d 100644 --- a/Mage.Sets/src/mage/cards/c/Chastise.java +++ b/Mage.Sets/src/mage/cards/c/Chastise.java @@ -45,6 +45,7 @@ class ChastiseEffect extends OneShotEffect { public ChastiseEffect() { super(Outcome.GainLife); + this.staticText = "You gain life equal to its power"; } public ChastiseEffect(final ChastiseEffect effect) { @@ -69,9 +70,4 @@ class ChastiseEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "You gain life equal to its power"; - } } diff --git a/Mage.Sets/src/mage/cards/c/CitadelOfPain.java b/Mage.Sets/src/mage/cards/c/CitadelOfPain.java index ae1e15e5c31..5597a0f0d7f 100644 --- a/Mage.Sets/src/mage/cards/c/CitadelOfPain.java +++ b/Mage.Sets/src/mage/cards/c/CitadelOfPain.java @@ -54,6 +54,7 @@ class CitadelOfPainEffect extends OneShotEffect { public CitadelOfPainEffect() { super(Outcome.Damage); + this.staticText = "{this} deals X damage to that player, where X is the number of untapped lands they control."; } private CitadelOfPainEffect(final CitadelOfPainEffect effect) { @@ -75,9 +76,4 @@ class CitadelOfPainEffect extends OneShotEffect { public CitadelOfPainEffect copy() { return new CitadelOfPainEffect(this); } - - @Override - public String getText(Mode mode) { - return "{this} deals X damage to that player, where X is the number of untapped lands they control."; - } } \ No newline at end of file diff --git a/Mage.Sets/src/mage/cards/c/CloakingDevice.java b/Mage.Sets/src/mage/cards/c/CloakingDevice.java index 5389250b1c9..a195126ad5b 100644 --- a/Mage.Sets/src/mage/cards/c/CloakingDevice.java +++ b/Mage.Sets/src/mage/cards/c/CloakingDevice.java @@ -45,7 +45,7 @@ public final class CloakingDevice extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedAttachedEffect(AttachmentType.AURA))); // Whenever enchanted creature attacks, defending player loses 1 life. - this.addAbility(new AttacksAttachedTriggeredAbility(new CloakingDeviceLoseLifeDefendingPlayerEffect(1, true), AttachmentType.AURA, false)); + this.addAbility(new AttacksAttachedTriggeredAbility(new CloakingDeviceLoseLifeDefendingPlayerEffect(), AttachmentType.AURA, false)); } @@ -61,29 +61,13 @@ public final class CloakingDevice extends CardImpl { class CloakingDeviceLoseLifeDefendingPlayerEffect extends OneShotEffect { - private DynamicValue amount; - private boolean attackerIsSource; - - /** - * - * @param amount - * @param attackerIsSource true if the source.getSourceId() contains the - * attacker false if attacker has to be taken from targetPointer - */ - public CloakingDeviceLoseLifeDefendingPlayerEffect(int amount, boolean attackerIsSource) { - this(StaticValue.get(amount), attackerIsSource); - } - - public CloakingDeviceLoseLifeDefendingPlayerEffect(DynamicValue amount, boolean attackerIsSource) { + public CloakingDeviceLoseLifeDefendingPlayerEffect() { super(Outcome.Damage); - this.amount = amount; - this.attackerIsSource = attackerIsSource; + this.staticText = "defending player loses 1 life"; } public CloakingDeviceLoseLifeDefendingPlayerEffect(final CloakingDeviceLoseLifeDefendingPlayerEffect effect) { super(effect); - this.amount = effect.amount.copy(); - this.attackerIsSource = effect.attackerIsSource; } @Override @@ -102,15 +86,9 @@ class CloakingDeviceLoseLifeDefendingPlayerEffect extends OneShotEffect { if (enchantment != null && enchantment.getAttachedTo() != null) { Player defender = game.getPlayer(game.getCombat().getDefendingPlayerId(enchantment.getAttachedTo(), game)); if (defender != null) { - defender.loseLife(amount.calculate(game, source, this), game, source, false); + defender.loseLife(1, game, source, false); } } return true; } - - @Override - public String getText(Mode mode) { - return "defending player loses " + amount + " life"; - } - } diff --git a/Mage.Sets/src/mage/cards/c/ColdSnap.java b/Mage.Sets/src/mage/cards/c/ColdSnap.java index 102cc5a0cc4..ba51cbbd3de 100644 --- a/Mage.Sets/src/mage/cards/c/ColdSnap.java +++ b/Mage.Sets/src/mage/cards/c/ColdSnap.java @@ -50,17 +50,13 @@ class ColdSnapDamageTargetEffect extends OneShotEffect { public ColdSnapDamageTargetEffect() { super(Outcome.Damage); + this.staticText = "{this} deals damage to that player equal to the number of snow lands they control"; } public ColdSnapDamageTargetEffect(ColdSnapDamageTargetEffect copy) { super(copy); } - @Override - public String getText(Mode mode) { - return "{this} deals damage to that player equal to the number of snow lands they control"; - } - @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(targetPointer.getFirst(game, source)); diff --git a/Mage.Sets/src/mage/cards/c/ContestedWarZone.java b/Mage.Sets/src/mage/cards/c/ContestedWarZone.java index 81f3372220e..e2257c32579 100644 --- a/Mage.Sets/src/mage/cards/c/ContestedWarZone.java +++ b/Mage.Sets/src/mage/cards/c/ContestedWarZone.java @@ -95,6 +95,7 @@ class ContestedWarZoneEffect extends ContinuousEffectImpl { public ContestedWarZoneEffect() { super(Duration.Custom, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); + this.staticText = "Gain control of {this}"; } public ContestedWarZoneEffect(final ContestedWarZoneEffect effect) { @@ -117,9 +118,4 @@ class ContestedWarZoneEffect extends ContinuousEffectImpl { } return false; } - - @Override - public String getText(Mode mode) { - return "Gain control of {this}"; - } } diff --git a/Mage.Sets/src/mage/cards/c/CranialExtraction.java b/Mage.Sets/src/mage/cards/c/CranialExtraction.java index c858222855e..cc66310f1f4 100644 --- a/Mage.Sets/src/mage/cards/c/CranialExtraction.java +++ b/Mage.Sets/src/mage/cards/c/CranialExtraction.java @@ -24,7 +24,7 @@ public final class CranialExtraction extends CardImpl { super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{3}{B}"); this.subtype.add(SubType.ARCANE); - /* Name a nonland card. Search target player's graveyard, hand, and library for + /* Choose a nonland card. Search target player's graveyard, hand, and library for * all cards with that name and exile them. Then that player shuffles their library. */ this.getSpellAbility().addTarget(new TargetPlayer()); this.getSpellAbility().addEffect(new CranialExtractionEffect()); @@ -44,6 +44,7 @@ class CranialExtractionEffect extends SearchTargetGraveyardHandLibraryForCardNam CranialExtractionEffect() { super(false, "target player's", "all cards with that name"); + this.staticText = "Choose a nonland card name. " + CardUtil.getTextWithFirstCharUpperCase(this.staticText); } CranialExtractionEffect(final CranialExtractionEffect effect) { @@ -68,9 +69,4 @@ class CranialExtractionEffect extends SearchTargetGraveyardHandLibraryForCardNam public CranialExtractionEffect copy() { return new CranialExtractionEffect(this); } - - @Override - public String getText(Mode mode) { - return "Choose a nonland card name. " + CardUtil.getTextWithFirstCharUpperCase(super.getText(mode)); - } } diff --git a/Mage.Sets/src/mage/cards/c/CrimsonHonorGuard.java b/Mage.Sets/src/mage/cards/c/CrimsonHonorGuard.java index 9e4ef9f7b5b..74d3793f1ad 100644 --- a/Mage.Sets/src/mage/cards/c/CrimsonHonorGuard.java +++ b/Mage.Sets/src/mage/cards/c/CrimsonHonorGuard.java @@ -13,6 +13,7 @@ import mage.constants.Outcome; import mage.constants.SubType; import mage.constants.TargetController; import mage.filter.FilterPermanent; +import mage.filter.StaticFilters; import mage.filter.predicate.mageobject.CommanderPredicate; import mage.game.Game; import mage.players.Player; @@ -59,6 +60,7 @@ class CrimsonHonorGuardEffect extends OneShotEffect { public CrimsonHonorGuardEffect() { super(Outcome.Damage); + this.staticText = "{this} deals 4 damage to that player unless they control a commander"; } private CrimsonHonorGuardEffect(final CrimsonHonorGuardEffect effect) { @@ -78,11 +80,6 @@ class CrimsonHonorGuardEffect extends OneShotEffect { return false; } - @Override - public String getText(Mode mode) { - return "{this} deals 4 damage to that player unless they control a commander"; - } - @Override public CrimsonHonorGuardEffect copy() { return new CrimsonHonorGuardEffect(this); diff --git a/Mage.Sets/src/mage/cards/c/CrownOfEmpires.java b/Mage.Sets/src/mage/cards/c/CrownOfEmpires.java index 2c4352820ec..52d6c1d798d 100644 --- a/Mage.Sets/src/mage/cards/c/CrownOfEmpires.java +++ b/Mage.Sets/src/mage/cards/c/CrownOfEmpires.java @@ -89,6 +89,7 @@ class CrownOfEmpiresControlEffect extends ContinuousEffectImpl { public CrownOfEmpiresControlEffect() { super(Duration.EndOfGame, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); + this.staticText = "Gain control of {this}"; } public CrownOfEmpiresControlEffect(final CrownOfEmpiresControlEffect effect) { @@ -109,9 +110,4 @@ class CrownOfEmpiresControlEffect extends ContinuousEffectImpl { } return false; } - - @Override - public String getText(Mode mode) { - return "Gain control of {this}"; - } } diff --git a/Mage.Sets/src/mage/cards/d/Deicide.java b/Mage.Sets/src/mage/cards/d/Deicide.java index 3a104ea0271..47c8948feab 100644 --- a/Mage.Sets/src/mage/cards/d/Deicide.java +++ b/Mage.Sets/src/mage/cards/d/Deicide.java @@ -43,6 +43,7 @@ class DeicideExileEffect extends SearchTargetGraveyardHandLibraryForCardNameAndE DeicideExileEffect() { super(true, "its controller's", "any number of cards with the same name as that card"); + this.staticText = "Exile target enchantment. If the exiled card is a God card, " + this.staticText; } private DeicideExileEffect(final DeicideExileEffect effect) { @@ -77,9 +78,4 @@ class DeicideExileEffect extends SearchTargetGraveyardHandLibraryForCardNameAndE public DeicideExileEffect copy() { return new DeicideExileEffect(this); } - - @Override - public String getText(Mode mode) { - return "Exile target enchantment. If the exiled card is a God card, " + super.getText(mode); - } } diff --git a/Mage.Sets/src/mage/cards/d/DimirCharm.java b/Mage.Sets/src/mage/cards/d/DimirCharm.java index 353f09eeed2..e99ac87293c 100644 --- a/Mage.Sets/src/mage/cards/d/DimirCharm.java +++ b/Mage.Sets/src/mage/cards/d/DimirCharm.java @@ -69,6 +69,7 @@ class DimirCharmEffect extends OneShotEffect { public DimirCharmEffect() { super(Outcome.Benefit); + this.staticText = "look at the top three cards of target player's library, then put one back and the rest into that player's graveyard"; } public DimirCharmEffect(final DimirCharmEffect effect) { @@ -100,9 +101,4 @@ class DimirCharmEffect extends OneShotEffect { public DimirCharmEffect copy() { return new DimirCharmEffect(this); } - - @Override - public String getText(Mode mode) { - return "look at the top three cards of target player's library, then put one back and the rest into that player's graveyard"; - } } diff --git a/Mage.Sets/src/mage/cards/d/DismissIntoDream.java b/Mage.Sets/src/mage/cards/d/DismissIntoDream.java index 0ad5d839162..e183b38684e 100644 --- a/Mage.Sets/src/mage/cards/d/DismissIntoDream.java +++ b/Mage.Sets/src/mage/cards/d/DismissIntoDream.java @@ -30,7 +30,6 @@ public final class DismissIntoDream extends CardImpl { public DismissIntoDream(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{6}{U}"); - // Each creature your opponents control is an Illusion in addition to its other types // and has "When this creature becomes the target of a spell or ability, sacrifice it." this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DismissIntoDreamEffect(filter))); @@ -51,6 +50,7 @@ class DismissIntoDreamEffect extends CreaturesBecomeOtherTypeEffect { DismissIntoDreamEffect(FilterPermanent filter) { super(filter, SubType.ILLUSION, Duration.WhileOnBattlefield); this.outcome = Outcome.Detriment; + this.staticText = this.staticText + " and has \"When this creature becomes the target of a spell or ability, sacrifice it.\""; } DismissIntoDreamEffect(final DismissIntoDreamEffect effect) { @@ -84,9 +84,4 @@ class DismissIntoDreamEffect extends CreaturesBecomeOtherTypeEffect { public boolean hasLayer(Layer layer) { return super.hasLayer(layer) || layer == Layer.AbilityAddingRemovingEffects_6; } - - @Override - public String getText(Mode mode) { - return super.getText(mode) + " and has \"When this creature becomes the target of a spell or ability, sacrifice it.\""; - } } diff --git a/Mage.Sets/src/mage/cards/d/DisruptingShoal.java b/Mage.Sets/src/mage/cards/d/DisruptingShoal.java index fc6d2df5859..f027591394b 100644 --- a/Mage.Sets/src/mage/cards/d/DisruptingShoal.java +++ b/Mage.Sets/src/mage/cards/d/DisruptingShoal.java @@ -63,6 +63,7 @@ class DisruptingShoalCounterTargetEffect extends OneShotEffect { public DisruptingShoalCounterTargetEffect() { super(Outcome.Detriment); + this.staticText = "Counter target spell if its mana value is X"; } public DisruptingShoalCounterTargetEffect(final DisruptingShoalCounterTargetEffect effect) { @@ -95,9 +96,4 @@ class DisruptingShoalCounterTargetEffect extends OneShotEffect { // No alternate costs payed so compare to X value return sourceAbility.getManaCostsToPay().getX() == amount; } - - @Override - public String getText(Mode mode) { - return "Counter target spell if its mana value is X"; - } } diff --git a/Mage.Sets/src/mage/cards/d/Duplicant.java b/Mage.Sets/src/mage/cards/d/Duplicant.java index 71d063e5453..6ed77be88de 100644 --- a/Mage.Sets/src/mage/cards/d/Duplicant.java +++ b/Mage.Sets/src/mage/cards/d/Duplicant.java @@ -62,6 +62,7 @@ class DuplicantExileTargetEffect extends OneShotEffect { public DuplicantExileTargetEffect() { super(Outcome.Exile); + this.staticText = "you may exile target nontoken creature"; } public DuplicantExileTargetEffect(final DuplicantExileTargetEffect effect) { @@ -87,11 +88,6 @@ class DuplicantExileTargetEffect extends OneShotEffect { return false; } - - @Override - public String getText(Mode mode) { - return "you may exile target nontoken creature"; - } } class DuplicantContinuousEffect extends ContinuousEffectImpl { diff --git a/Mage.Sets/src/mage/cards/d/DustOfMoments.java b/Mage.Sets/src/mage/cards/d/DustOfMoments.java index bae8372b21e..3de21424f05 100644 --- a/Mage.Sets/src/mage/cards/d/DustOfMoments.java +++ b/Mage.Sets/src/mage/cards/d/DustOfMoments.java @@ -49,6 +49,12 @@ class DustOfMomentsEffect extends OneShotEffect { DustOfMomentsEffect(boolean remove) { super(Outcome.Benefit); this.remove = remove; + this.staticText = (remove ? "remove" : "put") + + " two time counters " + + (remove ? "from" : "on") + + " each permanent" + + (remove ? "" : "with a time counter on it") + + " and each suspended card"; } private DustOfMomentsEffect(final DustOfMomentsEffect effect) { @@ -82,17 +88,4 @@ class DustOfMomentsEffect extends OneShotEffect { } return true; } - - @Override - public String getText(Mode mode) { - StringBuilder sb = new StringBuilder(remove ? "remove" : "put"); - sb.append(" two time counters "); - sb.append(remove ? "from" : "on"); - sb.append(" each permanent"); - if (!remove) { - sb.append("with a time counter on it"); - } - sb.append(" and each suspended card"); - return sb.toString(); - } } diff --git a/Mage.Sets/src/mage/cards/e/EchoingTruth.java b/Mage.Sets/src/mage/cards/e/EchoingTruth.java index 3babebde4ff..96d30d3d637 100644 --- a/Mage.Sets/src/mage/cards/e/EchoingTruth.java +++ b/Mage.Sets/src/mage/cards/e/EchoingTruth.java @@ -50,6 +50,7 @@ class ReturnToHandAllNamedPermanentsEffect extends OneShotEffect { public ReturnToHandAllNamedPermanentsEffect() { super(Outcome.ReturnToHand); + this.staticText = "Return target nonland permanent and all other permanents with the same name as that permanent to their owners' hands"; } public ReturnToHandAllNamedPermanentsEffect(final ReturnToHandAllNamedPermanentsEffect effect) { @@ -81,10 +82,4 @@ class ReturnToHandAllNamedPermanentsEffect extends OneShotEffect { } return true; } - - @Override - public String getText(Mode mode) { - return "Return target nonland permanent and all other permanents with the same name as that permanent to their owners' hands"; - } - } diff --git a/Mage.Sets/src/mage/cards/f/FickleEfreet.java b/Mage.Sets/src/mage/cards/f/FickleEfreet.java index b7fa0c2d222..c10d8378766 100644 --- a/Mage.Sets/src/mage/cards/f/FickleEfreet.java +++ b/Mage.Sets/src/mage/cards/f/FickleEfreet.java @@ -99,6 +99,7 @@ class FickleEfreetGainControlEffect extends ContinuousEffectImpl { public FickleEfreetGainControlEffect(Duration duration, UUID controller) { super(duration, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); this.controller = controller; + this.staticText = "That player gains control of {this}"; } public FickleEfreetGainControlEffect(final FickleEfreetGainControlEffect effect) { @@ -122,9 +123,4 @@ class FickleEfreetGainControlEffect extends ContinuousEffectImpl { } return false; } - - @Override - public String getText(Mode mode) { - return "That player gains control of {this}"; - } } diff --git a/Mage.Sets/src/mage/cards/f/FruitOfTheFirstTree.java b/Mage.Sets/src/mage/cards/f/FruitOfTheFirstTree.java index f324d19b22f..01b4f8795ba 100644 --- a/Mage.Sets/src/mage/cards/f/FruitOfTheFirstTree.java +++ b/Mage.Sets/src/mage/cards/f/FruitOfTheFirstTree.java @@ -54,6 +54,7 @@ class FruitOfTheFirstTreeEffect extends OneShotEffect { public FruitOfTheFirstTreeEffect() { super(Outcome.Benefit); + this.staticText = "you gain X life and draw X cards, where X is its toughness"; } public FruitOfTheFirstTreeEffect(FruitOfTheFirstTreeEffect copy) { @@ -76,10 +77,4 @@ class FruitOfTheFirstTreeEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "you gain X life and draw X cards, where X is its toughness"; - } - } diff --git a/Mage.Sets/src/mage/cards/g/GoblinArchaeologist.java b/Mage.Sets/src/mage/cards/g/GoblinArchaeologist.java index dcc3c8c53ec..59480da7be8 100644 --- a/Mage.Sets/src/mage/cards/g/GoblinArchaeologist.java +++ b/Mage.Sets/src/mage/cards/g/GoblinArchaeologist.java @@ -54,6 +54,7 @@ class GoblinArchaeologistEffect extends OneShotEffect { public GoblinArchaeologistEffect() { super(Outcome.DestroyPermanent); + this.staticText = "Flip a coin. If you win the flip, destroy target artifact and untap {this}. If you lose the flip, sacrifice {this}"; } public GoblinArchaeologistEffect(final GoblinArchaeologistEffect ability) { @@ -81,9 +82,4 @@ class GoblinArchaeologistEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "Flip a coin. If you win the flip, destroy target artifact and untap {this}. If you lose the flip, sacrifice {this}"; - } } diff --git a/Mage.Sets/src/mage/cards/g/GoblinFestival.java b/Mage.Sets/src/mage/cards/g/GoblinFestival.java index bd3cb48a565..023dcb4b178 100644 --- a/Mage.Sets/src/mage/cards/g/GoblinFestival.java +++ b/Mage.Sets/src/mage/cards/g/GoblinFestival.java @@ -98,6 +98,7 @@ class GoblinFestivalGainControlEffect extends ContinuousEffectImpl { public GoblinFestivalGainControlEffect(Duration duration, UUID controller) { super(duration, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); this.controller = controller; + this.staticText = "That player gains control of {this}"; } public GoblinFestivalGainControlEffect(final GoblinFestivalGainControlEffect effect) { @@ -121,9 +122,4 @@ class GoblinFestivalGainControlEffect extends ContinuousEffectImpl { } return false; } - - @Override - public String getText(Mode mode) { - return "That player gains control of {this}"; - } } diff --git a/Mage.Sets/src/mage/cards/h/Hammerheim.java b/Mage.Sets/src/mage/cards/h/Hammerheim.java index 0071b5d70b9..caa14605024 100644 --- a/Mage.Sets/src/mage/cards/h/Hammerheim.java +++ b/Mage.Sets/src/mage/cards/h/Hammerheim.java @@ -57,6 +57,7 @@ class HammerheimEffect extends ContinuousEffectImpl { public HammerheimEffect() { super(Duration.EndOfTurn, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.LoseAbility); + this.staticText = "Target creature loses all landwalk abilities until end of turn."; } public HammerheimEffect(final HammerheimEffect effect) { @@ -81,9 +82,4 @@ class HammerheimEffect extends ContinuousEffectImpl { } return true; } - - @Override - public String getText(Mode mode) { - return "Target creature loses all landwalk abilities until end of turn."; - } } diff --git a/Mage.Sets/src/mage/cards/h/HonorablePassage.java b/Mage.Sets/src/mage/cards/h/HonorablePassage.java index 2a105a635ea..ad2ecfef82f 100644 --- a/Mage.Sets/src/mage/cards/h/HonorablePassage.java +++ b/Mage.Sets/src/mage/cards/h/HonorablePassage.java @@ -43,6 +43,7 @@ class HonorablePassageEffect extends PreventNextDamageFromChosenSourceToTargetEf public HonorablePassageEffect() { super(Duration.EndOfTurn); + this.staticText = "The next time a source of your choice would deal damage to any target this turn, prevent that damage. If damage from a red source is prevented this way, {this} deals that much damage to the source's controller"; } public HonorablePassageEffect(final HonorablePassageEffect effect) { @@ -73,9 +74,4 @@ class HonorablePassageEffect extends PreventNextDamageFromChosenSourceToTargetEf } return false; } - - @Override - public String getText(Mode mode) { - return "The next time a source of your choice would deal damage to any target this turn, prevent that damage. If damage from a red source is prevented this way, {this} deals that much damage to the source's controller"; - } } diff --git a/Mage.Sets/src/mage/cards/h/HuatliWarriorPoet.java b/Mage.Sets/src/mage/cards/h/HuatliWarriorPoet.java index 3bc125fbce6..987e5b7e512 100644 --- a/Mage.Sets/src/mage/cards/h/HuatliWarriorPoet.java +++ b/Mage.Sets/src/mage/cards/h/HuatliWarriorPoet.java @@ -64,6 +64,7 @@ class HuatliWarriorPoetDamageEffect extends OneShotEffect { HuatliWarriorPoetDamageEffect() { super(Outcome.Damage); + this.staticText = "{this} deals X damage divided as you choose among any number of target creatures. Creatures dealt damage this way can't block this turn"; } private HuatliWarriorPoetDamageEffect(final HuatliWarriorPoetDamageEffect effect) { @@ -91,14 +92,4 @@ class HuatliWarriorPoetDamageEffect extends OneShotEffect { } return true; } - - @Override - public String getText(Mode mode) { - if (staticText != null && !staticText.isEmpty()) { - return staticText; - } - return "{this} deals X damage divided as you choose among any number of target " - + mode.getTargets().get(0).getTargetName() - + ". Creatures dealt damage this way can't block this turn"; - } } diff --git a/Mage.Sets/src/mage/cards/h/Hydroblast.java b/Mage.Sets/src/mage/cards/h/Hydroblast.java index 5c47c2e9204..df618f280e1 100644 --- a/Mage.Sets/src/mage/cards/h/Hydroblast.java +++ b/Mage.Sets/src/mage/cards/h/Hydroblast.java @@ -23,11 +23,10 @@ public final class Hydroblast extends CardImpl { public Hydroblast(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{U}"); - // Choose one - Counter target spell if it's red; this.getSpellAbility().addEffect(new HydroblastCounterEffect()); this.getSpellAbility().addTarget(new TargetSpell()); - + // or destroy target permanent if it's red. Mode mode = new Mode(new HydroblastDestroyEffect()); mode.addTarget(new TargetPermanent()); @@ -48,6 +47,7 @@ class HydroblastCounterEffect extends OneShotEffect { HydroblastCounterEffect() { super(Outcome.Detriment); + this.staticText = "Counter target spell if it's red"; } HydroblastCounterEffect(final HydroblastCounterEffect effect) { @@ -66,17 +66,13 @@ class HydroblastCounterEffect extends OneShotEffect { } return true; } - - @Override - public String getText(Mode mode) { - return "Counter target spell if it's red"; - } } class HydroblastDestroyEffect extends OneShotEffect { HydroblastDestroyEffect() { super(Outcome.DestroyPermanent); + this.staticText = "destroy target permanent if it's red"; } HydroblastDestroyEffect(final HydroblastDestroyEffect effect) { @@ -96,9 +92,4 @@ class HydroblastDestroyEffect extends OneShotEffect { } return true; } - - @Override - public String getText(Mode mode) { - return "destroy target permanent if it's red"; - } } diff --git a/Mage.Sets/src/mage/cards/i/InfiniteObliteration.java b/Mage.Sets/src/mage/cards/i/InfiniteObliteration.java index c4becf0fb3c..6b70832d073 100644 --- a/Mage.Sets/src/mage/cards/i/InfiniteObliteration.java +++ b/Mage.Sets/src/mage/cards/i/InfiniteObliteration.java @@ -10,6 +10,7 @@ import mage.constants.CardType; import mage.game.Game; import mage.players.Player; import mage.target.common.TargetOpponent; +import mage.util.CardUtil; import java.util.UUID; @@ -21,8 +22,8 @@ public final class InfiniteObliteration extends CardImpl { public InfiniteObliteration(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{B}{B}"); - // Name a creature card. Search target opponent's graveyard, hand, and library - // for any number of cards with that name and exile them. Then that player shuffles their library. + // Choose a creature card. Search target opponent's graveyard, hand, and library + // for any number of cards with that name and exile them. Then that player shuffles their library. this.getSpellAbility().addEffect(new InfiniteObliterationEffect()); this.getSpellAbility().addTarget(new TargetOpponent()); } @@ -41,6 +42,7 @@ class InfiniteObliterationEffect extends SearchTargetGraveyardHandLibraryForCard public InfiniteObliterationEffect() { super(true, "target opponent's", "any number of cards with that name"); + this.staticText = "Choose a creature card name. " + CardUtil.getTextWithFirstCharUpperCase(this.staticText); } public InfiniteObliterationEffect(final InfiniteObliterationEffect effect) { @@ -63,9 +65,4 @@ class InfiniteObliterationEffect extends SearchTargetGraveyardHandLibraryForCard public InfiniteObliterationEffect copy() { return new InfiniteObliterationEffect(this); } - - @Override - public String getText(Mode mode) { - return "Choose a creature card name. " + super.getText(mode); - } } diff --git a/Mage.Sets/src/mage/cards/i/InfiniteReflection.java b/Mage.Sets/src/mage/cards/i/InfiniteReflection.java index 7c5c6d6f0ef..2dbd65415a2 100644 --- a/Mage.Sets/src/mage/cards/i/InfiniteReflection.java +++ b/Mage.Sets/src/mage/cards/i/InfiniteReflection.java @@ -103,6 +103,7 @@ class InfiniteReflectionEntersBattlefieldEffect extends ReplacementEffectImpl { public InfiniteReflectionEntersBattlefieldEffect() { super(Duration.WhileOnBattlefield, Outcome.Benefit); + this.staticText = "Nontoken creatures you control enter the battlefield as a copy of enchanted creature"; } public InfiniteReflectionEntersBattlefieldEffect(InfiniteReflectionEntersBattlefieldEffect effect) { @@ -135,11 +136,6 @@ class InfiniteReflectionEntersBattlefieldEffect extends ReplacementEffectImpl { return false; } - @Override - public String getText(Mode mode) { - return "Nontoken creatures you control enter the battlefield as a copy of enchanted creature"; - } - @Override public InfiniteReflectionEntersBattlefieldEffect copy() { return new InfiniteReflectionEntersBattlefieldEffect(this); diff --git a/Mage.Sets/src/mage/cards/i/InvasiveSurgery.java b/Mage.Sets/src/mage/cards/i/InvasiveSurgery.java index a97f8d57b74..ab963051300 100644 --- a/Mage.Sets/src/mage/cards/i/InvasiveSurgery.java +++ b/Mage.Sets/src/mage/cards/i/InvasiveSurgery.java @@ -53,6 +53,10 @@ class InvasiveSurgeryEffect extends SearchTargetGraveyardHandLibraryForCardNameA public InvasiveSurgeryEffect() { super(true, "that spell's controller", "all cards with the same name as that spell"); + this.staticText = "Counter target sorcery spell.

" + + "Delirium — If there are four or more card types among cards in your graveyard, " + + "search the graveyard, hand, and library of that spell's controller for any number of cards " + + "with the same name as that spell, exile those cards, then that player shuffles"; } public InvasiveSurgeryEffect(final InvasiveSurgeryEffect effect) { @@ -91,12 +95,4 @@ class InvasiveSurgeryEffect extends SearchTargetGraveyardHandLibraryForCardNameA } return this.applySearchAndExile(game, source, cardName, spellController); } - - @Override - public String getText(Mode mode) { - return "Counter target sorcery spell.

" - + "Delirium — If there are four or more card types among cards in your graveyard, " - + "search the graveyard, hand, and library of that spell's controller for any number of cards " - + "with the same name as that spell, exile those cards, then that player shuffles"; - } } diff --git a/Mage.Sets/src/mage/cards/i/IronMaiden.java b/Mage.Sets/src/mage/cards/i/IronMaiden.java index f7106077a4d..cae9107d065 100644 --- a/Mage.Sets/src/mage/cards/i/IronMaiden.java +++ b/Mage.Sets/src/mage/cards/i/IronMaiden.java @@ -42,6 +42,7 @@ class IronMaidenEffect extends OneShotEffect { private IronMaidenEffect(final IronMaidenEffect effect) { super(effect); + this.staticText = "Iron Maiden deals X damage to that player, where X is the number of cards in their hand minus 4"; } public IronMaidenEffect() { @@ -65,10 +66,4 @@ class IronMaidenEffect extends OneShotEffect { public IronMaidenEffect copy() { return new IronMaidenEffect(this); } - - @Override - public String getText(Mode mode) { - return "Iron Maiden deals X damage to that player, where X is the number of cards in their hand minus 4"; - } - } diff --git a/Mage.Sets/src/mage/cards/j/JaceMemoryAdept.java b/Mage.Sets/src/mage/cards/j/JaceMemoryAdept.java index 04ab1c419a2..e8de742fd9e 100644 --- a/Mage.Sets/src/mage/cards/j/JaceMemoryAdept.java +++ b/Mage.Sets/src/mage/cards/j/JaceMemoryAdept.java @@ -78,11 +78,6 @@ class JaceMemoryAdeptEffect extends DrawCardTargetEffect { return true; } - @Override - public String getText(Mode mode) { - return staticText; - } - @Override public JaceMemoryAdeptEffect copy() { return new JaceMemoryAdeptEffect(this); diff --git a/Mage.Sets/src/mage/cards/j/JovensFerrets.java b/Mage.Sets/src/mage/cards/j/JovensFerrets.java index 653aad5159d..34166b4cc8b 100644 --- a/Mage.Sets/src/mage/cards/j/JovensFerrets.java +++ b/Mage.Sets/src/mage/cards/j/JovensFerrets.java @@ -63,6 +63,7 @@ class JovensFerretsEffect extends OneShotEffect { public JovensFerretsEffect() { super(Outcome.Benefit); + this.staticText = "tap all creatures that blocked {this} this turn. They don't untap during their controller's next untap step."; } public JovensFerretsEffect(final JovensFerretsEffect effect) { @@ -100,9 +101,4 @@ class JovensFerretsEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "tap all creatures that blocked {this} this turn. They don't untap during their controller's next untap step."; - } } \ No newline at end of file diff --git a/Mage.Sets/src/mage/cards/k/Karma.java b/Mage.Sets/src/mage/cards/k/Karma.java index a2ce89f52f0..004fd540bce 100644 --- a/Mage.Sets/src/mage/cards/k/Karma.java +++ b/Mage.Sets/src/mage/cards/k/Karma.java @@ -51,17 +51,13 @@ class KarmaDamageTargetEffect extends OneShotEffect { public KarmaDamageTargetEffect() { super(Outcome.Damage); + this.staticText = "{this} deals damage to that player equal to the number of Swamps they control"; } public KarmaDamageTargetEffect(KarmaDamageTargetEffect copy) { super(copy); } - @Override - public String getText(Mode mode) { - return "{this} deals damage to that player equal to the number of Swamps they control"; - } - @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(targetPointer.getFirst(game, source)); diff --git a/Mage.Sets/src/mage/cards/k/KyloRen.java b/Mage.Sets/src/mage/cards/k/KyloRen.java index cbf0b30d686..453797a62f1 100644 --- a/Mage.Sets/src/mage/cards/k/KyloRen.java +++ b/Mage.Sets/src/mage/cards/k/KyloRen.java @@ -78,6 +78,7 @@ class KyloRenTapTargetEffect extends TapTargetEffect { public KyloRenTapTargetEffect() { super(); + this.staticText = "and you may tap target creature defending player controls"; } public KyloRenTapTargetEffect(final KyloRenTapTargetEffect effect) { @@ -100,9 +101,4 @@ class KyloRenTapTargetEffect extends TapTargetEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "and you may tap target creature defending player controls"; - } } diff --git a/Mage.Sets/src/mage/cards/l/LeylineOfSingularity.java b/Mage.Sets/src/mage/cards/l/LeylineOfSingularity.java index 9b23e8d8652..141c4980ef7 100644 --- a/Mage.Sets/src/mage/cards/l/LeylineOfSingularity.java +++ b/Mage.Sets/src/mage/cards/l/LeylineOfSingularity.java @@ -46,6 +46,7 @@ class SetSupertypeAllEffect extends ContinuousEffectImpl { public SetSupertypeAllEffect() { super(Duration.WhileOnBattlefield, Layer.TypeChangingEffects_4, SubLayer.NA, Outcome.Detriment); + this.staticText = "All nonland permanents are legendary"; } public SetSupertypeAllEffect(final SetSupertypeAllEffect effect) { @@ -64,9 +65,4 @@ class SetSupertypeAllEffect extends ContinuousEffectImpl { } return true; } - - @Override - public String getText(Mode mode) { - return "All nonland permanents are legendary"; - } } diff --git a/Mage.Sets/src/mage/cards/l/LithoformEngine.java b/Mage.Sets/src/mage/cards/l/LithoformEngine.java index 32aef36c80f..3a259a0de6d 100644 --- a/Mage.Sets/src/mage/cards/l/LithoformEngine.java +++ b/Mage.Sets/src/mage/cards/l/LithoformEngine.java @@ -95,6 +95,7 @@ class LithoformEngineEffect extends OneShotEffect { public LithoformEngineEffect() { super(Outcome.Copy); + this.staticText = "Copy target activated or triggered ability you control. You may choose new targets for the copy"; } public LithoformEngineEffect(final LithoformEngineEffect effect) { @@ -120,9 +121,4 @@ class LithoformEngineEffect extends OneShotEffect { public LithoformEngineEffect copy() { return new LithoformEngineEffect(this); } - - @Override - public String getText(Mode mode) { - return "Copy target activated or triggered ability you control. You may choose new targets for the copy"; - } } diff --git a/Mage.Sets/src/mage/cards/l/LordXanderTheCollector.java b/Mage.Sets/src/mage/cards/l/LordXanderTheCollector.java index 6dea96c00bf..93125e3d994 100644 --- a/Mage.Sets/src/mage/cards/l/LordXanderTheCollector.java +++ b/Mage.Sets/src/mage/cards/l/LordXanderTheCollector.java @@ -76,6 +76,17 @@ class LordXanderTheCollectorEffect extends OneShotEffect { LordXanderTheCollectorEffect(LordXanderTheCollectorEffectType LordXanderTheCollectorEffectType) { super(Outcome.Benefit); this.effectType = LordXanderTheCollectorEffectType; + switch (effectType) { + case DISCARD: + this.staticText = "target opponent discards half the cards in their hand, rounded down"; + break; + case MILL: + this.staticText = "defending player mills half their library, rounded down"; + break; + case SACRIFICE: + this.staticText = "target opponent sacrifices half the nonland permanents they control, rounded down"; + break; + } } private LordXanderTheCollectorEffect(final LordXanderTheCollectorEffect effect) { @@ -132,17 +143,4 @@ class LordXanderTheCollectorEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - switch (effectType) { - case DISCARD: - return "target opponent discards half the cards in their hand, rounded down"; - case MILL: - return "defending player mills half their library, rounded down"; - case SACRIFICE: - return "target opponent sacrifices half the nonland permanents they control, rounded down"; - } - return ""; - } } diff --git a/Mage.Sets/src/mage/cards/l/LostLegacy.java b/Mage.Sets/src/mage/cards/l/LostLegacy.java index 7cbd30a66b6..a0e97ac2c00 100644 --- a/Mage.Sets/src/mage/cards/l/LostLegacy.java +++ b/Mage.Sets/src/mage/cards/l/LostLegacy.java @@ -44,6 +44,7 @@ class LostLegacyEffect extends SearchTargetGraveyardHandLibraryForCardNameAndExi LostLegacyEffect() { super(true, "target player's", "any number of cards with that name"); + this.staticText = "Search target player's graveyard, hand, and library for any number of cards with that name and exile them. That player shuffles, then draws a card for each card exiled from their hand this way"; } LostLegacyEffect(final LostLegacyEffect effect) { @@ -72,9 +73,4 @@ class LostLegacyEffect extends SearchTargetGraveyardHandLibraryForCardNameAndExi public LostLegacyEffect copy() { return new LostLegacyEffect(this); } - - @Override - public String getText(Mode mode) { - return "Search target player's graveyard, hand, and library for any number of cards with that name and exile them. That player shuffles, then draws a card for each card exiled from their hand this way"; - } } diff --git a/Mage.Sets/src/mage/cards/m/ManaVortex.java b/Mage.Sets/src/mage/cards/m/ManaVortex.java index 38276f4e054..e64c38e690e 100644 --- a/Mage.Sets/src/mage/cards/m/ManaVortex.java +++ b/Mage.Sets/src/mage/cards/m/ManaVortex.java @@ -60,6 +60,7 @@ class CounterSourceEffect extends OneShotEffect { public CounterSourceEffect() { super(Outcome.Detriment); + this.staticText = "counter it unless you sacrifice a land"; } public CounterSourceEffect(final CounterSourceEffect effect) { @@ -96,14 +97,6 @@ class CounterSourceEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - if (staticText != null && !staticText.isEmpty()) { - return staticText; - } - return "counter it unless you sacrifice a land"; - } } class ManaVortexStateTriggeredAbility extends StateTriggeredAbility { diff --git a/Mage.Sets/src/mage/cards/m/Melting.java b/Mage.Sets/src/mage/cards/m/Melting.java index ff759cdf784..f6ae0d80f8e 100644 --- a/Mage.Sets/src/mage/cards/m/Melting.java +++ b/Mage.Sets/src/mage/cards/m/Melting.java @@ -48,6 +48,7 @@ class MeltingEffect extends ContinuousEffectImpl { public MeltingEffect() { super(Duration.WhileOnBattlefield, Layer.TypeChangingEffects_4, SubLayer.NA, Outcome.Detriment); + this.staticText = "All lands are no longer snow"; } public MeltingEffect(final MeltingEffect effect) { @@ -66,9 +67,4 @@ class MeltingEffect extends ContinuousEffectImpl { } return true; } - - @Override - public String getText(Mode mode) { - return "All lands are no longer snow"; - } } diff --git a/Mage.Sets/src/mage/cards/m/Memoricide.java b/Mage.Sets/src/mage/cards/m/Memoricide.java index 9a6c564abf8..5b157260823 100644 --- a/Mage.Sets/src/mage/cards/m/Memoricide.java +++ b/Mage.Sets/src/mage/cards/m/Memoricide.java @@ -61,9 +61,4 @@ class MemoricideEffect extends SearchTargetGraveyardHandLibraryForCardNameAndExi public MemoricideEffect copy() { return new MemoricideEffect(this); } - - @Override - public String getText(Mode mode) { - return "Search target player's graveyard, hand, and library for any number of cards with that name and exile them. Then that player shuffles"; - } } diff --git a/Mage.Sets/src/mage/cards/m/MorgueBurst.java b/Mage.Sets/src/mage/cards/m/MorgueBurst.java index dbf508ef4bc..53c7c2b83a7 100644 --- a/Mage.Sets/src/mage/cards/m/MorgueBurst.java +++ b/Mage.Sets/src/mage/cards/m/MorgueBurst.java @@ -46,6 +46,7 @@ class MorgueBurstEffect extends OneShotEffect { public MorgueBurstEffect() { super(Outcome.ReturnToHand); + this.staticText = "Return target creature card from your graveyard to your hand. Morgue Burst deals damage to any target equal to the power of the card returned this way"; } public MorgueBurstEffect(final MorgueBurstEffect effect) { @@ -79,9 +80,4 @@ class MorgueBurstEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "Return target creature card from your graveyard to your hand. Morgue Burst deals damage to any target equal to the power of the card returned this way"; - } } diff --git a/Mage.Sets/src/mage/cards/n/NewBlood.java b/Mage.Sets/src/mage/cards/n/NewBlood.java index 5f811d96ef7..9462801cee0 100644 --- a/Mage.Sets/src/mage/cards/n/NewBlood.java +++ b/Mage.Sets/src/mage/cards/n/NewBlood.java @@ -99,6 +99,7 @@ class ChangeCreatureTypeTargetEffect extends ContinuousEffectImpl { super(duration, Layer.TextChangingEffects_3, SubLayer.NA, Outcome.Benefit); this.fromSubType = fromSubType; this.toSubType = toSubType; + this.staticText = "Change the text of that creature by replacing all instances of one creature type with Vampire"; } public ChangeCreatureTypeTargetEffect(final ChangeCreatureTypeTargetEffect effect) { @@ -171,9 +172,4 @@ class ChangeCreatureTypeTargetEffect extends ContinuousEffectImpl { public ChangeCreatureTypeTargetEffect copy() { return new ChangeCreatureTypeTargetEffect(this); } - - @Override - public String getText(Mode mode) { - return "Change the text of that creature by replacing all instances of one creature type with Vampire"; - } } diff --git a/Mage.Sets/src/mage/cards/o/OppressiveWill.java b/Mage.Sets/src/mage/cards/o/OppressiveWill.java index 73a6bcb5a18..bf279b477f2 100644 --- a/Mage.Sets/src/mage/cards/o/OppressiveWill.java +++ b/Mage.Sets/src/mage/cards/o/OppressiveWill.java @@ -44,6 +44,7 @@ class SpellSyphonEffect extends OneShotEffect { public SpellSyphonEffect() { super(Outcome.Benefit); + this.staticText = "Counter target spell unless its controller pays {1} for each card in your hand"; } public SpellSyphonEffect(final SpellSyphonEffect effect) { @@ -76,10 +77,4 @@ class SpellSyphonEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "Counter target spell unless its controller pays {1} for each card in your hand"; - } - } diff --git a/Mage.Sets/src/mage/cards/o/OracleEnVec.java b/Mage.Sets/src/mage/cards/o/OracleEnVec.java index 85c3d420b2b..be139101af4 100644 --- a/Mage.Sets/src/mage/cards/o/OracleEnVec.java +++ b/Mage.Sets/src/mage/cards/o/OracleEnVec.java @@ -163,6 +163,7 @@ class OracleEnVecCantAttackRestrictionEffect extends RestrictionEffect { OracleEnVecCantAttackRestrictionEffect() { super(Duration.Custom); + this.staticText = "{this} can't attack."; } OracleEnVecCantAttackRestrictionEffect(final OracleEnVecCantAttackRestrictionEffect effect) { @@ -200,11 +201,6 @@ class OracleEnVecCantAttackRestrictionEffect extends RestrictionEffect { public boolean isInactive(Ability source, Game game) { return game.getPhase().getType() == TurnPhase.END && this.isYourNextTurn(game); } - - @Override - public String getText(Mode mode) { - return "{this} can't attack."; - } } class OracleEnVecDelayedTriggeredAbility extends DelayedTriggeredAbility { @@ -214,6 +210,7 @@ class OracleEnVecDelayedTriggeredAbility extends DelayedTriggeredAbility { OracleEnVecDelayedTriggeredAbility(int startingTurn, List chosenCreatures) { super(new OracleEnVecDestroyEffect(chosenCreatures), Duration.EndOfGame, true); this.startingTurn = startingTurn; + setTriggerPhrase("At the beginning of that turn's end step, "); } OracleEnVecDelayedTriggeredAbility(final OracleEnVecDelayedTriggeredAbility ability) { @@ -235,11 +232,6 @@ class OracleEnVecDelayedTriggeredAbility extends DelayedTriggeredAbility { public OracleEnVecDelayedTriggeredAbility copy() { return new OracleEnVecDelayedTriggeredAbility(this); } - - @Override - public String getRule() { - return "At the beginning of that turn's end step, destroy each of the chosen creatures that didn't attack."; - } } class OracleEnVecDestroyEffect extends OneShotEffect { diff --git a/Mage.Sets/src/mage/cards/o/OverrideCard.java b/Mage.Sets/src/mage/cards/o/OverrideCard.java index 26d9400ea31..9838fef899e 100644 --- a/Mage.Sets/src/mage/cards/o/OverrideCard.java +++ b/Mage.Sets/src/mage/cards/o/OverrideCard.java @@ -45,6 +45,7 @@ class OverrideEffect extends OneShotEffect { public OverrideEffect() { super(Outcome.Benefit); + this.staticText = "Counter target spell unless its controller pays {1} for each artifact you control"; } public OverrideEffect(final OverrideEffect effect) { @@ -77,10 +78,4 @@ class OverrideEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "Counter target spell unless its controller pays {1} for each artifact you control"; - } - } diff --git a/Mage.Sets/src/mage/cards/p/Phantasmagorian.java b/Mage.Sets/src/mage/cards/p/Phantasmagorian.java index d7d050a973c..45ed8e484a4 100644 --- a/Mage.Sets/src/mage/cards/p/Phantasmagorian.java +++ b/Mage.Sets/src/mage/cards/p/Phantasmagorian.java @@ -56,6 +56,7 @@ class CounterSourceEffect extends OneShotEffect { public CounterSourceEffect() { super(Outcome.AIDontUseIt); + this.staticText = "any player may discard three cards. If a player does, counter {this}"; } public CounterSourceEffect(final CounterSourceEffect effect) { @@ -91,12 +92,4 @@ class CounterSourceEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - if (staticText != null && !staticText.isEmpty()) { - return staticText; - } - return "any player may discard three cards. If a player does, counter {this}"; - } } diff --git a/Mage.Sets/src/mage/cards/p/PickTheBrain.java b/Mage.Sets/src/mage/cards/p/PickTheBrain.java index 3e8cdbc825e..9e61d1371bb 100644 --- a/Mage.Sets/src/mage/cards/p/PickTheBrain.java +++ b/Mage.Sets/src/mage/cards/p/PickTheBrain.java @@ -48,6 +48,10 @@ class PickTheBrainEffect extends SearchTargetGraveyardHandLibraryForCardNameAndE public PickTheBrainEffect() { super(true, "that card's controller", "all cards with the same name as that card"); + this.staticText = "Target opponent reveals their hand. You choose a nonland card from it and exile that card.

" + + "Delirium — If there are four or more card types among cards in your graveyard, " + + "search that player's graveyard, hand, and library for any number of cards " + + "with the same name as the exiled card, exile those cards, then that player shuffles"; } public PickTheBrainEffect(final PickTheBrainEffect effect) { @@ -83,12 +87,4 @@ class PickTheBrainEffect extends SearchTargetGraveyardHandLibraryForCardNameAndE } return false; } - - @Override - public String getText(Mode mode) { - return "Target opponent reveals their hand. You choose a nonland card from it and exile that card.

" - + "Delirium — If there are four or more card types among cards in your graveyard, " - + "search that player's graveyard, hand, and library for any number of cards " - + "with the same name as the exiled card, exile those cards, then that player shuffles"; - } } diff --git a/Mage.Sets/src/mage/cards/p/PowerSurge.java b/Mage.Sets/src/mage/cards/p/PowerSurge.java index 45652e501dc..d70b3de3bdd 100644 --- a/Mage.Sets/src/mage/cards/p/PowerSurge.java +++ b/Mage.Sets/src/mage/cards/p/PowerSurge.java @@ -43,17 +43,13 @@ class PowerSurgeDamageEffect extends OneShotEffect { public PowerSurgeDamageEffect() { super(Outcome.Damage); + this.staticText = "{this} deals X damage to that player where X is the number of untapped lands they controlled at the beginning of this turn"; } public PowerSurgeDamageEffect(PowerSurgeDamageEffect copy) { super(copy); } - @Override - public String getText(Mode mode) { - return "{this} deals X damage to that player where X is the number of untapped lands they controlled at the beginning of this turn"; - } - @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(targetPointer.getFirst(game, source)); diff --git a/Mage.Sets/src/mage/cards/p/PrimalOrder.java b/Mage.Sets/src/mage/cards/p/PrimalOrder.java index 497f46128bf..7160a35afb8 100644 --- a/Mage.Sets/src/mage/cards/p/PrimalOrder.java +++ b/Mage.Sets/src/mage/cards/p/PrimalOrder.java @@ -44,17 +44,13 @@ class PrimalOrderDamageTargetEffect extends OneShotEffect { public PrimalOrderDamageTargetEffect() { super(Outcome.Damage); + this.staticText = "{this} deals damage to that player equal to the number of nonbasic lands they control"; } public PrimalOrderDamageTargetEffect(PrimalOrderDamageTargetEffect copy) { super(copy); } - @Override - public String getText(Mode mode) { - return "{this} deals damage to that player equal to the number of nonbasic lands they control"; - } - @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(targetPointer.getFirst(game, source)); diff --git a/Mage.Sets/src/mage/cards/p/Pyroblast.java b/Mage.Sets/src/mage/cards/p/Pyroblast.java index 1218d9c746e..f9834e24d6a 100644 --- a/Mage.Sets/src/mage/cards/p/Pyroblast.java +++ b/Mage.Sets/src/mage/cards/p/Pyroblast.java @@ -47,6 +47,7 @@ class PyroblastCounterTargetEffect extends OneShotEffect { public PyroblastCounterTargetEffect() { super(Outcome.Detriment); + this.staticText = "Counter target spell if it's blue"; } public PyroblastCounterTargetEffect(final PyroblastCounterTargetEffect effect) { @@ -66,18 +67,13 @@ class PyroblastCounterTargetEffect extends OneShotEffect { } return true; } - - @Override - public String getText(Mode mode) { - return "Counter target spell if it's blue"; - } - } class PyroblastDestroyTargetEffect extends OneShotEffect { public PyroblastDestroyTargetEffect() { super(Outcome.DestroyPermanent); + this.staticText = "Destroy target permanent if it's blue"; } public PyroblastDestroyTargetEffect(final PyroblastDestroyTargetEffect effect) { @@ -97,10 +93,4 @@ class PyroblastDestroyTargetEffect extends OneShotEffect { } return true; } - - @Override - public String getText(Mode mode) { - return "Destroy target permanent if it's blue"; - } - } diff --git a/Mage.Sets/src/mage/cards/r/RenderSilent.java b/Mage.Sets/src/mage/cards/r/RenderSilent.java index d2f18055614..40cbaadc9a9 100644 --- a/Mage.Sets/src/mage/cards/r/RenderSilent.java +++ b/Mage.Sets/src/mage/cards/r/RenderSilent.java @@ -7,6 +7,7 @@ import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.CounterTargetEffect; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; @@ -27,17 +28,11 @@ import mage.target.targetpointer.FixedTarget; */ public final class RenderSilent extends CardImpl { - private static final FilterControlledPermanent filter = new FilterControlledPermanent("multicolored permanent"); - - static { - filter.add(MulticoloredPredicate.instance); - } - public RenderSilent(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{W}{U}{U}"); // Counter target spell. Its controller can't cast spells this turn. - this.getSpellAbility().addEffect(new RenderSilentCounterEffect()); + this.getSpellAbility().addEffect(new CounterTargetEffect()); this.getSpellAbility().addTarget(new TargetSpell()); this.getSpellAbility().addEffect(new RenderSilentEffect()); } @@ -52,38 +47,6 @@ public final class RenderSilent extends CardImpl { } } -class RenderSilentCounterEffect extends OneShotEffect { - - public RenderSilentCounterEffect() { - super(Outcome.Detriment); - } - - public RenderSilentCounterEffect(final RenderSilentCounterEffect effect) { - super(effect); - } - - @Override - public RenderSilentCounterEffect copy() { - return new RenderSilentCounterEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Spell spell = game.getStack().getSpell(source.getFirstTarget()); - if (spell != null) { - source.getEffects().get(1).setTargetPointer(new FixedTarget(spell.getControllerId())); - return game.getStack().counter(source.getFirstTarget(), source, game); - } - return false; - } - - @Override - public String getText(Mode mode) { - return "Counter target " + mode.getTargets().get(0).getTargetName(); - } - -} - class RenderSilentEffect extends ContinuousRuleModifyingEffectImpl { public RenderSilentEffect() { diff --git a/Mage.Sets/src/mage/cards/r/RescueFromTheUnderworld.java b/Mage.Sets/src/mage/cards/r/RescueFromTheUnderworld.java index a225bec80ed..0bebcb7e4b9 100644 --- a/Mage.Sets/src/mage/cards/r/RescueFromTheUnderworld.java +++ b/Mage.Sets/src/mage/cards/r/RescueFromTheUnderworld.java @@ -106,6 +106,7 @@ class RescueFromTheUnderworldCreateDelayedTriggeredAbilityEffect extends OneShot public RescueFromTheUnderworldCreateDelayedTriggeredAbilityEffect(DelayedTriggeredAbility ability) { super(ability.getEffects().getOutcome(ability)); this.ability = ability; + this.staticText = "Return that card and the sacrificed card to the battlefield under your control at the beginning of your next upkeep"; } public RescueFromTheUnderworldCreateDelayedTriggeredAbilityEffect(final RescueFromTheUnderworldCreateDelayedTriggeredAbilityEffect effect) { @@ -140,12 +141,6 @@ class RescueFromTheUnderworldCreateDelayedTriggeredAbilityEffect extends OneShot game.addDelayedTriggeredAbility(delayedAbility, source); return true; } - - @Override - public String getText(Mode mode) { - return ability.getRule(); - } - } class RescueFromTheUnderworldDelayedTriggeredAbility extends DelayedTriggeredAbility { diff --git a/Mage.Sets/src/mage/cards/r/RimefeatherOwl.java b/Mage.Sets/src/mage/cards/r/RimefeatherOwl.java index 3a68df6cd25..ac3fbaa0a10 100644 --- a/Mage.Sets/src/mage/cards/r/RimefeatherOwl.java +++ b/Mage.Sets/src/mage/cards/r/RimefeatherOwl.java @@ -88,6 +88,7 @@ class RimefeatherOwlEffect extends ContinuousEffectImpl { public RimefeatherOwlEffect(Duration duration, FilterPermanent filter) { super(duration, Layer.TypeChangingEffects_4, SubLayer.NA, Outcome.Detriment); this.filter = filter; + this.staticText = "Permanents with ice counters on them are snow."; } public RimefeatherOwlEffect(final RimefeatherOwlEffect effect) { @@ -108,9 +109,4 @@ class RimefeatherOwlEffect extends ContinuousEffectImpl { } return true; } - - @Override - public String getText(Mode mode) { - return "Permanents with ice counters on them are snow."; - } } diff --git a/Mage.Sets/src/mage/cards/r/RiskyMove.java b/Mage.Sets/src/mage/cards/r/RiskyMove.java index a5947a60c11..2273346d3e6 100644 --- a/Mage.Sets/src/mage/cards/r/RiskyMove.java +++ b/Mage.Sets/src/mage/cards/r/RiskyMove.java @@ -185,6 +185,7 @@ class RiskyMoveCreatureGainControlEffect extends ContinuousEffectImpl { public RiskyMoveCreatureGainControlEffect(Duration duration, UUID controller) { super(duration, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); this.controller = controller; + this.staticText = "If you lose the flip, that opponent gains control of that creature"; } public RiskyMoveCreatureGainControlEffect(final RiskyMoveCreatureGainControlEffect effect) { @@ -208,9 +209,4 @@ class RiskyMoveCreatureGainControlEffect extends ContinuousEffectImpl { } return false; } - - @Override - public String getText(Mode mode) { - return "If you lose the flip, that opponent gains control of that creature"; - } } diff --git a/Mage.Sets/src/mage/cards/s/ScarwoodBandits.java b/Mage.Sets/src/mage/cards/s/ScarwoodBandits.java index 54e31161090..99eaeff587c 100644 --- a/Mage.Sets/src/mage/cards/s/ScarwoodBandits.java +++ b/Mage.Sets/src/mage/cards/s/ScarwoodBandits.java @@ -148,9 +148,6 @@ class DoUnlessAnyOpponentPaysEffect extends OneShotEffect { @Override public String getText(Mode mode) { - if (!staticText.isEmpty()) { - return staticText; - } String effectsText = executingEffects.getText(mode); return effectsText.substring(0, effectsText.length() - 1) + " unless any opponent pays " + cost.getText(); } diff --git a/Mage.Sets/src/mage/cards/s/ShiftingShadow.java b/Mage.Sets/src/mage/cards/s/ShiftingShadow.java index 348066d4230..896438fd3b8 100644 --- a/Mage.Sets/src/mage/cards/s/ShiftingShadow.java +++ b/Mage.Sets/src/mage/cards/s/ShiftingShadow.java @@ -90,18 +90,18 @@ class ShiftingShadowGainEffect extends ContinuousEffectImpl { class ShiftingShadowEffect extends OneShotEffect { private final MageObjectReference mor; - private final String name; ShiftingShadowEffect(Permanent permanent, Game game) { super(Outcome.Benefit); this.mor = new MageObjectReference(permanent, game); - this.name = permanent.getName(); + this.staticText = "destroy this creature. Reveal cards from the top of your library until you reveal a creature card. " + + "Put that card onto the battlefield and attach " + permanent.getName() + " to it, then put all other cards " + + "revealed this way on the bottom of your library in a random order."; } private ShiftingShadowEffect(final ShiftingShadowEffect effect) { super(effect); this.mor = effect.mor; - this.name = effect.name; } @Override @@ -147,11 +147,4 @@ class ShiftingShadowEffect extends OneShotEffect { player.putCardsOnBottomOfLibrary(cards, game, source, false); return true; } - - @Override - public String getText(Mode mode) { - return "destroy this creature. Reveal cards from the top of your library until you reveal a creature card. " + - "Put that card onto the battlefield and attach " + name + " to it, then put all other cards " + - "revealed this way on the bottom of your library in a random order."; - } } diff --git a/Mage.Sets/src/mage/cards/s/SkilledAnimator.java b/Mage.Sets/src/mage/cards/s/SkilledAnimator.java index f0f0c6899ab..490132e97a5 100644 --- a/Mage.Sets/src/mage/cards/s/SkilledAnimator.java +++ b/Mage.Sets/src/mage/cards/s/SkilledAnimator.java @@ -59,6 +59,7 @@ class SkilledAnimatorBecomesCreatureEffect extends BecomesCreatureTargetEffect { public SkilledAnimatorBecomesCreatureEffect() { super(new SkilledAnimatorToken(), false, false, Duration.WhileOnBattlefield); + this.staticText = "target artifact you control becomes an artifact creature with base power and toughness 5/5 for as long as {this} remains on the battlefield"; } public SkilledAnimatorBecomesCreatureEffect(final SkilledAnimatorBecomesCreatureEffect effect) { @@ -79,11 +80,6 @@ class SkilledAnimatorBecomesCreatureEffect extends BecomesCreatureTargetEffect { } return super.apply(layer, sublayer, source, game); } - - @Override - public String getText(Mode mode) { - return "target artifact you control becomes an artifact creature with base power and toughness 5/5 for as long as {this} remains on the battlefield"; - } } class SkilledAnimatorToken extends TokenImpl { diff --git a/Mage.Sets/src/mage/cards/s/SkySwallower.java b/Mage.Sets/src/mage/cards/s/SkySwallower.java index aef84518b66..b675f0b0147 100644 --- a/Mage.Sets/src/mage/cards/s/SkySwallower.java +++ b/Mage.Sets/src/mage/cards/s/SkySwallower.java @@ -53,6 +53,7 @@ class GainControlAllPermanentsEffect extends ContinuousEffectImpl { public GainControlAllPermanentsEffect(Duration duration) { super(duration, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.Detriment); + this.staticText = "target opponent gains control of all other permanents you control"; } public GainControlAllPermanentsEffect(final GainControlAllPermanentsEffect effect) { @@ -78,9 +79,4 @@ class GainControlAllPermanentsEffect extends ContinuousEffectImpl { } return true; } - - @Override - public String getText(Mode mode) { - return "target opponent gains control of all other permanents you control"; - } } diff --git a/Mage.Sets/src/mage/cards/s/SpellRupture.java b/Mage.Sets/src/mage/cards/s/SpellRupture.java index c110ad6b8f1..2e4202eeeca 100644 --- a/Mage.Sets/src/mage/cards/s/SpellRupture.java +++ b/Mage.Sets/src/mage/cards/s/SpellRupture.java @@ -50,6 +50,7 @@ class SpellRuptureCounterUnlessPaysEffect extends OneShotEffect { public SpellRuptureCounterUnlessPaysEffect() { super(Outcome.Detriment); + this.staticText = "Counter target spell unless its controller pays {X}, where X is the greatest power among creatures you control"; } public SpellRuptureCounterUnlessPaysEffect(final SpellRuptureCounterUnlessPaysEffect effect) { @@ -81,11 +82,6 @@ class SpellRuptureCounterUnlessPaysEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "Counter target spell unless its controller pays {X}, where X is the greatest power among creatures you control"; - } } class GreatestPowerCountCreatureYouControl implements DynamicValue { diff --git a/Mage.Sets/src/mage/cards/s/SpellSyphon.java b/Mage.Sets/src/mage/cards/s/SpellSyphon.java index 575ba034f7e..bd9950842df 100644 --- a/Mage.Sets/src/mage/cards/s/SpellSyphon.java +++ b/Mage.Sets/src/mage/cards/s/SpellSyphon.java @@ -56,6 +56,7 @@ class SpellSyphonEffect extends OneShotEffect { public SpellSyphonEffect() { super(Outcome.Detriment); + this.staticText = "Counter target spell unless its controller pays {1} for each blue permanent you control"; } public SpellSyphonEffect(final SpellSyphonEffect effect) { @@ -88,10 +89,4 @@ class SpellSyphonEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "Counter target spell unless its controller pays {1} for each blue permanent you control"; - } - } diff --git a/Mage.Sets/src/mage/cards/s/StreetSweeper.java b/Mage.Sets/src/mage/cards/s/StreetSweeper.java index c898004224d..cfdd2439783 100644 --- a/Mage.Sets/src/mage/cards/s/StreetSweeper.java +++ b/Mage.Sets/src/mage/cards/s/StreetSweeper.java @@ -61,6 +61,7 @@ class StreetSweeperDestroyEffect extends OneShotEffect { public StreetSweeperDestroyEffect() { super(Outcome.DestroyPermanent); + this.staticText = "destroy all Auras attached to target land"; } public StreetSweeperDestroyEffect(final StreetSweeperDestroyEffect effect) { @@ -91,9 +92,4 @@ class StreetSweeperDestroyEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "destroy all Auras attached to target land"; - } } \ No newline at end of file diff --git a/Mage.Sets/src/mage/cards/s/StrionicResonator.java b/Mage.Sets/src/mage/cards/s/StrionicResonator.java index df7808e549e..b549308e45e 100644 --- a/Mage.Sets/src/mage/cards/s/StrionicResonator.java +++ b/Mage.Sets/src/mage/cards/s/StrionicResonator.java @@ -45,6 +45,7 @@ class StrionicResonatorEffect extends OneShotEffect { public StrionicResonatorEffect() { super(Outcome.Copy); + this.staticText = "Copy target triggered ability you control. You may choose new targets for the copy"; } public StrionicResonatorEffect(final StrionicResonatorEffect effect) { @@ -66,9 +67,4 @@ class StrionicResonatorEffect extends OneShotEffect { public StrionicResonatorEffect copy() { return new StrionicResonatorEffect(this); } - - @Override - public String getText(Mode mode) { - return "Copy " + mode.getTargets().get(0).getTargetName() + ". You may choose new targets for the copy"; - } } diff --git a/Mage.Sets/src/mage/cards/t/ThousandYearStorm.java b/Mage.Sets/src/mage/cards/t/ThousandYearStorm.java index e125bf3eb85..fa5d2f8332d 100644 --- a/Mage.Sets/src/mage/cards/t/ThousandYearStorm.java +++ b/Mage.Sets/src/mage/cards/t/ThousandYearStorm.java @@ -114,6 +114,7 @@ class ThousandYearStormEffect extends OneShotEffect { public ThousandYearStormEffect() { super(Outcome.Benefit); this.stormCount = -1; + this.staticText = "copy it for each other instant and sorcery spell you've cast before it this turn. You may choose new targets for the copies"; } public ThousandYearStormEffect(final ThousandYearStormEffect effect) { @@ -139,11 +140,6 @@ class ThousandYearStormEffect extends OneShotEffect { public void setStormCount(int stormCount) { this.stormCount = stormCount; } - - @Override - public String getText(Mode mode) { - return "copy it for each other instant and sorcery spell you've cast before it this turn. You may choose new targets for the copies"; - } } class ThousandYearStormWatcher extends Watcher { diff --git a/Mage.Sets/src/mage/cards/t/TreefolkMystic.java b/Mage.Sets/src/mage/cards/t/TreefolkMystic.java index e2510a41670..9b29a443622 100644 --- a/Mage.Sets/src/mage/cards/t/TreefolkMystic.java +++ b/Mage.Sets/src/mage/cards/t/TreefolkMystic.java @@ -47,6 +47,7 @@ class TreefolkMysticEffect extends OneShotEffect { public TreefolkMysticEffect() { super(Outcome.DestroyPermanent); + this.staticText = "destroy all Auras attached to that creature"; } public TreefolkMysticEffect(final TreefolkMysticEffect effect) { @@ -73,10 +74,4 @@ class TreefolkMysticEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "destroy all Auras attached to that creature"; - } - } diff --git a/Mage.Sets/src/mage/cards/v/ViashinoHeretic.java b/Mage.Sets/src/mage/cards/v/ViashinoHeretic.java index 2e3c2cba00b..de885b68b42 100644 --- a/Mage.Sets/src/mage/cards/v/ViashinoHeretic.java +++ b/Mage.Sets/src/mage/cards/v/ViashinoHeretic.java @@ -54,6 +54,7 @@ class ViashinoHereticEffect extends OneShotEffect { public ViashinoHereticEffect() { super(Outcome.DestroyPermanent); + this.staticText = "Destroy target artifact. Viashino Heretic deals damage to that artifact's controller equal to the artifact's mana value"; } public ViashinoHereticEffect(final ViashinoHereticEffect effect) { @@ -80,9 +81,4 @@ class ViashinoHereticEffect extends OneShotEffect { } return false; } - - @Override - public String getText(Mode mode) { - return "Destroy target artifact. Viashino Heretic deals damage to that artifact's controller equal to the artifact's mana value"; - } } \ No newline at end of file diff --git a/Mage.Sets/src/mage/cards/w/WebOfInertia.java b/Mage.Sets/src/mage/cards/w/WebOfInertia.java index deee9777e48..d0dd80430bc 100644 --- a/Mage.Sets/src/mage/cards/w/WebOfInertia.java +++ b/Mage.Sets/src/mage/cards/w/WebOfInertia.java @@ -44,7 +44,7 @@ class WebOfInertiaEffect extends OneShotEffect { public WebOfInertiaEffect() { super(Outcome.Detriment); - staticText = "that player may exile a card from their graveyard. If the player doesn't, creatures they control can't attack you this turn"; + this.staticText = "that player may exile a card from their graveyard. If the player doesn't, creatures they control can't attack you this turn"; } public WebOfInertiaEffect(final WebOfInertiaEffect effect) { @@ -72,16 +72,10 @@ class WebOfInertiaEffect extends OneShotEffect { return false; } - @Override - public String getText(Mode mode) { - return staticText; - } - @Override public WebOfInertiaEffect copy() { return new WebOfInertiaEffect(this); } - } class WebOfInertiaRestrictionEffect extends RestrictionEffect { @@ -111,11 +105,6 @@ class WebOfInertiaRestrictionEffect extends RestrictionEffect { return !defenderId.equals(source.getControllerId()); } - @Override - public String getText(Mode mode) { - return staticText; - } - @Override public WebOfInertiaRestrictionEffect copy() { return new WebOfInertiaRestrictionEffect(this); diff --git a/Mage.Sets/src/mage/cards/w/WheelOfTorture.java b/Mage.Sets/src/mage/cards/w/WheelOfTorture.java index 34db53de582..73ceb5e5310 100644 --- a/Mage.Sets/src/mage/cards/w/WheelOfTorture.java +++ b/Mage.Sets/src/mage/cards/w/WheelOfTorture.java @@ -41,6 +41,7 @@ class WheelOfTortureEffect extends OneShotEffect { private WheelOfTortureEffect(final WheelOfTortureEffect effect) { super(effect); + this.staticText = "Wheel of Torture deals X damage to that player, where X is 3 minus the number of cards in their hand"; } public WheelOfTortureEffect() { @@ -64,10 +65,4 @@ class WheelOfTortureEffect extends OneShotEffect { public WheelOfTortureEffect copy() { return new WheelOfTortureEffect(this); } - - @Override - public String getText(Mode mode) { - return "Wheel of Torture deals X damage to that player, where X is 3 minus the number of cards in their hand"; - } - } diff --git a/Mage.Sets/src/mage/cards/y/YoseiTheMorningStar.java b/Mage.Sets/src/mage/cards/y/YoseiTheMorningStar.java index 0a40a1aac2f..066153a1fb2 100644 --- a/Mage.Sets/src/mage/cards/y/YoseiTheMorningStar.java +++ b/Mage.Sets/src/mage/cards/y/YoseiTheMorningStar.java @@ -126,5 +126,4 @@ class YoseiTheMorningStarTapEffect extends OneShotEffect { public String getText(Mode mode) { return staticText; } - } diff --git a/Mage/src/main/java/mage/abilities/common/GiveManaAbilityAndCastSourceAbility.java b/Mage/src/main/java/mage/abilities/common/GiveManaAbilityAndCastSourceAbility.java index 11b396b879f..ad9718e4e35 100644 --- a/Mage/src/main/java/mage/abilities/common/GiveManaAbilityAndCastSourceAbility.java +++ b/Mage/src/main/java/mage/abilities/common/GiveManaAbilityAndCastSourceAbility.java @@ -81,6 +81,14 @@ class GainManaAbilitiesWhileExiledEffect extends ContinuousEffectImpl { GainManaAbilitiesWhileExiledEffect(String colors) { super(Duration.Custom, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); this.colors = colors; + this.staticText = + "target land gains \"{T}: Add " + + CardUtil.concatWithOr( + Arrays.stream(colors.split("")) + .map(s -> '{' + s + '}') + .collect(Collectors.toList()) + ) + + "\" until {this} is cast from exile"; } private GainManaAbilitiesWhileExiledEffect(final GainManaAbilitiesWhileExiledEffect effect) { @@ -129,17 +137,6 @@ class GainManaAbilitiesWhileExiledEffect extends ContinuousEffectImpl { } return true; } - - @Override - public String getText(Mode mode) { - return "target land gains \"{T}: Add " + - CardUtil.concatWithOr( - Arrays.stream(colors.split("")) - .map(s -> '{' + s + '}') - .collect(Collectors.toList()) - ) + - "\" until {this} is cast from exile"; - } } class WasCastFromExileWatcher extends Watcher { diff --git a/Mage/src/main/java/mage/abilities/effects/common/AmplifyEffect.java b/Mage/src/main/java/mage/abilities/effects/common/AmplifyEffect.java index 91e5c45a81f..dbf1ef308da 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/AmplifyEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/AmplifyEffect.java @@ -83,6 +83,9 @@ public class AmplifyEffect extends ReplacementEffectImpl { public AmplifyEffect(AmplifyFactor amplifyFactor) { super(Duration.EndOfGame, Outcome.BoostCreature); this.amplifyFactor = amplifyFactor; + this.staticText = amplifyFactor.toString() + + " (As this enter the battlefield, " + amplifyFactor.getRuleText() + " for each card" + + " you reveal that shares a type with it in your hand.)"; } public AmplifyEffect(final AmplifyEffect effect) { @@ -133,15 +136,6 @@ public class AmplifyEffect extends ReplacementEffectImpl { return false; } - @Override - public String getText(Mode mode) { - StringBuilder sb = new StringBuilder(amplifyFactor.toString()); - sb.append(" (As this enter the battlefield, "); - sb.append(amplifyFactor.getRuleText()).append(" for each card" - + " you reveal that shares a type with it in your hand.)"); - return sb.toString(); - } - @Override public AmplifyEffect copy() { return new AmplifyEffect(this); diff --git a/Mage/src/main/java/mage/abilities/effects/common/CantBeRegeneratedSourceEffect.java b/Mage/src/main/java/mage/abilities/effects/common/CantBeRegeneratedSourceEffect.java index 89fd454a988..d3128a4cec4 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/CantBeRegeneratedSourceEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/CantBeRegeneratedSourceEffect.java @@ -19,6 +19,7 @@ public class CantBeRegeneratedSourceEffect extends ContinuousRuleModifyingEffect public CantBeRegeneratedSourceEffect(Duration duration) { super(duration, Outcome.Benefit, false, false); + this.staticText = buildStaticText(); } public CantBeRegeneratedSourceEffect(final CantBeRegeneratedSourceEffect effect) { @@ -56,8 +57,7 @@ public class CantBeRegeneratedSourceEffect extends ContinuousRuleModifyingEffect return Objects.equals(source.getSourceId(), event.getTargetId()); } - @Override - public String getText(Mode mode) { + private String buildStaticText() { if (staticText != null && !staticText.isEmpty()) { return staticText; } diff --git a/Mage/src/main/java/mage/abilities/effects/common/SacrificeOpponentsUnlessPayEffect.java b/Mage/src/main/java/mage/abilities/effects/common/SacrificeOpponentsUnlessPayEffect.java index d0e86cc5886..e9b1e2e3928 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/SacrificeOpponentsUnlessPayEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/SacrificeOpponentsUnlessPayEffect.java @@ -11,6 +11,7 @@ import mage.abilities.effects.OneShotEffect; import mage.constants.Outcome; import mage.constants.TargetController; import mage.filter.FilterPermanent; +import mage.filter.StaticFilters; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; @@ -28,46 +29,17 @@ import java.util.UUID; public class SacrificeOpponentsUnlessPayEffect extends OneShotEffect { protected Cost cost; - protected DynamicValue genericMana; - protected DynamicValue amount; protected FilterPermanent filter; - public SacrificeOpponentsUnlessPayEffect(Cost cost) { - this(cost, new FilterPermanent(), 1); - } - public SacrificeOpponentsUnlessPayEffect(int genericManaCost) { - this(genericManaCost, new FilterPermanent(), 1); + this(new GenericManaCost(genericManaCost), StaticFilters.FILTER_PERMANENT); } public SacrificeOpponentsUnlessPayEffect(Cost cost, FilterPermanent filter) { - this(cost, filter, 1); - } - - public SacrificeOpponentsUnlessPayEffect(int genericManaCost, FilterPermanent filter) { - this(genericManaCost, filter, 1); - } - - public SacrificeOpponentsUnlessPayEffect(Cost cost, FilterPermanent filter, int amount) { - this(cost, filter, StaticValue.get(amount)); - } - - public SacrificeOpponentsUnlessPayEffect(int genericManaCost, FilterPermanent filter, int amount) { - this(new GenericManaCost(genericManaCost), filter, StaticValue.get(amount)); - } - - public SacrificeOpponentsUnlessPayEffect(Cost cost, FilterPermanent filter, DynamicValue amount) { super(Outcome.Sacrifice); this.cost = cost; - this.amount = amount; - this.filter = filter; - } - - public SacrificeOpponentsUnlessPayEffect(DynamicValue genericMana, FilterPermanent filter, DynamicValue amount) { - super(Outcome.Sacrifice); - this.genericMana = genericMana; - this.amount = amount; this.filter = filter; + this.staticText = "each opponent sacrifices " + CardUtil.addArticle(filter.getMessage()) + " unless they " + CardUtil.addCostVerb(cost.getText()); } public SacrificeOpponentsUnlessPayEffect(final SacrificeOpponentsUnlessPayEffect effect) { @@ -76,14 +48,6 @@ public class SacrificeOpponentsUnlessPayEffect extends OneShotEffect { this.cost = effect.cost.copy(); } - if (effect.genericMana != null) { - this.genericMana = effect.genericMana.copy(); - } - - if (effect.amount != null) { - this.amount = effect.amount.copy(); - } - if (effect.filter != null) { this.filter = effect.filter.copy(); } @@ -103,27 +67,16 @@ public class SacrificeOpponentsUnlessPayEffect extends OneShotEffect { Player player = game.getPlayer(playerId); if (player != null) { - Cost costToPay; - String costValueMessage; - if (cost != null) { - costToPay = cost.copy(); - costValueMessage = costToPay.getText(); - } else { - costToPay = ManaUtil.createManaCost(genericMana, game, source, this); - costValueMessage = "{" + genericMana.calculate(game, source, this) + "}"; - } - String message = ""; - if (costToPay instanceof ManaCost) { - message += "Pay "; - } - message += costValueMessage + '?'; + Cost costToPay = cost.copy(); + String costValueMessage = costToPay.getText(); + String message = ((costToPay instanceof ManaCost) ? "Pay " : "") + costValueMessage + '?'; costToPay.clearPaid(); if (!(player.chooseUse(Outcome.Benefit, message, source, game) && costToPay.pay(source, game, source, player.getId(), false, null))) { game.informPlayers(player.getLogName() + " chooses not to pay " + costValueMessage + " to prevent the sacrifice effect"); - int numTargets = Math.min(amount.calculate(game, source, this), game.getBattlefield().countAll(filter, player.getId(), game)); + int numTargets = Math.min(1, game.getBattlefield().countAll(filter, player.getId(), game)); if (numTargets > 0) { TargetPermanent target = new TargetPermanent(numTargets, numTargets, filter, true); @@ -148,43 +101,4 @@ public class SacrificeOpponentsUnlessPayEffect extends OneShotEffect { return true; } - - @Override - public String getText(Mode mode) { - if (staticText != null && !staticText.isEmpty()) { - return staticText; - } - StringBuilder sb = new StringBuilder(); - sb.append("each opponent sacrifices "); - - switch (amount.toString()) { - case "1": - sb.append(CardUtil.addArticle(filter.getMessage())); - break; - case "X": - sb.append("X "); - sb.append(filter.getMessage()); - break; - default: - sb.append(CardUtil.numberToText(amount.toString())); - sb.append(' '); - sb.append(filter.getMessage()); - } - - - sb.append(" unless they "); - - if (cost != null) { - sb.append(CardUtil.addCostVerb(cost.getText())); - } else { - sb.append("pay {X}"); - } - - if (genericMana != null && !genericMana.getMessage().isEmpty()) { - sb.append(", where X is "); - sb.append(genericMana.getMessage()); - } - - return sb.toString(); - } } diff --git a/Mage/src/main/java/mage/abilities/effects/common/continuous/CreaturesBecomeOtherTypeEffect.java b/Mage/src/main/java/mage/abilities/effects/common/continuous/CreaturesBecomeOtherTypeEffect.java index 01cd5cafab8..1b0d7285847 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/continuous/CreaturesBecomeOtherTypeEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/continuous/CreaturesBecomeOtherTypeEffect.java @@ -19,6 +19,8 @@ public class CreaturesBecomeOtherTypeEffect extends ContinuousEffectImpl { this.subType = subType; this.dependendToTypes.add(DependencyType.BecomeCreature); // Opalescence and Starfield of Nyx + this.staticText = this.filter.getMessage() + " is " + this.subType.getIndefiniteArticle() + + " " + this.subType.toString() + " in addition to its other types"; } protected CreaturesBecomeOtherTypeEffect(final CreaturesBecomeOtherTypeEffect effect) { @@ -52,14 +54,4 @@ public class CreaturesBecomeOtherTypeEffect extends ContinuousEffectImpl { public boolean hasLayer(Layer layer) { return layer == Layer.TypeChangingEffects_4; } - - @Override - public String getText(Mode mode) { - if (staticText != null && !staticText.isEmpty()) { - return staticText; - } - - return this.filter.getMessage() + " is " + this.subType.getIndefiniteArticle() - + " " + this.subType.toString() + " in addition to its other types"; - } } \ No newline at end of file diff --git a/Mage/src/main/java/mage/abilities/effects/common/search/SearchTargetGraveyardHandLibraryForCardNameAndExileEffect.java b/Mage/src/main/java/mage/abilities/effects/common/search/SearchTargetGraveyardHandLibraryForCardNameAndExileEffect.java index e7f8b3132e3..1029b4899d3 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/search/SearchTargetGraveyardHandLibraryForCardNameAndExileEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/search/SearchTargetGraveyardHandLibraryForCardNameAndExileEffect.java @@ -38,6 +38,7 @@ public abstract class SearchTargetGraveyardHandLibraryForCardNameAndExileEffect this.searchWhatText = searchWhatText; this.searchForText = searchForText; this.graveyardExileOptional = graveyardExileOptional; + this.staticText = "search " + searchWhatText + " graveyard, hand, and library for " + searchForText + " and exile them. Then that player shuffles"; } public SearchTargetGraveyardHandLibraryForCardNameAndExileEffect(final SearchTargetGraveyardHandLibraryForCardNameAndExileEffect effect) { @@ -98,17 +99,4 @@ public abstract class SearchTargetGraveyardHandLibraryForCardNameAndExileEffect return false; } - - @Override - public String getText(Mode mode) { - if (staticText != null && !staticText.isEmpty()) { - return staticText; - } - StringBuilder sb = new StringBuilder(); - sb.append("search ").append(this.searchWhatText); - sb.append(" graveyard, hand, and library for "); - sb.append(this.searchForText); - sb.append(" and exile them. Then that player shuffles"); - return sb.toString(); - } }