From 2a39a4a278ee7ee7b6c4f6c8b5a5fad45b7bf1d7 Mon Sep 17 00:00:00 2001 From: PurpleCrowbar <26198472+PurpleCrowbar@users.noreply.github.com> Date: Sat, 8 Oct 2022 16:11:42 +0100 Subject: [PATCH] Fixed text of some Domain cards. Closes #9610 --- .../src/mage/cards/l/LeylineBinding.java | 2 +- Mage.Sets/src/mage/cards/s/Stratadon.java | 47 +++---------------- .../src/mage/cards/y/YavimayaSojourner.java | 1 + 3 files changed, 9 insertions(+), 41 deletions(-) diff --git a/Mage.Sets/src/mage/cards/l/LeylineBinding.java b/Mage.Sets/src/mage/cards/l/LeylineBinding.java index 3e19b8a93f..861d19ac80 100644 --- a/Mage.Sets/src/mage/cards/l/LeylineBinding.java +++ b/Mage.Sets/src/mage/cards/l/LeylineBinding.java @@ -14,7 +14,6 @@ import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.AbilityWord; import mage.constants.CardType; -import mage.constants.TargetController; import mage.constants.Zone; import mage.filter.StaticFilters; import mage.target.TargetPermanent; @@ -35,6 +34,7 @@ public final class LeylineBinding extends CardImpl { // Domain -- This spell costs {1} less to cast for each basic land type among lands you control. this.addAbility(new SimpleStaticAbility( Zone.ALL, new SpellCostReductionSourceEffect(DomainValue.REGULAR) + .setText("This spell costs {1} less to cast for each basic land type among lands you control") ).setAbilityWord(AbilityWord.DOMAIN).addHint(DomainHint.instance)); // When Leyline Binding enters the battlefield, exile target nonland permanent an opponent controls until Leyline Binding leaves the battlefield. diff --git a/Mage.Sets/src/mage/cards/s/Stratadon.java b/Mage.Sets/src/mage/cards/s/Stratadon.java index 8a49cb4b56..e98f3cef1a 100644 --- a/Mage.Sets/src/mage/cards/s/Stratadon.java +++ b/Mage.Sets/src/mage/cards/s/Stratadon.java @@ -3,22 +3,14 @@ package mage.cards.s; import java.util.UUID; import mage.MageInt; -import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.dynamicvalue.common.DomainValue; -import mage.abilities.effects.common.cost.CostModificationEffectImpl; +import mage.abilities.effects.common.cost.SpellCostReductionSourceEffect; import mage.abilities.hint.common.DomainHint; import mage.abilities.keyword.TrampleAbility; import mage.cards.CardImpl; import mage.cards.CardSetInfo; -import mage.constants.CardType; -import mage.constants.SubType; -import mage.constants.CostModificationType; -import mage.constants.Duration; -import mage.constants.Outcome; -import mage.constants.Zone; -import mage.game.Game; -import mage.util.CardUtil; +import mage.constants.*; /** * @@ -32,8 +24,11 @@ public final class Stratadon extends CardImpl { this.power = new MageInt(5); this.toughness = new MageInt(5); - // Domain - Stratadon costs {1} less to cast for each basic land type among lands you control. - this.addAbility(new SimpleStaticAbility(Zone.ALL, new StratadonCostReductionEffect()).addHint(DomainHint.instance)); + // Domain -- This spell costs {1} less to cast for each basic land type among lands you control. + this.addAbility(new SimpleStaticAbility( + Zone.ALL, new SpellCostReductionSourceEffect(DomainValue.REGULAR) + .setText("This spell costs {1} less to cast for each basic land type among lands you control") + ).setAbilityWord(AbilityWord.DOMAIN).addHint(DomainHint.instance)); // Trample this.addAbility(TrampleAbility.getInstance()); } @@ -47,31 +42,3 @@ public final class Stratadon extends CardImpl { return new Stratadon(this); } } - -class StratadonCostReductionEffect extends CostModificationEffectImpl { - - public StratadonCostReductionEffect() { - super(Duration.WhileOnStack, Outcome.Benefit, CostModificationType.REDUCE_COST); - staticText = "Domain — This spell costs {1} less to cast for each basic land type among lands you control."; - } - - protected StratadonCostReductionEffect(final StratadonCostReductionEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source, Ability abilityToModify) { - CardUtil.reduceCost(abilityToModify, DomainValue.REGULAR.calculate(game, source, this)); - return true; - } - - @Override - public boolean applies(Ability abilityToModify, Ability source, Game game) { - return abilityToModify.getSourceId().equals(source.getSourceId()); - } - - @Override - public StratadonCostReductionEffect copy() { - return new StratadonCostReductionEffect(this); - } -} diff --git a/Mage.Sets/src/mage/cards/y/YavimayaSojourner.java b/Mage.Sets/src/mage/cards/y/YavimayaSojourner.java index 911ca60914..ebf41e4f45 100644 --- a/Mage.Sets/src/mage/cards/y/YavimayaSojourner.java +++ b/Mage.Sets/src/mage/cards/y/YavimayaSojourner.java @@ -29,6 +29,7 @@ public final class YavimayaSojourner extends CardImpl { // Domain - This spell costs {1} less to cast for each basic land type among lands you control. this.addAbility(new SimpleStaticAbility( Zone.ALL, new SpellCostReductionSourceEffect(DomainValue.REGULAR) + .setText("This spell costs {1} less to cast for each basic land type among lands you control") ).setAbilityWord(AbilityWord.DOMAIN).addHint(DomainHint.instance)); }