another batch of text cleanup (#11694)

* minor refactor EntersBattlefieldEffect

* more minor refactoring

* text fix

* fix more text

* more text adjustments

* more text discrepancy fixes

* continue the text fixes

* followup fixes and more fixes
This commit is contained in:
xenohedron 2024-01-20 23:13:03 -05:00 committed by GitHub
parent 7008f0a7f0
commit 4959ef4d49
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
84 changed files with 192 additions and 212 deletions

View file

@ -87,7 +87,7 @@ enum AmberGristleOMaulValue implements DynamicValue {
@Override
public String getMessage() {
return "player you're attacking";
return "player being attacked";
}
@Override

View file

@ -11,7 +11,6 @@ import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.*;
import mage.filter.StaticFilters;
import mage.filter.common.FilterCreaturePermanent;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.players.Player;
@ -28,10 +27,10 @@ public final class AngelsTrumpet extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{3}");
// All creatures have vigilance.
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(VigilanceAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent())));
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(VigilanceAbility.getInstance(), Duration.WhileOnBattlefield, StaticFilters.FILTER_PERMANENT_ALL_CREATURES)));
// At the beginning of each player's end step, tap all untapped creatures that player controls that didn't attack this turn. Angel's Trumpet deals damage to the player equal to the number of creatures tapped this way.
this.addAbility(new BeginningOfEndStepTriggeredAbility(new AngelsTrumpetTapEffect(), TargetController.ANY, false));
this.addAbility(new BeginningOfEndStepTriggeredAbility(new AngelsTrumpetTapEffect(), TargetController.EACH_PLAYER, false));
}
private AngelsTrumpet(final AngelsTrumpet card) {

View file

@ -72,7 +72,7 @@ class AngrathMinotaurPirateThirdAbilityEffect extends OneShotEffect {
AngrathMinotaurPirateThirdAbilityEffect() {
super(Outcome.DestroyPermanent);
this.staticText = "Destroy all creature target opponent controls. {this} deals damage to that player equal to their total power";
this.staticText = "Destroy all creatures target opponent controls. {this} deals damage to that player equal to their total power";
}
private AngrathMinotaurPirateThirdAbilityEffect(final AngrathMinotaurPirateThirdAbilityEffect effect) {

View file

@ -26,7 +26,7 @@ public final class Antagonism extends CardImpl {
// At the beginning of each player's end step, Antagonism deals 2 damage to that player unless one of their opponents was dealt damage this turn.
this.addAbility(new BeginningOfEndStepTriggeredAbility(new ConditionalOneShotEffect(new DamageTargetEffect(2),
new OpponentWasNotDealtDamageCondition(), rule), TargetController.ANY, false));
AntagonismCondition.instance, rule), TargetController.EACH_PLAYER, false));
}
@ -40,10 +40,9 @@ public final class Antagonism extends CardImpl {
}
}
class OpponentWasNotDealtDamageCondition implements Condition {
enum AntagonismCondition implements Condition {
public OpponentWasNotDealtDamageCondition() {
}
instance;
@Override
public boolean apply(Game game, Ability source) {

View file

@ -1,4 +1,3 @@
package mage.cards.a;
import java.util.UUID;
@ -13,7 +12,6 @@ import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.*;
import mage.filter.StaticFilters;
import mage.target.common.TargetControlledPermanent;
/**
*
@ -29,7 +27,7 @@ public final class ApocalypseDemon extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// Apocalypse Demon's power and toughness are each equal to the number of cards in your graveyard.
this.addAbility(new SimpleStaticAbility(Zone.ALL, new SetBasePowerToughnessSourceEffect(new CardsInControllerGraveyardCount())));
this.addAbility(new SimpleStaticAbility(Zone.ALL, new SetBasePowerToughnessSourceEffect(new CardsInControllerGraveyardCount(StaticFilters.FILTER_CARD_CARDS))));
// At the beginning of your upkeep, tap Apocalypse Demon unless you sacrifice another creature.
TapSourceUnlessPaysEffect tapEffect = new TapSourceUnlessPaysEffect(new SacrificeTargetCost(StaticFilters.FILTER_CONTROLLED_ANOTHER_CREATURE));

View file

@ -37,7 +37,7 @@ public final class ArchfiendOfIfnir extends CardImpl {
CounterType.M1M1.createInstance(1),
new FilterOpponentsCreaturePermanent("creature your opponents control")
)
));
).setTriggerPhrase("Whenever you cycle or discard another card, "));
// Cycling {2}
this.addAbility(new CyclingAbility(new ManaCostsImpl<>("{2}")));

View file

@ -21,7 +21,7 @@ import mage.target.common.TargetCreaturePermanent;
public final class BanewhipPunisher extends CardImpl {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with a -1/-1 counter on it");
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature that has a -1/-1 counter on it");
static {
filter.add(CounterType.M1M1.getPredicate());

View file

@ -37,7 +37,8 @@ public final class BlazeOfGlory extends CardImpl {
// Target creature defending player controls can block any number of creatures this turn. It blocks each attacking creature this turn if able.
this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter));
this.getSpellAbility().addEffect(new CanBlockAdditionalCreatureTargetEffect(Duration.EndOfTurn, 0));
this.getSpellAbility().addEffect(new CanBlockAdditionalCreatureTargetEffect(Duration.EndOfTurn, 0)
.setText("target creature defending player controls can block any number of creatures this turn"));
this.getSpellAbility().addEffect(new BlazeOfGloryRequirementEffect());
}

View file

@ -1,4 +1,3 @@
package mage.cards.b;
import java.util.UUID;
@ -9,15 +8,14 @@ import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Outcome;
import mage.filter.StaticFilters;
import mage.filter.common.FilterControlledLandPermanent;
import mage.filter.common.FilterCreaturePermanent;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.players.Player;
import mage.target.Target;
import mage.target.common.TargetControlledPermanent;
import mage.target.common.TargetOpponent;
import mage.target.common.TargetSacrifice;
/**
*
@ -32,7 +30,7 @@ public final class BurningOfXinye extends CardImpl {
// You destroy four lands you control, then target opponent destroys four lands they control. Then Burning of Xinye deals 4 damage to each creature.
this.getSpellAbility().addTarget(new TargetOpponent());
this.getSpellAbility().addEffect(new BurningOfXinyeEffect());
this.getSpellAbility().addEffect(new DamageAllEffect(4, new FilterCreaturePermanent()));
this.getSpellAbility().addEffect(new DamageAllEffect(4, StaticFilters.FILTER_PERMANENT_CREATURE).concatBy("Then"));
}
private BurningOfXinye(final BurningOfXinye card) {
@ -50,7 +48,7 @@ class BurningOfXinyeEffect extends OneShotEffect{
private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent();
public BurningOfXinyeEffect() {
BurningOfXinyeEffect() {
super(Outcome.DestroyPermanent);
staticText = "You destroy four lands you control, then target opponent destroys four lands they control";
}
@ -82,10 +80,10 @@ class BurningOfXinyeEffect extends OneShotEffect{
int realCount = game.getBattlefield().countAll(filter, player.getId(), game);
int amount = Math.min(4, realCount);
Target target = new TargetSacrifice(amount, filter);
Target target = new TargetControlledPermanent(amount, amount, filter, true);
if (amount > 0 && target.canChoose(player.getId(), source, game)) {
while (!target.isChosen() && target.canChoose(player.getId(), source, game) && player.canRespond()) {
player.choose(Outcome.Sacrifice, target, source, game);
player.choose(Outcome.DestroyPermanent, target, source, game);
}
for (UUID targetId : target.getTargets()) {

View file

@ -30,7 +30,7 @@ public final class CelestialConvergence extends CardImpl {
// Celestial Convergence enters the battlefield with seven omen counters on it.
Effect effect = new AddCountersSourceEffect(CounterType.OMEN.createInstance(7));
this.addAbility(new EntersBattlefieldAbility(effect, "with seven omen counters"));
this.addAbility(new EntersBattlefieldAbility(effect, "with seven omen counters on it"));
// At the beginning of your upkeep, remove an omen counter from Celestial Convergence. If there are no omen counters on Celestial Convergence, the player with the highest life total wins the game. If two or more players are tied for highest life total, the game is a draw.
Ability ability = new BeginningOfUpkeepTriggeredAbility(

View file

@ -21,7 +21,6 @@ import mage.constants.Zone;
import mage.filter.StaticFilters;
import mage.game.Game;
import mage.game.events.GameEvent;
import mage.game.events.GameEvent.EventType;
import mage.target.targetpointer.FixedTarget;
/**
@ -44,7 +43,7 @@ public final class ChancellorOfTheAnnex extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// Whenever an opponent casts a spell, counter it unless that player pays {1}.
this.addAbility(new SpellCastOpponentTriggeredAbility(Zone.BATTLEFIELD, new CounterUnlessPaysEffect(new GenericManaCost(1)), StaticFilters.FILTER_SPELL, false, SetTargetPointer.SPELL));
this.addAbility(new SpellCastOpponentTriggeredAbility(Zone.BATTLEFIELD, new CounterUnlessPaysEffect(new GenericManaCost(1)), StaticFilters.FILTER_SPELL_A, false, SetTargetPointer.SPELL));
}
private ChancellorOfTheAnnex(final ChancellorOfTheAnnex card) {

View file

@ -60,7 +60,7 @@ class CryptoplasmEffect extends OneShotEffect {
CryptoplasmEffect() {
super(Outcome.Copy);
this.staticText = "you may have {this} become a copy of another target creature, except it gains this ability";
this.staticText = "you may have {this} become a copy of another target creature, except it has this ability";
}
private CryptoplasmEffect(final CryptoplasmEffect effect) {

View file

@ -39,7 +39,8 @@ public final class Draco extends CardImpl {
this.addAbility(new SimpleStaticAbility(Zone.ALL, new DracoCostReductionEffect()).addHint(DomainHint.instance));
// Domain - At the beginning of your upkeep, sacrifice Draco unless you pay {10}. This cost is reduced by {2} for each basic land type among lands you control.
this.addAbility(new BeginningOfUpkeepTriggeredAbility(new DracoSacrificeUnlessPaysEffect(), TargetController.YOU, false));
this.addAbility(new BeginningOfUpkeepTriggeredAbility(new DracoSacrificeUnlessPaysEffect(), TargetController.YOU, false)
.setAbilityWord(AbilityWord.DOMAIN));
}
private Draco(final Draco card) {

View file

@ -37,7 +37,7 @@ public final class ElbrusTheBindingBlade extends CardImpl {
// Equipped creature gets +1/+0.
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(1, 0)));
// When equipped creature deals combat damage to a player, unattach Elbrus, the Binding Blade, then transform it.
this.addAbility(new DealsDamageToAPlayerAttachedTriggeredAbility(new ElbrusTheBindingBladeEffect(), "equipped", true));
this.addAbility(new DealsDamageToAPlayerAttachedTriggeredAbility(new ElbrusTheBindingBladeEffect(), "equipped", false));
// Equip {1}
this.addAbility(new EquipAbility(Outcome.BoostCreature, new GenericManaCost(1), new TargetControlledCreaturePermanent(), false));
}
@ -53,7 +53,7 @@ public final class ElbrusTheBindingBlade extends CardImpl {
}
class ElbrusTheBindingBladeEffect extends OneShotEffect {
public ElbrusTheBindingBladeEffect() {
ElbrusTheBindingBladeEffect() {
super(Outcome.BecomeCreature);
staticText = "unattach {this}, then transform it";
}
@ -80,4 +80,4 @@ class ElbrusTheBindingBladeEffect extends OneShotEffect {
return new ElbrusTheBindingBladeEffect(this);
}
}
}

View file

@ -68,7 +68,7 @@ class ElminsterReductionEffect extends CostModificationEffectImpl {
ElminsterReductionEffect() {
super(Duration.EndOfTurn, Outcome.Benefit, CostModificationType.REDUCE_COST);
staticText = " the next instant or sorcery spell you cast this turn costs {X} less to cast, " +
staticText = "the next instant or sorcery spell you cast this turn costs {X} less to cast, " +
"where X is the number of cards looked at while scrying this way";
}

View file

@ -24,7 +24,7 @@ public final class FeveredVisions extends CardImpl {
// At the beginning of each player's end step, that player draws a card. If the player is your opponent and has four or more cards in hand,
// Fevered Visions deals 2 damage to that player.
this.addAbility(new BeginningOfEndStepTriggeredAbility(new FeveredVisionsEffect(), TargetController.ANY, false));
this.addAbility(new BeginningOfEndStepTriggeredAbility(new FeveredVisionsEffect(), TargetController.EACH_PLAYER, false));
}
private FeveredVisions(final FeveredVisions card) {

View file

@ -35,7 +35,7 @@ public final class FirbolgFlutist extends CardImpl {
Ability ability = new EntersBattlefieldTriggeredAbility(
new GainControlTargetEffect(Duration.EndOfTurn), false
);
ability.addEffect(new UntapTargetEffect().setText("Untap that creature"));
ability.addEffect(new UntapTargetEffect().setText("Untap it"));
ability.addEffect(new GainAbilityTargetEffect(
HasteAbility.getInstance(), Duration.EndOfTurn
).setText("It gains haste"));
@ -43,7 +43,7 @@ public final class FirbolgFlutist extends CardImpl {
new MyriadAbility(), Duration.EndOfTurn
).setText("and myriad until end of turn"));
ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_CREATURE_YOU_DONT_CONTROL));
this.addAbility(ability.withFlavorWord("Captivating Performance"));
this.addAbility(ability.withFlavorWord("Enthralling Performance"));
}
private FirbolgFlutist(final FirbolgFlutist card) {

View file

@ -34,7 +34,7 @@ public final class FlameKinWarScout extends CardImpl {
Zone.BATTLEFIELD, new FlameKinWarScourEffect(),
StaticFilters.FILTER_ANOTHER_CREATURE, false,
SetTargetPointer.PERMANENT
));
).setTriggerPhrase("When another creature enters the battlefield, "));
}

View file

@ -28,10 +28,9 @@ public final class Foil extends CardImpl {
public Foil(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{U}{U}");
// You may discard an Island card and another card rather than pay Foil's mana cost.
Ability ability = new AlternativeCostSourceAbility(new DiscardTargetCost(new TargetCardInHand(filter)));
ability.addCost(new DiscardTargetCost(new TargetCardInHand(new FilterCard("another card"))));
ability.addCost(new DiscardTargetCost(new TargetCardInHand(new FilterCard("another card"))).setText("another card"));
this.addAbility(ability);
// Counter target spell.

View file

@ -25,7 +25,8 @@ public final class GemstoneMine extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.LAND},"");
// Gemstone Mine enters the battlefield with three mining counters on it.
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.MINING.createInstance(3))));
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.MINING.createInstance(3)),
"with three mining counters on it"));
// {T}, Remove a mining counter from Gemstone Mine: Add one mana of any color. If there are no mining counters on Gemstone Mine, sacrifice it.
Ability ability = new AnyColorManaAbility();

View file

@ -31,7 +31,8 @@ public final class GhituFireEater extends CardImpl {
this.toughness = new MageInt(2);
// {T}, Sacrifice Ghitu Fire-Eater: Ghitu Fire-Eater deals damage equal to its power to any target.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(new SourcePermanentPowerCount()), new TapSourceCost());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(new SourcePermanentPowerCount())
.setText("it deals damage equal to its power to any target"), new TapSourceCost());
ability.addCost(new SacrificeSourceCost());
ability.addTarget(new TargetAnyTarget());
this.addAbility(ability);

View file

@ -1,4 +1,3 @@
package mage.cards.g;
import java.util.UUID;
@ -17,7 +16,7 @@ import mage.constants.CardType;
import mage.constants.SubType;
import mage.constants.Duration;
import mage.constants.SuperType;
import mage.filter.common.FilterControlledCreaturePermanent;
import mage.filter.StaticFilters;
import mage.filter.common.FilterOpponentsCreaturePermanent;
import mage.game.permanent.token.TokenImpl;
@ -36,7 +35,7 @@ public final class GideonMartialParagon extends CardImpl {
this.setStartingLoyalty(5);
// +2: Untap all creatures you control. Those creatures get +1/+1 until end of turn.
LoyaltyAbility ability = new LoyaltyAbility(new UntapAllEffect(new FilterControlledCreaturePermanent()), 2);
LoyaltyAbility ability = new LoyaltyAbility(new UntapAllEffect(StaticFilters.FILTER_CONTROLLED_CREATURES), 2);
Effect effect = new BoostControlledEffect(1, 1, Duration.EndOfTurn);
effect.setText("Those creatures get +1/+1 until end of turn");
ability.addEffect(effect);

View file

@ -58,7 +58,7 @@ class GisaAndGeralfCastFromGraveyardEffect extends AsThoughEffectImpl {
GisaAndGeralfCastFromGraveyardEffect() {
super(AsThoughEffectType.PLAY_FROM_NOT_OWN_HAND_ZONE, Duration.WhileOnBattlefield, Outcome.PutCreatureInPlay);
staticText = "During each of your turns, you may cast a Zombie creature spell from your graveyard";
staticText = "Once during each of your turns, you may cast a Zombie creature spell from your graveyard";
}
private GisaAndGeralfCastFromGraveyardEffect(final GisaAndGeralfCastFromGraveyardEffect effect) {

View file

@ -1,4 +1,3 @@
package mage.cards.g;
import java.util.UUID;
@ -18,9 +17,9 @@ public final class GleamOfBattle extends CardImpl {
public GleamOfBattle(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.ENCHANTMENT},"{4}{R}{W}");
// Whenever a creature you control attacks, put a +1/+1 counter on it.
this.addAbility(new AttacksCreatureYouControlTriggeredAbility(new AddCountersTargetEffect(CounterType.P1P1.createInstance()), false, true));
this.addAbility(new AttacksCreatureYouControlTriggeredAbility(new AddCountersTargetEffect(CounterType.P1P1.createInstance())
.setText("put a +1/+1 counter on it"), false, true));
}
private GleamOfBattle(final GleamOfBattle card) {

View file

@ -40,7 +40,8 @@ public final class GravebreakerLamia extends CardImpl {
this.addAbility(LifelinkAbility.getInstance());
// When Gravebreaker Lamia enters the battlefield, search your library for a card, put it into your graveyard, then shuffle your library.
this.addAbility(new EntersBattlefieldTriggeredAbility(new SearchLibraryPutInGraveyardEffect(), false));
this.addAbility(new EntersBattlefieldTriggeredAbility(new SearchLibraryPutInGraveyardEffect()
.setText("search your library for a card, put it into your graveyard, then shuffle"), false));
// Spells you cast from your graveyard cost {1} less to cast.
this.addAbility(new SimpleStaticAbility(new SpellsCostReductionControllerEffect(filter, 1)));

View file

@ -62,7 +62,7 @@ class HalsinEmeraldArchdruidEffect extends ContinuousEffectImpl {
HalsinEmeraldArchdruidEffect() {
super(Duration.EndOfTurn, Outcome.Benefit);
staticText = "until end of turn, target token you control becomes a green Bear creature " +
"with base power and toughness 4/4 in addition to its other types and colors";
"with base power and toughness 4/4 in addition to its other colors and types";
}
private HalsinEmeraldArchdruidEffect(final HalsinEmeraldArchdruidEffect effect) {

View file

@ -7,7 +7,6 @@ import mage.abilities.effects.common.TapTargetEffect;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.TargetController;
import mage.filter.StaticFilters;
import mage.target.common.TargetCreaturePermanent;
@ -22,7 +21,7 @@ public final class HandsOfBinding extends CardImpl {
//Tap target creature an opponent controls. That creature doesn't untap during its controller's next untap step.
this.getSpellAbility().addEffect(new TapTargetEffect());
this.getSpellAbility().addEffect(new DontUntapInControllersNextUntapStepTargetEffect());
this.getSpellAbility().addEffect(new DontUntapInControllersNextUntapStepTargetEffect("that creature"));
this.getSpellAbility().addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_OPPONENTS_PERMANENT_CREATURE));
//Cipher
this.getSpellAbility().addEffect(new CipherEffect());

View file

@ -29,7 +29,7 @@ import java.util.UUID;
public final class HistoriansBoon extends CardImpl {
private static final FilterPermanent filter
= new FilterControlledEnchantmentPermanent("another nontoken enchantment");
= new FilterControlledEnchantmentPermanent("nontoken enchantment");
static {
filter.add(TokenPredicate.FALSE);
@ -61,6 +61,7 @@ class HistoriansBoonTriggeredAbility extends TriggeredAbilityImpl {
HistoriansBoonTriggeredAbility() {
super(Zone.BATTLEFIELD, new CreateTokenEffect(new AngelVigilanceToken()));
setTriggerPhrase("Whenever the final chapter ability of a Saga you control triggers, ");
}
private HistoriansBoonTriggeredAbility(final HistoriansBoonTriggeredAbility ability) {
@ -95,9 +96,4 @@ class HistoriansBoonTriggeredAbility extends TriggeredAbilityImpl {
return SagaAbility.isFinalAbility(stackObject.getStackAbility(), maxChapter);
}
@Override
public String getRule() {
return "Whenever the final chapter of a Saga you control triggers, " +
"create a 4/4 white Angel creature token with flying and vigilance.";
}
}

View file

@ -27,7 +27,8 @@ public final class HorrorOfTheBrokenLands extends CardImpl {
this.toughness = new MageInt(4);
// Whenever you cycle or discard another card, Horror of the Broken Lands gets +2/+1 until end of turn.
this.addAbility(new CycleOrDiscardControllerTriggeredAbility(new BoostSourceEffect(2, 1, Duration.EndOfTurn)));
this.addAbility(new CycleOrDiscardControllerTriggeredAbility(new BoostSourceEffect(2, 1, Duration.EndOfTurn))
.setTriggerPhrase("Whenever you cycle or discard another card, "));
// Cycling {B}
this.addAbility(new CyclingAbility(new ManaCostsImpl<>("{B}")));

View file

@ -22,10 +22,8 @@ import java.util.UUID;
*/
public final class HowlpackAlpha extends CardImpl {
private static final String ruleText = "At the beginning of your end step, create a 2/2 green Wolf creature token";
private static final FilterCreaturePermanent filter
= new FilterCreaturePermanent("Werewolf and Wolf creatures");
= new FilterCreaturePermanent("each other creature you control that's a Werewolf or a Wolf");
static {
filter.add(Predicates.or(

View file

@ -3,8 +3,8 @@ package mage.cards.i;
import mage.MageInt;
import mage.MageObject;
import mage.ObjectColor;
import mage.abilities.common.BeginningOfEndStepTriggeredAbility;
import mage.abilities.common.BeginningOfUpkeepTriggeredAbility;
import mage.abilities.common.BeginningOfYourEndStepTriggeredAbility;
import mage.abilities.costs.common.ExileFromGraveCost;
import mage.abilities.effects.common.DoIfCostPaid;
import mage.abilities.effects.common.ReturnSourceFromGraveyardToBattlefieldEffect;
@ -41,7 +41,7 @@ public final class Ichorid extends CardImpl {
this.addAbility(HasteAbility.getInstance());
// At the beginning of the end step, sacrifice Ichorid.
this.addAbility(new BeginningOfYourEndStepTriggeredAbility(new SacrificeSourceEffect(), false));
this.addAbility(new BeginningOfEndStepTriggeredAbility(new SacrificeSourceEffect(), TargetController.NEXT, false));
// At the beginning of your upkeep, if Ichorid is in your graveyard, you may exile a black creature card other than Ichorid from your graveyard. If you do, return Ichorid to the battlefield.
this.addAbility(new IchoridTriggerdAbility());

View file

@ -24,7 +24,7 @@ import mage.game.permanent.Permanent;
*/
public final class Immerwolf extends CardImpl {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Wolf and Werewolf creatures");
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Each other creature you control that's a Wolf or a Werewolf");
static {
filter.add(Predicates.or(SubType.WOLF.getPredicate(), SubType.WEREWOLF.getPredicate()));

View file

@ -52,7 +52,8 @@ public final class InsidiousMist extends CardImpl {
// Whenever Insideous Mist attacks and isn't blocked, you may pay {2}{B}. If you do, transform it.
this.addAbility(new TransformAbility());
this.addAbility(new AttacksAndIsNotBlockedTriggeredAbility(new DoIfCostPaid(new TransformSourceEffect(), new ManaCostsImpl<>("{2}{B}"), "Pay {2}{B} to transform?")));
this.addAbility(new AttacksAndIsNotBlockedTriggeredAbility(new DoIfCostPaid(new TransformSourceEffect()
.setText("transform it"), new ManaCostsImpl<>("{2}{B}"), "Pay {2}{B} to transform?")));
}
private InsidiousMist(final InsidiousMist card) {

View file

@ -38,7 +38,7 @@ public final class JunkGolem extends CardImpl {
// At the beginning of your upkeep, sacrifice Junk Golem unless you remove a +1/+1 counter from it.
this.addAbility(new BeginningOfUpkeepTriggeredAbility(
new SacrificeSourceUnlessPaysEffect(
new RemoveCountersSourceCost(CounterType.P1P1.createInstance())
new RemoveCountersSourceCost(CounterType.P1P1.createInstance()).setText("remove a +1/+1 counter from it")
), TargetController.YOU, false
));

View file

@ -52,7 +52,7 @@ class KaerveksTorchCostIncreaseEffect extends CostModificationEffectImpl {
KaerveksTorchCostIncreaseEffect() {
super(Duration.WhileOnStack, Outcome.Benefit, CostModificationType.INCREASE_COST);
staticText = "Spells that target {this} cost {2} more to cast";
staticText = "As long as {this} is on the stack, spells that target it cost {2} more to cast";
}
private KaerveksTorchCostIncreaseEffect(final KaerveksTorchCostIncreaseEffect effect) {

View file

@ -54,7 +54,8 @@ public final class KeldonBattlewagon extends CardImpl {
this.addAbility(new CantBlockAbility());
// When Keldon Battlewagon attacks, sacrifice it at end of combat.
this.addAbility(new AttacksTriggeredAbility(new CreateDelayedTriggeredAbilityEffect(new AtTheEndOfCombatDelayedTriggeredAbility(new SacrificeSourceEffect())), false));
this.addAbility(new AttacksTriggeredAbility(new CreateDelayedTriggeredAbilityEffect(new AtTheEndOfCombatDelayedTriggeredAbility(new SacrificeSourceEffect()))
.setText("sacrifice it at end of combat"), false).setTriggerPhrase("When {this} attacks, "));
// Tap an untapped creature you control: Keldon Battlewagon gets +X/+0 until end of turn, where X is the power of the creature tapped this way.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new KeldonBattlewagonBoostEffect(), new KeldonBattlewagonCost(new TargetControlledPermanent(filter))));
@ -126,9 +127,9 @@ class KeldonBattlewagonBoostEffect extends OneShotEffect {
@Override
public boolean apply(Game game, Ability source) {
Permanent KeldonBattlewagon = game.getPermanent(source.getSourceId());
Permanent keldonBattlewagon = game.getPermanent(source.getSourceId());
Permanent tappedCreature = getTargetPointer().getFirstTargetPermanentOrLKI(game, source);
if (tappedCreature != null && KeldonBattlewagon != null) {
if (tappedCreature != null && keldonBattlewagon != null) {
int amount = tappedCreature.getPower().getValue();
game.addEffect(new BoostSourceEffect(amount, 0, Duration.EndOfTurn), source);
}

View file

@ -48,7 +48,7 @@ class KembasLegionEffect extends ContinuousEffectImpl {
KembasLegionEffect() {
super(Duration.WhileOnBattlefield, Outcome.Benefit);
staticText = "{this} can block an additional creature for each Equipment attached to Kemba's Legion";
staticText = "{this} can block an additional creature each combat for each Equipment attached to {this}";
}
private KembasLegionEffect(final KembasLegionEffect effect) {

View file

@ -66,7 +66,7 @@ public final class KorvoldGleefulGlutton extends CardImpl {
new AddCountersSourceEffect(CounterType.P1P1.createInstance(), PermanentTypesInGraveyardCount.instance, true)
.setText("put X +1/+1 counters on {this}"),
false
);
).withRuleTextReplacement(false);
combatDamageAbility.addEffect(new DrawCardSourceControllerEffect(PermanentTypesInGraveyardCount.instance).setText("and draw X cards, where X is the number of permanent types among cards in your graveyard"));
combatDamageAbility.addHint(new ValueHint("Permanent types among cards in your graveyard", PermanentTypesInGraveyardCount.instance));
this.addAbility(combatDamageAbility);
@ -100,7 +100,7 @@ class KorvoldGleefulGluttonWatcher extends Watcher {
if (permanent != null) {
permanent.getCardType(game).forEach(type ->
map.computeIfAbsent(event.getPlayerId(), (key) -> new HashSet<>()).add(type)
map.computeIfAbsent(event.getPlayerId(), k -> new HashSet<>()).add(type)
);
}
}
@ -112,8 +112,8 @@ class KorvoldGleefulGluttonWatcher extends Watcher {
}
public int getNumberOfTypes(UUID playerId) {
return map.computeIfAbsent(playerId, (key) -> new HashSet<>()).size();
};
return map.computeIfAbsent(playerId, k -> new HashSet<>()).size();
}
}
enum CardTypesAmongSacrificedPermanentsCount implements DynamicValue {
@ -164,4 +164,4 @@ enum PermanentTypesInGraveyardCount implements DynamicValue {
return "permanent types among cards in your graveyard";
}
}
}

View file

@ -27,6 +27,7 @@ public final class KragmaWarcaller extends CardImpl {
private static final FilterControlledCreaturePermanent filter2 = new FilterControlledCreaturePermanent("Minotaur you control");
static {
filter1.add(SubType.MINOTAUR.getPredicate());
filter2.add(SubType.MINOTAUR.getPredicate());
}
public KragmaWarcaller(UUID ownerId, CardSetInfo setInfo) {
@ -43,7 +44,7 @@ public final class KragmaWarcaller extends CardImpl {
// Whenever a Minotaur you control attacks, it gets +2/+0 until end of turn.
Effect effect = new BoostTargetEffect(2,0, Duration.EndOfTurn);
effect.setText("it gets +2/+0 until end of turn");
this.addAbility(new AttacksCreatureYouControlTriggeredAbility(effect, false, filter1, true));
this.addAbility(new AttacksCreatureYouControlTriggeredAbility(effect, false, filter2, true));
}
private KragmaWarcaller(final KragmaWarcaller card) {

View file

@ -14,7 +14,7 @@ import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Duration;
import mage.constants.SubType;
import mage.filter.common.FilterControlledCreaturePermanent;
import mage.filter.StaticFilters;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.game.permanent.PermanentToken;
@ -38,9 +38,11 @@ public final class LegionLoyalist extends CardImpl {
this.addAbility(HasteAbility.getInstance());
//Battalion - Whenever Legion Loyalist and at least two other creatures attack,
//creatures you control gain first strike and trample until end of turn and can't be blocked by tokens this turn.
Ability ability = new BattalionAbility(new GainAbilityAllEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn, new FilterControlledCreaturePermanent()));
ability.addEffect(new GainAbilityAllEffect(TrampleAbility.getInstance(), Duration.EndOfTurn, new FilterControlledCreaturePermanent()));
ability.addEffect(new CantBeBlockedByTokenEffect());
Ability ability = new BattalionAbility(new GainAbilityAllEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn, StaticFilters.FILTER_CONTROLLED_CREATURES)
.setText("creatures you control gain first strike"));
ability.addEffect(new GainAbilityAllEffect(TrampleAbility.getInstance(), Duration.EndOfTurn, StaticFilters.FILTER_CONTROLLED_CREATURES)
.setText("and trample until end of turn"));
ability.addEffect(new LegionLoyalistCantBeBlockedByTokensEffect());
this.addAbility(ability);
}
@ -54,21 +56,21 @@ public final class LegionLoyalist extends CardImpl {
}
}
class CantBeBlockedByTokenEffect extends RestrictionEffect {
class LegionLoyalistCantBeBlockedByTokensEffect extends RestrictionEffect {
CantBeBlockedByTokenEffect() {
LegionLoyalistCantBeBlockedByTokensEffect() {
super(Duration.EndOfTurn);
staticText = "Creatures you control can't be blocked by tokens this turn";
staticText = "and can't be blocked by creature tokens this turn";
}
private CantBeBlockedByTokenEffect(final CantBeBlockedByTokenEffect effect) {
private LegionLoyalistCantBeBlockedByTokensEffect(final LegionLoyalistCantBeBlockedByTokensEffect effect) {
super(effect);
}
@Override
public void init(Ability source, Game game) {
affectedObjectsSet = true;
for (Permanent perm : game.getBattlefield().getActivePermanents(new FilterControlledCreaturePermanent(), source.getControllerId(), source, game)) {
for (Permanent perm : game.getBattlefield().getActivePermanents(StaticFilters.FILTER_CONTROLLED_CREATURES, source.getControllerId(), source, game)) {
affectedObjectList.add(new MageObjectReference(perm, game));
}
}
@ -84,7 +86,7 @@ class CantBeBlockedByTokenEffect extends RestrictionEffect {
}
@Override
public CantBeBlockedByTokenEffect copy() {
return new CantBeBlockedByTokenEffect(this);
public LegionLoyalistCantBeBlockedByTokensEffect copy() {
return new LegionLoyalistCantBeBlockedByTokensEffect(this);
}
}

View file

@ -28,7 +28,7 @@ public final class LimitsOfSolidarity extends CardImpl {
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
this.getSpellAbility().addEffect(new GainControlTargetEffect(Duration.EndOfTurn));
Effect effect = new UntapTargetEffect();
effect.setText("Untap it");
effect.setText("Untap that creature");
this.getSpellAbility().addEffect(effect);
effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn);
effect.setText("It gains haste until end of turn");

View file

@ -1,11 +1,9 @@
package mage.cards.l;
import java.util.UUID;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.effects.Effect;
import mage.abilities.effects.common.continuous.BoostTargetEffect;
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
import mage.abilities.keyword.FirstStrikeAbility;
@ -29,10 +27,10 @@ public final class LoomingSpires extends CardImpl {
this.addAbility(new EntersBattlefieldTappedAbility());
// When Looming Spires enters the battlefield, target creature gets +1/+1 and gain first strike until end of turn.
Effect effect = new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn);
effect.setText("and gains first strike");
Ability ability = new EntersBattlefieldTriggeredAbility(new BoostTargetEffect(1, 1, Duration.EndOfTurn), false);
ability.addEffect(effect);
Ability ability = new EntersBattlefieldTriggeredAbility(new BoostTargetEffect(1, 1, Duration.EndOfTurn)
.setText("target creature gets +1/+1"), false);
ability.addEffect(new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn)
.setText("and gains first strike until end of turn"));
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);

View file

@ -42,7 +42,7 @@ class MiseEffect extends OneShotEffect {
MiseEffect() {
super(Outcome.Detriment);
staticText = "then reveal the top card of your library. If that card has the chosen name, you draw three cards";
staticText = ", then reveal the top card of your library. If that card has the chosen name, you draw three cards";
}
private MiseEffect(final MiseEffect effect) {

View file

@ -80,7 +80,7 @@ class MoltenPrimordialEffect extends OneShotEffect {
MoltenPrimordialEffect() {
super(Outcome.GainControl);
this.staticText = "for each opponent, take control of up to one target creature that player controls until end of turn. Untap those creatures. They have haste until end of turn";
this.staticText = "for each opponent, gain control of up to one target creature that player controls until end of turn. Untap those creatures. They gain haste until end of turn";
}
private MoltenPrimordialEffect(final MoltenPrimordialEffect effect) {

View file

@ -53,7 +53,10 @@ class NeeraWildMageEffect extends OneShotEffect {
NeeraWildMageEffect() {
super(Outcome.Neutral);
staticText = "you may put it on the bottom of its owner's library. If you do, reveal cards from the top of your library until you reveal a nonland card. You may cast that card without paying its mana cost. Then put the rest on the bottom of your library in a random order. This ability triggers only once each turn.";
staticText = "you may put it on the bottom of its owner's library. " +
"If you do, reveal cards from the top of your library until you reveal a nonland card. " +
"You may cast that card without paying its mana cost. " +
"Then put all revealed cards not cast this way on the bottom of your library in a random order";
}
private NeeraWildMageEffect(final NeeraWildMageEffect effect) {

View file

@ -24,6 +24,8 @@ import java.util.UUID;
*/
public final class OnakkeOathkeeper extends CardImpl {
private static final FilterPlaneswalkerCard filter = new FilterPlaneswalkerCard("planeswalker card from your graveyard");
public OnakkeOathkeeper(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{W}");
@ -47,7 +49,7 @@ public final class OnakkeOathkeeper extends CardImpl {
Zone.GRAVEYARD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new ManaCostsImpl<>("{4}{W}{W}")
);
ability.addCost(new ExileSourceFromGraveCost());
ability.addTarget(new TargetCardInYourGraveyard(new FilterPlaneswalkerCard()));
ability.addTarget(new TargetCardInYourGraveyard(filter));
this.addAbility(ability);
}

View file

@ -19,7 +19,6 @@ import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.players.Player;
import mage.target.common.TargetCardInLibrary;
import mage.target.common.TargetControlledPermanent;
import java.util.Collection;
import java.util.UUID;
@ -62,7 +61,7 @@ class OswaldFiddlebenderEffect extends OneShotEffect {
OswaldFiddlebenderEffect() {
super(Outcome.Benefit);
staticText = "search your library for an artifact card with mana value equal to 1 plus the " +
"sacrificed artifact's mana value. Put that card onto the battlefield, then shuffle";
"sacrificed artifact's mana value, put it onto the battlefield, then shuffle";
}
private OswaldFiddlebenderEffect(final OswaldFiddlebenderEffect effect) {

View file

@ -38,7 +38,8 @@ public final class OverchargedAmalgam extends CardImpl {
this.addAbility(new ExploitAbility());
// When Overcharged Amalgam exploits a creature, counter target spell, activated ability, or triggered ability.
Ability ability = new ExploitCreatureTriggeredAbility(new CounterTargetEffect());
Ability ability = new ExploitCreatureTriggeredAbility(new CounterTargetEffect()
.setText("counter target spell, activated ability, or triggered ability"));
ability.addTarget(new TargetStackObject());
this.addAbility(ability);
}

View file

@ -49,7 +49,7 @@ class PainiacEffect extends OneShotEffect {
PainiacEffect() {
super(Outcome.Benefit);
this.staticText = "Roll a six-sided die. {this} gets +X/+0 until end of turn, where X is the result";
this.staticText = "roll a six-sided die. {this} gets +X/+0 until end of turn, where X is the result";
}
private PainiacEffect(final PainiacEffect effect) {

View file

@ -36,7 +36,7 @@ public final class PyreZombie extends CardImpl {
new DoIfCostPaid(new ReturnToHandSourceEffect().setText("return {this} to your hand"), new ManaCostsImpl<>("{1}{B}{B}")),
TargetController.YOU, false));
// {1}{R}{R}, Sacrifice Pyre Zombie: Pyre Zombie deals 2 damage to any target.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(2), new ManaCostsImpl<>("{1}{R}{R}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(2, "it"), new ManaCostsImpl<>("{1}{R}{R}"));
ability.addCost(new SacrificeSourceCost());
ability.addTarget(new TargetAnyTarget());
this.addAbility(ability);

View file

@ -1,8 +1,5 @@
package mage.cards.r;
import java.util.UUID;
import mage.abilities.effects.Effect;
import mage.abilities.effects.common.UntapAllControllerEffect;
import mage.abilities.effects.common.continuous.GainAbilityAllEffect;
import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
@ -15,7 +12,8 @@ import mage.constants.CardType;
import mage.constants.Duration;
import mage.constants.SpellAbilityType;
import mage.filter.StaticFilters;
import mage.filter.common.FilterControlledCreaturePermanent;
import java.util.UUID;
/**
*
@ -28,17 +26,19 @@ public final class ReadyWilling extends SplitCard {
// Ready
// Creatures you control are indestructible this turn. Untap each creature you control.
Effect effect = new GainAbilityAllEffect(IndestructibleAbility.getInstance(), Duration.EndOfTurn, new FilterControlledCreaturePermanent("Creatures you controll"), false);
effect.setText("Creatures you control are indestructible this turn");
getLeftHalfCard().getSpellAbility().addEffect(effect);
getLeftHalfCard().getSpellAbility().addEffect(new UntapAllControllerEffect(new FilterControlledCreaturePermanent(), "Untap each creature you control"));
getLeftHalfCard().getSpellAbility().addEffect(new GainAbilityAllEffect(IndestructibleAbility.getInstance(),
Duration.EndOfTurn, StaticFilters.FILTER_CONTROLLED_CREATURES, false));
getLeftHalfCard().getSpellAbility().addEffect(new UntapAllControllerEffect(StaticFilters.FILTER_CONTROLLED_CREATURES,
"Untap each creature you control"));
// Willing
// Creatures you control gain deathtouch and lifelink until end of turn.
getRightHalfCard().getSpellAbility().addEffect(new GainAbilityControlledEffect(DeathtouchAbility.getInstance(), Duration.EndOfTurn, StaticFilters.FILTER_PERMANENT_CREATURES));
effect = new GainAbilityControlledEffect(LifelinkAbility.getInstance(), Duration.EndOfTurn, StaticFilters.FILTER_PERMANENT_CREATURES);
effect.setText("Creatures you control gain lifelink until end of turn");
getRightHalfCard().getSpellAbility().addEffect(effect);
getRightHalfCard().getSpellAbility().addEffect(new GainAbilityControlledEffect(DeathtouchAbility.getInstance(),
Duration.EndOfTurn, StaticFilters.FILTER_PERMANENT_CREATURES)
.setText("creatures you control gain deathtouch"));
getRightHalfCard().getSpellAbility().addEffect(new GainAbilityControlledEffect(LifelinkAbility.getInstance(),
Duration.EndOfTurn, StaticFilters.FILTER_PERMANENT_CREATURES)
.setText("and lifelink until end of turn"));
}

View file

@ -1,5 +1,3 @@
package mage.cards.r;
import java.util.UUID;
@ -18,7 +16,6 @@ import mage.filter.common.FilterCreaturePermanent;
* @author LevelX2
*/
public final class RiotControl extends CardImpl {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature your opponents control");
@ -29,9 +26,9 @@ public final class RiotControl extends CardImpl {
public RiotControl(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{W}");
// Gain 1 life for each creature your opponents control. Prevent all damage that would be dealt to you this turn.
this.getSpellAbility().addEffect(new GainLifeEffect(new PermanentsOnBattlefieldCount(filter)));
this.getSpellAbility().addEffect(new GainLifeEffect(new PermanentsOnBattlefieldCount(filter))
.setText("You gain 1 life for each creature your opponents control"));
this.getSpellAbility().addEffect(new PreventDamageToControllerEffect(Duration.EndOfTurn));
}

View file

@ -31,7 +31,7 @@ public final class ScionOfHalaster extends CardImpl {
this.addAbility(new SimpleStaticAbility(new GainAbilityAllEffect(
new SimpleStaticAbility(new ScionOfHalasterReplacementEffect()),
Duration.WhileOnBattlefield, StaticFilters.FILTER_CREATURES_OWNED_COMMANDER
)));
).withForceQuotes()));
}
private ScionOfHalaster(final ScionOfHalaster card) {

View file

@ -38,7 +38,7 @@ import mage.target.targetadjustment.TargetAdjuster;
*/
public final class SimicManipulator extends CardImpl {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("with power less than or equal to the number of +1/+1 counters removed this way");
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with power less than or equal to the number of +1/+1 counters removed this way");
public SimicManipulator(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{U}{U}");

View file

@ -26,9 +26,11 @@ public final class SkarrgTheRagePits extends CardImpl {
public SkarrgTheRagePits(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.LAND},"");
this.addAbility(new ColorlessManaAbility());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 1, Duration.EndOfTurn), new ManaCostsImpl<>("{R}{G}"));
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 1, Duration.EndOfTurn)
.setText("target creature gets +1/+1"), new ManaCostsImpl<>("{R}{G}"));
ability.addCost(new TapSourceCost());
ability.addEffect(new GainAbilityTargetEffect(TrampleAbility.getInstance(), Duration.EndOfTurn));
ability.addEffect(new GainAbilityTargetEffect(TrampleAbility.getInstance(), Duration.EndOfTurn)
.setText("and gains trample until end of turn"));
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);
}

View file

@ -29,7 +29,7 @@ import java.util.UUID;
*/
public final class SkirkDrillSergeant extends CardImpl {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("or another Goblin");
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Goblin");
static {
filter.add(SubType.GOBLIN.getPredicate());

View file

@ -48,7 +48,7 @@ public final class SmeltWardGatekeepers extends CardImpl {
Ability ability = new ConditionalInterveningIfTriggeredAbility(
new EntersBattlefieldTriggeredAbility(new GainControlTargetEffect(Duration.EndOfTurn)),
gatesCondition,
"When {this} enters the battlefield, if you control two or more Gates, gain control of target creature an opponent controls until end of turn. Untap that creature. That creature gains haste until end of turn.");
"When {this} enters the battlefield, if you control two or more Gates, gain control of target creature an opponent controls until end of turn. Untap that creature. It gains haste until end of turn.");
ability.addEffect(new UntapTargetEffect());
ability.addEffect(new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn));
Target target = new TargetCreaturePermanent(StaticFilters.FILTER_OPPONENTS_PERMANENT_CREATURE);

View file

@ -37,7 +37,7 @@ public final class SoulBurn extends CardImpl {
// Spend only black or red mana on X.
this.addAbility(new SimpleStaticAbility(
Zone.ALL, new InfoEffect("Spend only black or red mana on X")).setRuleAtTheTop(true)
Zone.ALL, new InfoEffect("Spend only black and/or red mana on X")).setRuleAtTheTop(true)
);
// Soul Burn deals X damage to any target. You gain life equal to the damage dealt for each black mana spent on X; not more life than the player's life total before Soul Burn dealt damage, or the creature's toughness.

View file

@ -13,7 +13,6 @@ import mage.abilities.keyword.EnchantAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.*;
import mage.filter.FilterCard;
import mage.filter.StaticFilters;
import mage.game.Game;
import mage.game.permanent.Permanent;
@ -68,7 +67,7 @@ class SoulRansomEffect extends OneShotEffect {
SoulRansomEffect() {
super(Outcome.Benefit);
this.staticText = "{this}'s controller sacrifices it, then draws two cards. Only any opponent may activate this ability";
this.staticText = "{this}'s controller sacrifices it, then draws two cards. Only your opponents may activate this ability";
}
private SoulRansomEffect(final SoulRansomEffect effect) {

View file

@ -38,7 +38,8 @@ public final class SpellbindingSoprano extends CardImpl {
this.toughness = new MageInt(2);
// Whenever Spellbinding Soprano attacks, instant and sorcery spells you cast this turn cost {1} less to cast.
this.addAbility(new AttacksTriggeredAbility(new SpellsCostReductionControllerEffect(filter, 1).setDuration(Duration.EndOfTurn)));
this.addAbility(new AttacksTriggeredAbility(new SpellsCostReductionControllerEffect(filter, 1).setDuration(Duration.EndOfTurn)
.setText("instant and sorcery spells you cast this turn cost {1} less to cast")));
// Encore {3}{R}
this.addAbility(new EncoreAbility(new ManaCostsImpl<>("{3}{R}")));

View file

@ -50,7 +50,7 @@ class StickTogetherEffect extends OneShotEffect {
StickTogetherEffect() {
super(Outcome.Benefit);
staticText = "each player choose a party from among creatures they control, then sacrifices the rest";
staticText = "each player chooses a party from among creatures they control, then sacrifices the rest";
}
private StickTogetherEffect(final StickTogetherEffect effect) {
@ -66,7 +66,7 @@ class StickTogetherEffect extends OneShotEffect {
public boolean apply(Game game, Ability source) {
Set<UUID> toKeep = new HashSet<>();
for (UUID playerId : game.getState().getPlayersInRange(source.getControllerId(), game)) {
Player player = game.getPlayer(source.getControllerId());
Player player = game.getPlayer(playerId);
if (player == null) {
continue;
}
@ -94,10 +94,10 @@ class StickTogetherTarget extends TargetPermanent {
SubType.WARRIOR,
SubType.WIZARD
);
private static final FilterPermanent filter = new FilterControlledPermanent("a party");
private static final FilterPermanent filterParty = new FilterControlledPermanent("a party");
static {
filter.add(Predicates.or(
filterParty.add(Predicates.or(
SubType.CLERIC.getPredicate(),
SubType.ROGUE.getPredicate(),
SubType.WARRIOR.getPredicate(),
@ -106,7 +106,7 @@ class StickTogetherTarget extends TargetPermanent {
}
StickTogetherTarget() {
super(0, 4, filter, true);
super(0, 4, filterParty, true);
}
private StickTogetherTarget(final StickTogetherTarget target) {
@ -146,7 +146,7 @@ class StickTogetherTarget extends TargetPermanent {
static int checkTargetCount(Ability source, Game game) {
List<Permanent> permanents = game
.getBattlefield()
.getActivePermanents(filter, source.getControllerId(), source, game);
.getActivePermanents(filterParty, source.getControllerId(), source, game);
return subTypeAssigner.getRoleCount(new CardsImpl(permanents), game);
}
}

View file

@ -25,7 +25,7 @@ public final class StructuralCollapse extends CardImpl {
this.getSpellAbility().addEffect(new SacrificeEffect(new FilterArtifactPermanent(), 1, "Target player"));
this.getSpellAbility().addEffect(new SacrificeEffect(StaticFilters.FILTER_LANDS, 1, "Target player")
.setText("and a land"));
this.getSpellAbility().addEffect(new DamageTargetEffect(2));
this.getSpellAbility().addEffect(new DamageTargetEffect(2, true, "that player"));
this.getSpellAbility().addTarget(new TargetPlayer());
}

View file

@ -55,9 +55,9 @@ public final class SwoopingPteranodon extends CardImpl {
// It gains flying and haste until end of turn.
// At the beginning of the next end step, target land deals 3 damage to that creature.
Ability ability = new EntersBattlefieldThisOrAnotherTriggeredAbility(
new GainControlTargetEffect(Duration.EndOfTurn), filter, true, true);
new GainControlTargetEffect(Duration.EndOfTurn), filter, false, true);
ability.addEffect(new UntapTargetEffect().setText("Untap that creature"));
ability.addEffect(new GainAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn).setText("It gains flying "));
ability.addEffect(new GainAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn).setText("It gains flying"));
ability.addEffect(new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn).setText("and haste until end of turn."));
ability.addEffect(new SwoopingPteranodonCreateDelayedTriggerEffect());
@ -149,4 +149,4 @@ class SwoopingPteranodonDamageEffect extends OneShotEffect {
return new SwoopingPteranodonDamageEffect(this);
}
}
}

View file

@ -44,7 +44,7 @@ class TheFallenEffect extends OneShotEffect {
TheFallenEffect() {
super(Outcome.Damage);
this.staticText = "{this} deals 1 damage to each opponent or planeswalker it has dealt damage to this game";
this.staticText = "{this} deals 1 damage to each opponent and planeswalker it has dealt damage to this game";
}
private TheFallenEffect(final TheFallenEffect effect) {
@ -73,7 +73,7 @@ class TheFallenEffect extends OneShotEffect {
class TheFallenWatcher extends Watcher {
private Map<UUID, Set<UUID>> playersAndWalkersDealtDamageThisGame = new HashMap<>(); // Map<creatureId, Set<playerId>>
private final Map<UUID, Set<UUID>> playersAndWalkersDealtDamageThisGame = new HashMap<>(); // Map<creatureId, Set<playerId>>
public TheFallenWatcher() {
super(WatcherScope.GAME);

View file

@ -127,6 +127,7 @@ class TheSpaceFamilyGoblinsonTriggeredAbility extends TriggeredAbilityImpl {
TheSpaceFamilyGoblinsonTriggeredAbility() {
super(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.P1P1.createInstance()));
setTriggerPhrase("Whenever you roll a die, ");
}
private TheSpaceFamilyGoblinsonTriggeredAbility(final TheSpaceFamilyGoblinsonTriggeredAbility ability) {
@ -148,8 +149,4 @@ class TheSpaceFamilyGoblinsonTriggeredAbility extends TriggeredAbilityImpl {
return isControlledBy(event.getPlayerId());
}
@Override
public String getRule() {
return "Whenever you roll a die, put a +1/+1 counter on {this}";
}
}

View file

@ -2,7 +2,7 @@ package mage.cards.t;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldAbility;
import mage.abilities.common.AsEntersBattlefieldAbility;
import mage.abilities.effects.OneShotEffect;
import mage.abilities.keyword.FlyingAbility;
import mage.cards.CardImpl;
@ -35,7 +35,7 @@ public final class ThiefOfBlood extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// As Thief of Blood enters the battlefield, remove all counters from all permanents. Thief of Blood enters the battlefield with a +1/+1 counter on it for each counter removed this way.
this.addAbility(new EntersBattlefieldAbility(new ThiefOfBloodEffect(), null, "As {this} enters the battlefield, remove all counters from all permanents. {this} enters the battlefield with a +1/+1 counter on it for each counter removed this way", null));
this.addAbility(new AsEntersBattlefieldAbility(new ThiefOfBloodEffect()));
}
private ThiefOfBlood(final ThiefOfBlood card) {

View file

@ -40,7 +40,8 @@ public final class TinStreetMarket extends CardImpl {
// Enchanted land has "{T}, Discard a card: Draw a card."
Ability gainAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new TapSourceCost());
gainAbility.addCost(new DiscardCardCost());
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(gainAbility, AttachmentType.AURA)));
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(gainAbility, AttachmentType.AURA,
Duration.WhileOnBattlefield, null, "land")));
}
@ -53,4 +54,3 @@ public final class TinStreetMarket extends CardImpl {
return new TinStreetMarket(this);
}
}

View file

@ -43,7 +43,7 @@ public final class TreacherousVampire extends CardImpl {
new DoUnlessControllerPaysEffect(
new SacrificeSourceEffect(),
new ExileFromGraveCost(new TargetCardInYourGraveyard())
), false
).setText("sacrifice it unless you exile a card from your graveyard"), false
));
// Threshold - As long as seven or more cards are in your graveyard, Treacherous Vampire gets +2/+2 and has "When Treacherous Vampire dies, you lose 6 life."

View file

@ -43,7 +43,7 @@ public final class UbulSarGatekeepers extends CardImpl {
Ability ability = new ConditionalInterveningIfTriggeredAbility(
new EntersBattlefieldTriggeredAbility(new BoostTargetEffect(-2, -2, Duration.EndOfTurn)),
gatesCondition,
"Whenever {this} enters the battlefield, if you control two or more Gates, target creature an opponent controls gets -2/-2 until end of turn.");
"When {this} enters the battlefield, if you control two or more Gates, target creature an opponent controls gets -2/-2 until end of turn.");
Target target = new TargetCreaturePermanent(StaticFilters.FILTER_OPPONENTS_PERMANENT_CREATURE);
ability.addTarget(target);
ability.addHint(new ConditionHint(gatesCondition, "You control two or more Gates"));

View file

@ -32,7 +32,7 @@ public final class UndercellarSweep extends CardImpl {
new AttacksWithCreaturesTriggeredAbility(
new CreateTokenEffect(new SoldierToken(), 2, true, true), 1
), UndercellarSweepCondition.instance, "Whenever you attack, if you or a player you're attacking " +
"has the initiative, you create two 1/1 white Soldier creature token that are tapped and attacking."
"has the initiative, you create two 1/1 white Soldier creature tokens that are tapped and attacking."
));
}
@ -63,4 +63,4 @@ enum UndercellarSweepCondition implements Condition {
.map(game.getCombat()::getDefenderId)
.anyMatch(game.getInitiativeId()::equals);
}
}
}

View file

@ -24,7 +24,8 @@ public final class UnderworldFires extends CardImpl {
new FilterCreatureOrPlaneswalkerPermanent("creature and each planeswalker")));
// If a permanent dealt damage this way would die this turn, exile it instead.
this.getSpellAbility().addEffect(new DealtDamageToCreatureBySourceDies(this, Duration.EndOfTurn));
this.getSpellAbility().addEffect(new DealtDamageToCreatureBySourceDies(this, Duration.EndOfTurn)
.setText("If a permanent dealt damage this way would die this turn, exile it instead"));
this.getSpellAbility().addWatcher(new DamagedByWatcher(false));
}

View file

@ -60,8 +60,9 @@ public final class VaevictisAsmadiTheDire extends CardImpl {
class VaevictisAsmadiTheDireTriggeredAbility extends TriggeredAbilityImpl {
public VaevictisAsmadiTheDireTriggeredAbility() {
VaevictisAsmadiTheDireTriggeredAbility() {
super(Zone.BATTLEFIELD, new VaevictisAsmadiTheDireEffect(), false);
setTriggerPhrase("Whenever {this} attacks, ");
}
private VaevictisAsmadiTheDireTriggeredAbility(final VaevictisAsmadiTheDireTriggeredAbility ability) {
@ -97,14 +98,6 @@ class VaevictisAsmadiTheDireTriggeredAbility extends TriggeredAbilityImpl {
return true;
}
@Override
public String getRule() {
return "Whenever {this} attacks, for each player, "
+ "choose target permanent that player controls. "
+ "Those players sacrifice those permanents. "
+ "Each player who sacrificed a permanent this way reveals the top card of their library, "
+ "then puts it onto the battlefield if it's a permanent card";
}
}
class VaevictisAsmadiTheDireEffect extends OneShotEffect {

View file

@ -32,13 +32,16 @@ public final class Vebulid extends CardImpl {
this.toughness = new MageInt(0);
// Vebulid enters the battlefield with a +1/+1 counter on it.
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(1))));
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(1)),
"with a +1/+1 counter on it"));
// At the beginning of your upkeep, you may put a +1/+1 counter on Vebulid.
this.addAbility(new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance()), TargetController.YOU, true));
// When Vebulid attacks or blocks, destroy it at end of combat.
this.addAbility(new AttacksOrBlocksTriggeredAbility(new CreateDelayedTriggeredAbilityEffect(new AtTheEndOfCombatDelayedTriggeredAbility(new DestroySourceEffect())), false));
this.addAbility(new AttacksOrBlocksTriggeredAbility(new CreateDelayedTriggeredAbilityEffect(
new AtTheEndOfCombatDelayedTriggeredAbility(new DestroySourceEffect()))
.setText("destroy it at end of combat"), false));
}
private Vebulid(final Vebulid card) {

View file

@ -28,7 +28,7 @@ public final class ViashinoCutthroat extends CardImpl {
// Haste
this.addAbility(HasteAbility.getInstance());
// At the beginning of the end step, return Viashino Cutthroat to its owner's hand.
this.addAbility(new BeginningOfEndStepTriggeredAbility(new ReturnToHandSourceEffect(true), TargetController.ANY, false));
this.addAbility(new BeginningOfEndStepTriggeredAbility(new ReturnToHandSourceEffect(true), TargetController.NEXT, false));
}
private ViashinoCutthroat(final ViashinoCutthroat card) {

View file

@ -1,7 +1,6 @@
package mage.cards.w;
import mage.abilities.Ability;
import mage.abilities.Mode;
import mage.abilities.common.BeginningOfUpkeepTriggeredAbility;
import mage.abilities.effects.OneShotEffect;
import mage.cards.CardImpl;
@ -39,13 +38,13 @@ public final class WheelOfTorture extends CardImpl {
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";
WheelOfTortureEffect() {
super(Outcome.Damage);
this.staticText = "{this} deals X damage to that player, where X is 3 minus the number of cards in their hand";
}
public WheelOfTortureEffect() {
super(Outcome.Damage);
private WheelOfTortureEffect(final WheelOfTortureEffect effect) {
super(effect);
}
@Override

View file

@ -30,7 +30,7 @@ public final class WindingCanyons extends CardImpl {
// {2}, {tap}: Until end of turn, you may cast creature spells as though they had flash.
Effect effect = new AddContinuousEffectToGame(new CastAsThoughItHadFlashAllEffect(Duration.EndOfTurn, StaticFilters.FILTER_CARD_CREATURE));
effect.setText("Until end of turn, you may cast creature spells as though they had flash.");
effect.setText("you may cast creature spells this turn as though they had flash");
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new GenericManaCost(2));
ability.addCost(new TapSourceCost());
this.addAbility(ability);

View file

@ -32,7 +32,8 @@ public final class WormfangManta extends CardImpl {
// When Wormfang Manta enters the battlefield, you skip your next turn.
this.addAbility(new EntersBattlefieldTriggeredAbility(new SkipNextTurnSourceEffect()));
// When Wormfang Manta leaves the battlefield, you take an extra turn after this one.
this.addAbility(new LeavesBattlefieldTriggeredAbility(new AddExtraTurnControllerEffect(), false));
this.addAbility(new LeavesBattlefieldTriggeredAbility(new AddExtraTurnControllerEffect()
.setText("you take an extra turn after this one"), false));
}
private WormfangManta(final WormfangManta card) {

View file

@ -226,7 +226,7 @@ public abstract class TriggeredAbilityImpl extends AbilityImpl implements Trigge
}
}
if (replaceRuleText && triggerPhrase != null) {
superRule = superRule.replaceFirst("^((?:you may )?sacrifice |(put|remove) an? [^ ]+ counter (on|from) |return |transform |untap |regenerate )?\\{this\\}", "$1it");
superRule = superRule.replaceFirst("^((?:you may )?sacrifice |(put|remove) [^ ]+ [^ ]+ counters? (on|from) |return |transform |untap |regenerate )?\\{this\\}", "$1it");
}
sb.append(superRule);
if (triggersOnceEachTurn) {

View file

@ -18,9 +18,9 @@ import mage.game.events.GameEvent;
*/
public class BecomesAttachedToCreatureSourceEffect extends ReplacementEffectImpl {
protected Effects baseEffects = new Effects();
protected String text;
protected Condition condition;
private final Effects baseEffects;
private final String text;
private final Condition condition;
public BecomesAttachedToCreatureSourceEffect(Effect baseEffect) {
this(baseEffect, "");
@ -32,6 +32,7 @@ public class BecomesAttachedToCreatureSourceEffect extends ReplacementEffectImpl
public BecomesAttachedToCreatureSourceEffect(Effect baseEffect, Condition condition, String text) {
super(Duration.WhileOnBattlefield, baseEffect.getOutcome(), false);
this.baseEffects = new Effects();
this.baseEffects.add(baseEffect);
this.text = text;
this.condition = condition;

View file

@ -1,4 +1,3 @@
package mage.abilities.effects;
import mage.MageObject;
@ -20,11 +19,11 @@ import mage.players.Player;
*/
public class EntersBattlefieldEffect extends ReplacementEffectImpl {
protected Effects baseEffects = new Effects();
protected String text;
protected Condition condition;
protected boolean optional;
protected EnterEventType enterEventType;
private final Effects baseEffects;
private final String text;
private final Condition condition;
private final boolean optional;
private final EnterEventType enterEventType;
public static final String SOURCE_CAST_SPELL_ABILITY = "sourceCastSpellAbility";
@ -46,6 +45,7 @@ public class EntersBattlefieldEffect extends ReplacementEffectImpl {
public EntersBattlefieldEffect(Effect baseEffect, Condition condition, String text, boolean selfScope, boolean optional, EnterEventType enterEventType) {
super(Duration.WhileOnBattlefield, baseEffect.getOutcome(), selfScope);
this.baseEffects = new Effects();
this.baseEffects.add(baseEffect);
this.enterEventType = enterEventType;
this.text = text;
@ -83,12 +83,8 @@ public class EntersBattlefieldEffect extends ReplacementEffectImpl {
@Override
public boolean applies(GameEvent event, Ability source, Game game) {
if (event.getTargetId().equals(source.getSourceId())) {
if (condition == null || condition.apply(game, source)) {
return true;
}
}
return false;
return event.getTargetId().equals(source.getSourceId())
&& (condition == null || condition.apply(game, source));
}
@Override

View file

@ -43,6 +43,9 @@ public class AddContinuousEffectToGame extends OneShotEffect {
@Override
public String getText(Mode mode) {
if (staticText != null && !staticText.isEmpty()) {
return staticText;
}
return effects.getText(mode);
}
}

View file

@ -21,6 +21,7 @@ public class DontUntapInControllersNextUntapStepSourceEffect extends ContinuousR
protected DontUntapInControllersNextUntapStepSourceEffect(final DontUntapInControllersNextUntapStepSourceEffect effect) {
super(effect);
this.validForTurnNum = effect.validForTurnNum;
}
@Override

View file

@ -20,7 +20,7 @@ public class ExileCardYouChooseTargetOpponentEffect extends OneShotEffect {
public ExileCardYouChooseTargetOpponentEffect(FilterCard filter) {
super(Outcome.Discard);
this.staticText = "target opponent reveals their hand. You choose "
+ filter.getMessage() + " from it and exile that card";
+ filter.getMessage() + (filter.getMessage().contains("from it") ? "" : " from it") + " and exile that card";
this.filter = filter;
}

View file

@ -8,7 +8,6 @@ import mage.constants.Outcome;
import mage.constants.SubLayer;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.util.CardUtil;
/**
* @author mzulch
@ -17,14 +16,22 @@ public class CanBlockAdditionalCreatureTargetEffect extends ContinuousEffectImpl
protected int amount;
/**
* Need to set text manually
* Target can block an additional creature this turn
*/
public CanBlockAdditionalCreatureTargetEffect() {
this(Duration.EndOfTurn, 1);
}
/**
* Need to set text manually
* @param duration of effect
* @param amount 0 = any number
*/
public CanBlockAdditionalCreatureTargetEffect(Duration duration, int amount) {
super(duration, Outcome.Benefit);
this.amount = amount;
staticText = setText();
}
protected CanBlockAdditionalCreatureTargetEffect(final CanBlockAdditionalCreatureTargetEffect effect) {
@ -59,24 +66,6 @@ public class CanBlockAdditionalCreatureTargetEffect extends ContinuousEffectImpl
return false;
}
private String setText() {
String text = "target can block ";
switch (amount) {
case 0:
text += "any number of creatures";
break;
default:
text += CardUtil.numberToText(amount, "an") + " additional creature" + (amount > 1 ? "s" : "");
}
if (duration == Duration.EndOfTurn) {
text += " this turn";
}
if (duration == Duration.WhileOnBattlefield) {
text += " each combat";
}
return text;
}
@Override
public boolean hasLayer(Layer layer) {
return layer == Layer.RulesEffects;