diff --git a/Mage.Sets/src/mage/cards/c/ChronomanticEscape.java b/Mage.Sets/src/mage/cards/c/ChronomanticEscape.java index a6057b39bc..955d974369 100644 --- a/Mage.Sets/src/mage/cards/c/ChronomanticEscape.java +++ b/Mage.Sets/src/mage/cards/c/ChronomanticEscape.java @@ -30,7 +30,7 @@ public final class ChronomanticEscape extends CardImpl { getSpellAbility().addEffect(new CantAttackYouAllEffect(Duration.UntilYourNextTurn, StaticFilters.FILTER_PERMANENT_CREATURES)); getSpellAbility().addEffect(new ExileSpellEffect()); Effect effect = new AddCountersSourceEffect(CounterType.TIME.createInstance(), StaticValue.get(3), true, true); - effect.setText("with 3 time counters on it"); + effect.setText("with three time counters on it"); getSpellAbility().addEffect(effect); // Suspend 3-{2}{W} diff --git a/Mage.Sets/src/mage/cards/c/CyclicalEvolution.java b/Mage.Sets/src/mage/cards/c/CyclicalEvolution.java index b6d3c453d1..daf7599d14 100644 --- a/Mage.Sets/src/mage/cards/c/CyclicalEvolution.java +++ b/Mage.Sets/src/mage/cards/c/CyclicalEvolution.java @@ -30,7 +30,7 @@ public final class CyclicalEvolution extends CardImpl { getSpellAbility().addTarget(new TargetCreaturePermanent()); getSpellAbility().addEffect(new ExileSpellEffect()); Effect effect = new AddCountersSourceEffect(CounterType.TIME.createInstance(), StaticValue.get(3), true, true); - effect.setText("with 3 time counters on it"); + effect.setText("with three time counters on it"); getSpellAbility().addEffect(effect); // Suspend 3-{2}{G} diff --git a/Mage.Sets/src/mage/cards/d/DustOfMoments.java b/Mage.Sets/src/mage/cards/d/DustOfMoments.java index d390fa5b6f..bae8372b21 100644 --- a/Mage.Sets/src/mage/cards/d/DustOfMoments.java +++ b/Mage.Sets/src/mage/cards/d/DustOfMoments.java @@ -1,32 +1,23 @@ - package mage.cards.d; -import java.util.List; -import java.util.Locale; -import java.util.UUID; -import mage.MageObject; import mage.abilities.Ability; import mage.abilities.Mode; -import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; import mage.constants.Outcome; -import mage.counters.Counter; import mage.counters.CounterType; -import mage.filter.Filter; -import mage.filter.FilterCard; -import mage.filter.FilterPermanent; +import mage.filter.StaticFilters; +import mage.filter.common.FilterPermanentOrSuspendedCard; import mage.game.Game; import mage.game.permanent.Permanent; -import mage.players.Player; + +import java.util.UUID; /** - * - * @author Gal Lerman - * + * @author TheElk801 */ public final class DustOfMoments extends CardImpl { @@ -34,11 +25,10 @@ public final class DustOfMoments extends CardImpl { super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{2}{W}"); // Choose one - Remove two time counters from each permanent and each suspended card - this.getSpellAbility().addEffect(new RemoveCountersEffect()); + this.getSpellAbility().addEffect(new DustOfMomentsEffect(true)); // Or put two time counters on each permanent with a time counter on it and each suspended card - Mode mode = new Mode(new AddCountersEffect()); - this.getSpellAbility().addMode(mode); + this.getSpellAbility().addMode(new Mode(new DustOfMomentsEffect(false))); } private DustOfMoments(final DustOfMoments card) { @@ -49,173 +39,60 @@ public final class DustOfMoments extends CardImpl { public DustOfMoments copy() { return new DustOfMoments(this); } +} - //TODO: PermanentImpl.getCounters() and CardImpl.getCounters(game) don't return the same value for the same Card - //TODO: This means I can't use a Card generic for Permanents and Exiled cards and use Card.getCounters(game) - //TODO: This is the reason i've copy pasted some logic in DustOfMomentsEffect - //TODO: After this issue is fixed/explained i'll refactor the code - public abstract static class DustOfMomentsEffect extends OneShotEffect { +class DustOfMomentsEffect extends OneShotEffect { - private final Counter counter; - private final Filter permFilter; - private final Filter exiledFilter; + private static final FilterPermanentOrSuspendedCard filter = new FilterPermanentOrSuspendedCard(); + private final boolean remove; - public DustOfMomentsEffect() { - super(Outcome.Benefit); - this.counter = new Counter(CounterType.TIME.getName(), 2); - this.permFilter = new FilterPermanent("permanent and each suspended card"); - permFilter.add(CounterType.TIME.getPredicate()); + DustOfMomentsEffect(boolean remove) { + super(Outcome.Benefit); + this.remove = remove; + } - this.exiledFilter = new FilterCard("permanent and each suspended card"); - exiledFilter.add(CounterType.TIME.getPredicate()); - setText(); - } + private DustOfMomentsEffect(final DustOfMomentsEffect effect) { + super(effect); + this.remove = effect.remove; + } - public DustOfMomentsEffect(final DustOfMomentsEffect effect) { - super(effect); - this.counter = effect.counter.copy(); - this.permFilter = effect.permFilter.copy(); - this.exiledFilter = effect.exiledFilter.copy(); - } + @Override + public DustOfMomentsEffect copy() { + return new DustOfMomentsEffect(this); + } - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - MageObject sourceObject = game.getObject(source); - if (controller != null && sourceObject != null) { - updatePermanents(source, game, controller, sourceObject); - updateSuspended(source, game, controller, sourceObject); - return true; - } - return false; - } - - private void updateSuspended(final Ability source, final Game game, final Player controller, final MageObject sourceObject) { - final List exiledCards = game.getExile().getAllCards(game); - execute(source, game, controller, sourceObject, exiledCards); - } - - private void updatePermanents(final Ability source, final Game game, final Player controller, final MageObject sourceObject) { - List permanents = game.getBattlefield().getAllActivePermanents(); - executeP(source, game, controller, sourceObject, permanents); - } - - private void executeP(final Ability source, final Game game, final Player controller, final MageObject sourceObject, final List cards) { - if (cards == null || cards.isEmpty()) { - return; - } - for (Permanent card : cards) { - if (permFilter.match(card, game)) { - final String counterName = counter.getName(); - if (shouldRemoveCounters()) { - final Counter existingCounterOfSameType = card.getCounters(game).get(counterName); - final int countersToRemove = Math.min(existingCounterOfSameType.getCount(), counter.getCount()); - final Counter modifiedCounter = new Counter(counterName, countersToRemove); - card.removeCounters(modifiedCounter, source, game); - } else { - card.addCounters(counter, source.getControllerId(), source, game); - } - if (!game.isSimulation()) { - game.informPlayers(sourceObject.getName() + ": " + - controller.getLogName() + getActionStr() + 's' + - counter.getCount() + ' ' + counterName.toLowerCase(Locale.ENGLISH) + - " counter on " + card.getName()); - } - } - } - } - - private void execute(final Ability source, final Game game, final Player controller, final MageObject sourceObject, final List cards) { - if (cards == null || cards.isEmpty()) { - return; - } - for (Card card : cards) { - if (exiledFilter.match(card, game)) { - final String counterName = counter.getName(); - if (shouldRemoveCounters()) { - final Counter existingCounterOfSameType = card.getCounters(game).get(counterName); - final int countersToRemove = Math.min(existingCounterOfSameType.getCount(), counter.getCount()); - final Counter modifiedCounter = new Counter(counterName, countersToRemove); - card.removeCounters(modifiedCounter, source, game); - } else { - card.addCounters(counter, source.getControllerId(), source, game); - } - if (!game.isSimulation()) { - game.informPlayers(sourceObject.getName() + ": " + - controller.getLogName() + getActionStr() + "s " + - counter.getCount() + ' ' + counterName.toLowerCase(Locale.ENGLISH) + - " counter on " + card.getName()); - } - } - } - } - - protected abstract boolean shouldRemoveCounters(); - - protected abstract String getActionStr(); - - private void setText() { - StringBuilder sb = new StringBuilder(); - sb.append(getActionStr()); - if (counter.getCount() > 1) { - sb.append(Integer.toString(counter.getCount())).append(' ').append(counter.getName().toLowerCase(Locale.ENGLISH)).append(" counters on each "); + @Override + public boolean apply(Game game, Ability source) { + for (Permanent permanent : game.getBattlefield().getActivePermanents( + remove ? StaticFilters.FILTER_PERMANENT : filter.getPermanentFilter(), + source.getControllerId(), source, game + )) { + if (remove) { + permanent.removeCounters(CounterType.TIME.createInstance(2), source, game); } else { - sb.append("a ").append(counter.getName().toLowerCase(Locale.ENGLISH)).append(" counter on each "); + permanent.addCounters(CounterType.TIME.createInstance(2), source, game); } - sb.append(permFilter.getMessage()); - staticText = sb.toString(); } + for (Card card : game.getExile().getCards(filter.getCardFilter(), game)) { + if (remove) { + card.removeCounters(CounterType.TIME.createInstance(2), source, game); + } else { + card.addCounters(CounterType.TIME.createInstance(2), source, game); + } + } + return true; } - public static class AddCountersEffect extends DustOfMomentsEffect { - - public AddCountersEffect() { - super(); - } - - public AddCountersEffect(final DustOfMomentsEffect effect) { - super(effect); - } - - @Override - protected boolean shouldRemoveCounters() { - return false; - } - - @Override - protected String getActionStr() { - return "add"; - } - - @Override - public Effect copy() { - return new AddCountersEffect(this); - } - } - - public static class RemoveCountersEffect extends DustOfMomentsEffect { - - public RemoveCountersEffect() { - super(); - } - - public RemoveCountersEffect(final DustOfMomentsEffect effect) { - super(effect); - } - - @Override - protected boolean shouldRemoveCounters() { - return true; - } - - @Override - protected String getActionStr() { - return "remove"; - } - - @Override - public Effect copy() { - return new RemoveCountersEffect(this); + @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/Epochrasite.java b/Mage.Sets/src/mage/cards/e/Epochrasite.java index 6c6b15ee5b..f7e9dd902b 100644 --- a/Mage.Sets/src/mage/cards/e/Epochrasite.java +++ b/Mage.Sets/src/mage/cards/e/Epochrasite.java @@ -41,7 +41,7 @@ public final class Epochrasite extends CardImpl { this.addAbility(new EntersBattlefieldAbility( new AddCountersSourceEffect(CounterType.P1P1.createInstance(3)), new InvertCondition(CastFromHandSourcePermanentCondition.instance), - "{this} enters the battlefield with three +1/+1 counters on it if you didn't cast it from your hand", ""), + "","with three +1/+1 counters on it if you didn't cast it from your hand"), new CastFromHandWatcher()); // When Epochrasite dies, exile it with three time counters on it and it gains suspend. diff --git a/Mage.Sets/src/mage/cards/f/FesteringMarch.java b/Mage.Sets/src/mage/cards/f/FesteringMarch.java index ccf4b0cb31..09567b45d7 100644 --- a/Mage.Sets/src/mage/cards/f/FesteringMarch.java +++ b/Mage.Sets/src/mage/cards/f/FesteringMarch.java @@ -30,7 +30,7 @@ public final class FesteringMarch extends CardImpl { this.getSpellAbility().addEffect(new ExileSpellEffect()); // with three time counters on it. Effect effect = new AddCountersSourceEffect(CounterType.TIME.createInstance(), StaticValue.get(3), false, true); - effect.setText("with 3 time counters on it"); + effect.setText("with three time counters on it"); this.getSpellAbility().addEffect(effect); // Suspend 3-{2}{B} diff --git a/Mage.Sets/src/mage/cards/g/Ghostfire.java b/Mage.Sets/src/mage/cards/g/Ghostfire.java index 7d8d129ebf..997d2fd1a0 100644 --- a/Mage.Sets/src/mage/cards/g/Ghostfire.java +++ b/Mage.Sets/src/mage/cards/g/Ghostfire.java @@ -1,27 +1,30 @@ - package mage.cards.g; -import java.util.UUID; import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.DamageTargetEffect; import mage.abilities.effects.common.InfoEffect; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; +import mage.constants.Zone; import mage.target.common.TargetAnyTarget; +import java.util.UUID; + /** - * * @author dustinconrad */ public final class Ghostfire extends CardImpl { public Ghostfire(UUID ownerId, CardSetInfo setInfo) { - super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{R}"); + super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{2}{R}"); // Ghostfire is colorless. this.color = new ObjectColor(); - this.getSpellAbility().addEffect(new InfoEffect("{this} is colorless")); + this.addAbility(new SimpleStaticAbility( + Zone.ALL, new InfoEffect("{this} is colorless") + ).setRuleAtTheTop(true)); // Ghostfire deals 3 damage to any target. this.getSpellAbility().addEffect(new DamageTargetEffect(3)); diff --git a/Mage.Sets/src/mage/cards/g/GuiltyConscience.java b/Mage.Sets/src/mage/cards/g/GuiltyConscience.java index 67b8e14442..ee7e3cfdc9 100644 --- a/Mage.Sets/src/mage/cards/g/GuiltyConscience.java +++ b/Mage.Sets/src/mage/cards/g/GuiltyConscience.java @@ -1,31 +1,30 @@ - package mage.cards.g; -import java.util.UUID; import mage.abilities.Ability; import mage.abilities.common.DealsDamageAttachedTriggeredAbility; -import mage.abilities.dynamicvalue.common.NumericSetToEffectValues; +import mage.abilities.dynamicvalue.common.SavedDamageValue; import mage.abilities.effects.common.AttachEffect; import mage.abilities.effects.common.DamageAttachedEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; -import mage.constants.SubType; import mage.constants.Outcome; +import mage.constants.SubType; import mage.constants.Zone; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; +import java.util.UUID; + /** - * * @author HanClinto */ public final class GuiltyConscience extends CardImpl { public GuiltyConscience(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{W}"); - + this.subtype.add(SubType.AURA); // Enchant creature @@ -36,7 +35,7 @@ public final class GuiltyConscience extends CardImpl { this.addAbility(ability); // Whenever enchanted creature deals damage, Guilty Conscience deals that much damage to that creature. - this.addAbility(new DealsDamageAttachedTriggeredAbility(Zone.BATTLEFIELD, new DamageAttachedEffect(new NumericSetToEffectValues("that much", "damage")), false)); + this.addAbility(new DealsDamageAttachedTriggeredAbility(Zone.BATTLEFIELD, new DamageAttachedEffect(SavedDamageValue.MUCH).setText("that much damage to that creature"), false)); } private GuiltyConscience(final GuiltyConscience card) { diff --git a/Mage.Sets/src/mage/cards/i/ImperialMask.java b/Mage.Sets/src/mage/cards/i/ImperialMask.java index 540d044fed..dd7d8e7914 100644 --- a/Mage.Sets/src/mage/cards/i/ImperialMask.java +++ b/Mage.Sets/src/mage/cards/i/ImperialMask.java @@ -1,7 +1,5 @@ - package mage.cards.i; -import java.util.UUID; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.condition.common.SourceMatchesFilterCondition; @@ -16,8 +14,9 @@ import mage.constants.Zone; import mage.filter.FilterPermanent; import mage.filter.predicate.permanent.TokenPredicate; +import java.util.UUID; + /** - * * @author TheElk801 */ public final class ImperialMask extends CardImpl { @@ -34,10 +33,10 @@ public final class ImperialMask extends CardImpl { // When Imperial Mask enters the battlefield, if it's not a token, each of your teammates puts a token that's a copy of Imperial Mask onto the battlefield. // No implementation of teammates currently, so no effect needed this.addAbility(new ConditionalInterveningIfTriggeredAbility( - new EntersBattlefieldTriggeredAbility(new InfoEffect("each of your teammates puts a token that's a copy of {this} onto the battlefield"), false), + new EntersBattlefieldTriggeredAbility(new InfoEffect(""), false), new SourceMatchesFilterCondition(filter), "When {this} enters the battlefield, if it's not a token, " - + "each of your teammates puts a token that's a copy of {this} onto the battlefield" + + "each of your teammates creates a token that's a copy of {this}" )); // You have hexproof. diff --git a/Mage.Sets/src/mage/cards/l/LlanowarEmpath.java b/Mage.Sets/src/mage/cards/l/LlanowarEmpath.java index 9718bd8da0..4d56a816d6 100644 --- a/Mage.Sets/src/mage/cards/l/LlanowarEmpath.java +++ b/Mage.Sets/src/mage/cards/l/LlanowarEmpath.java @@ -35,7 +35,7 @@ public final class LlanowarEmpath extends CardImpl { this.toughness = new MageInt(2); // When Llanowar Empath enters the battlefield, scry 2, then reveal the top card of your library. If it's a creature card, put it into your hand. - Ability ability = new EntersBattlefieldTriggeredAbility(new ScryEffect(2)); + Ability ability = new EntersBattlefieldTriggeredAbility(new ScryEffect(2, false)); ability.addEffect(new LlanowarEmpathEffect()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/cards/l/LostAuramancers.java b/Mage.Sets/src/mage/cards/l/LostAuramancers.java index c4d91966e9..68b695b7a6 100644 --- a/Mage.Sets/src/mage/cards/l/LostAuramancers.java +++ b/Mage.Sets/src/mage/cards/l/LostAuramancers.java @@ -86,6 +86,6 @@ class LostAuramancersAbility extends PutIntoGraveFromBattlefieldSourceTriggeredA @Override public String getRule() { - return "When {this} dies, if it had no time counters on it, you may search your library for an enchantment card and put it onto the battlefield. If you do, shuffle."; + return "When {this} dies, if it had no time counters on it, you may search your library for an enchantment card, put it onto the battlefield, then shuffle."; } } diff --git a/Mage.Sets/src/mage/cards/m/MarshalingCry.java b/Mage.Sets/src/mage/cards/m/MarshalingCry.java index 7a2535de65..09d9d3de59 100644 --- a/Mage.Sets/src/mage/cards/m/MarshalingCry.java +++ b/Mage.Sets/src/mage/cards/m/MarshalingCry.java @@ -29,7 +29,7 @@ public final class MarshalingCry extends CardImpl { effect.setText("Creatures you control get +1/+1"); this.getSpellAbility().addEffect(effect); effect = new GainAbilityControlledEffect(VigilanceAbility.getInstance(), Duration.EndOfTurn); - effect.setText("and vigilance until end of turn"); + effect.setText("and gain vigilance until end of turn"); this.getSpellAbility().addEffect(effect); // Cycling {2} diff --git a/Mage.Sets/src/mage/cards/p/PatriciansScorn.java b/Mage.Sets/src/mage/cards/p/PatriciansScorn.java index 3cbb5106cd..fc62084e7a 100644 --- a/Mage.Sets/src/mage/cards/p/PatriciansScorn.java +++ b/Mage.Sets/src/mage/cards/p/PatriciansScorn.java @@ -33,7 +33,7 @@ public final class PatriciansScorn extends CardImpl { // If you've cast another white spell this turn, you may cast this spell without paying its mana cost. this.addAbility(new AlternativeCostSourceAbility(new CastWhiteSpellThisTurnCondition()), new PatriciansScornWatcher()); // Destroy all enchantments. - this.getSpellAbility().addEffect(new DestroyAllEffect(StaticFilters.FILTER_PERMANENT_ENCHANTMENT)); + this.getSpellAbility().addEffect(new DestroyAllEffect(StaticFilters.FILTER_PERMANENT_ENCHANTMENTS)); } private PatriciansScorn(final PatriciansScorn card) { diff --git a/Mage.Sets/src/mage/cards/r/RealityStrobe.java b/Mage.Sets/src/mage/cards/r/RealityStrobe.java index 2e4ae802a4..9190b70a70 100644 --- a/Mage.Sets/src/mage/cards/r/RealityStrobe.java +++ b/Mage.Sets/src/mage/cards/r/RealityStrobe.java @@ -31,7 +31,7 @@ public final class RealityStrobe extends CardImpl { this.getSpellAbility().addEffect(new ExileSpellEffect()); // with three time counters on it. Effect effect = new AddCountersSourceEffect(CounterType.TIME.createInstance(), StaticValue.get(3), false, true); - effect.setText("with 3 time counters on it"); + effect.setText("with three time counters on it"); this.getSpellAbility().addEffect(effect); this.getSpellAbility().addTarget(new TargetPermanent()); diff --git a/Mage.Sets/src/mage/cards/s/ScoutsWarning.java b/Mage.Sets/src/mage/cards/s/ScoutsWarning.java index baadc72a93..e874a3bcb3 100644 --- a/Mage.Sets/src/mage/cards/s/ScoutsWarning.java +++ b/Mage.Sets/src/mage/cards/s/ScoutsWarning.java @@ -34,7 +34,7 @@ public final class ScoutsWarning extends CardImpl { this.getSpellAbility().addWatcher(new ScoutsWarningWatcher()); // Draw a card. - this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1).concatBy("
")); } private ScoutsWarning(final ScoutsWarning card) { diff --git a/Mage.Sets/src/mage/cards/s/SkizzikSurger.java b/Mage.Sets/src/mage/cards/s/SkizzikSurger.java index e7bbd3c140..32c666976f 100644 --- a/Mage.Sets/src/mage/cards/s/SkizzikSurger.java +++ b/Mage.Sets/src/mage/cards/s/SkizzikSurger.java @@ -28,7 +28,7 @@ public final class SkizzikSurger extends CardImpl { // Haste this.addAbility(HasteAbility.getInstance()); // Echo-Sacrifice two lands. - this.addAbility(new EchoAbility(new SacrificeTargetCost(new TargetControlledPermanent(2, 2, new FilterControlledLandPermanent("two lands"), true)))); + this.addAbility(new EchoAbility(new SacrificeTargetCost(new TargetControlledPermanent(2, 2, new FilterControlledLandPermanent("lands"), true)))); } private SkizzikSurger(final SkizzikSurger card) { diff --git a/Mage.Sets/src/mage/cards/s/SoultetherGolem.java b/Mage.Sets/src/mage/cards/s/SoultetherGolem.java index 450ac7f582..22c9e0fb01 100644 --- a/Mage.Sets/src/mage/cards/s/SoultetherGolem.java +++ b/Mage.Sets/src/mage/cards/s/SoultetherGolem.java @@ -1,11 +1,9 @@ - package mage.cards.s; -import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldAbility; -import mage.abilities.common.EntersBattlefieldAllTriggeredAbility; +import mage.abilities.common.EntersBattlefieldControlledTriggeredAbility; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.keyword.VanishingSacrificeAbility; import mage.abilities.keyword.VanishingUpkeepAbility; @@ -19,8 +17,9 @@ import mage.counters.CounterType; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.AnotherPredicate; +import java.util.UUID; + /** - * * @author fireshoes */ public final class SoultetherGolem extends CardImpl { @@ -33,7 +32,7 @@ public final class SoultetherGolem extends CardImpl { } public SoultetherGolem(UUID ownerId, CardSetInfo setInfo) { - super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT,CardType.CREATURE},"{2}"); + super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{2}"); this.subtype.add(SubType.GOLEM); this.power = new MageInt(3); this.toughness = new MageInt(3); @@ -46,7 +45,7 @@ public final class SoultetherGolem extends CardImpl { this.addAbility(new VanishingSacrificeAbility()); // Whenever another creature enters the battlefield under your control, put a time counter on Soultether Golem. - this.addAbility(new EntersBattlefieldAllTriggeredAbility( + this.addAbility(new EntersBattlefieldControlledTriggeredAbility( Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.TIME.createInstance(1)), filter, diff --git a/Mage.Sets/src/mage/cards/s/SteamfloggerBoss.java b/Mage.Sets/src/mage/cards/s/SteamfloggerBoss.java index 8659d72e0e..c4467fa9c8 100644 --- a/Mage.Sets/src/mage/cards/s/SteamfloggerBoss.java +++ b/Mage.Sets/src/mage/cards/s/SteamfloggerBoss.java @@ -23,7 +23,7 @@ import mage.filter.common.FilterCreaturePermanent; public final class SteamfloggerBoss extends CardImpl { private static final FilterCreaturePermanent filter - = new FilterCreaturePermanent(SubType.RIGGER, "Rigger creatures"); + = new FilterCreaturePermanent(SubType.RIGGER, "Riggers"); public SteamfloggerBoss(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{R}"); @@ -53,7 +53,7 @@ public final class SteamfloggerBoss extends CardImpl { Zone.BATTLEFIELD, new InfoEffect( "If a Rigger you control would assemble a Contraption, " - + "it assembles two Contraptions instead. (NOT IMPLEMENTED)" + + "it assembles two Contraptions instead" ) )); diff --git a/Mage.Sets/src/mage/cards/t/TilonallisCrown.java b/Mage.Sets/src/mage/cards/t/TilonallisCrown.java index f06ddc65be..4edccc2590 100644 --- a/Mage.Sets/src/mage/cards/t/TilonallisCrown.java +++ b/Mage.Sets/src/mage/cards/t/TilonallisCrown.java @@ -41,8 +41,7 @@ public final class TilonallisCrown extends CardImpl { this.addAbility(ability); // When Tilonalli's Crown enters the battlefield, it deals 1 damage to enchanted creature. - this.addAbility(new EntersBattlefieldTriggeredAbility(new DamageAttachedEffect(1, "it") - .setText("it deals 1 damage to enchanted creature"))); + this.addAbility(new EntersBattlefieldTriggeredAbility(new DamageAttachedEffect(1, "it"))); // Enchanted creature gets +3/+0 and has trample. ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(3, 0)); diff --git a/Mage.Sets/src/mage/cards/u/UnblinkingBleb.java b/Mage.Sets/src/mage/cards/u/UnblinkingBleb.java index eb49172c06..f4c08a3002 100644 --- a/Mage.Sets/src/mage/cards/u/UnblinkingBleb.java +++ b/Mage.Sets/src/mage/cards/u/UnblinkingBleb.java @@ -1,7 +1,5 @@ - package mage.cards.u; -import java.util.UUID; import mage.MageInt; import mage.abilities.common.TurnedFaceUpAllTriggeredAbility; import mage.abilities.costs.mana.ManaCostsImpl; @@ -11,25 +9,32 @@ import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; import mage.constants.SubType; +import mage.constants.Zone; import mage.filter.FilterPermanent; +import java.util.UUID; + /** - * * @author fireshoes */ public final class UnblinkingBleb extends CardImpl { + private static final FilterPermanent filter = new FilterPermanent("{this} or another permanent"); + public UnblinkingBleb(UUID ownerId, CardSetInfo setInfo) { - super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{U}"); + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{U}"); this.subtype.add(SubType.ILLUSION); this.power = new MageInt(1); this.toughness = new MageInt(3); // Morph {2}{U} - this.addAbility(new MorphAbility(this, new ManaCostsImpl("{2}{U}"))); - + this.addAbility(new MorphAbility(this, new ManaCostsImpl<>("{2}{U}"))); + // Whenever Unblinking Bleb or another permanent is turned face up, you may scry 2. - this.addAbility(new TurnedFaceUpAllTriggeredAbility(new ScryEffect(2), new FilterPermanent("{this} or another permanent"), true)); + this.addAbility(new TurnedFaceUpAllTriggeredAbility( + Zone.BATTLEFIELD, new ScryEffect(2), + filter, true, true + )); } private UnblinkingBleb(final UnblinkingBleb card) { @@ -40,4 +45,4 @@ public final class UnblinkingBleb extends CardImpl { public UnblinkingBleb copy() { return new UnblinkingBleb(this); } -} \ No newline at end of file +} diff --git a/Mage.Verify/src/test/java/mage/verify/VerifyCardDataTest.java b/Mage.Verify/src/test/java/mage/verify/VerifyCardDataTest.java index dd38a99cf0..59eed819cd 100644 --- a/Mage.Verify/src/test/java/mage/verify/VerifyCardDataTest.java +++ b/Mage.Verify/src/test/java/mage/verify/VerifyCardDataTest.java @@ -62,7 +62,7 @@ public class VerifyCardDataTest { private static final Logger logger = Logger.getLogger(VerifyCardDataTest.class); - private static final String FULL_ABILITIES_CHECK_SET_CODE = "PLC"; // check all abilities and output cards with wrong abilities texts; + private static final String FULL_ABILITIES_CHECK_SET_CODE = "FUT"; // check all abilities and output cards with wrong abilities texts; private static final boolean AUTO_FIX_SAMPLE_DECKS = false; // debug only: auto-fix sample decks by test_checkSampleDecks test run private static final boolean ONLY_TEXT = false; // use when checking text locally, suppresses unnecessary checks and output messages diff --git a/Mage/src/main/java/mage/abilities/effects/common/DamageAttachedEffect.java b/Mage/src/main/java/mage/abilities/effects/common/DamageAttachedEffect.java index 0d4e3f86bb..df3089bea3 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/DamageAttachedEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/DamageAttachedEffect.java @@ -72,9 +72,9 @@ public class DamageAttachedEffect extends OneShotEffect { return staticText; } if ("equal to".equals(amount.toString())) { - return this.sourceName + " deals damage " + amount + " that creatures toughness to that creature"; + return this.sourceName + " deals damage " + amount + " that creatures toughness to enchanted creature"; } - return this.sourceName + " deals " + amount + " damage to that creature"; + return this.sourceName + " deals " + amount + " damage to enchanted creature"; } public String getSourceName() { diff --git a/Mage/src/main/java/mage/game/permanent/token/FesteringGoblinToken.java b/Mage/src/main/java/mage/game/permanent/token/FesteringGoblinToken.java index 6f85ef6a2c..ccfd3e1e5c 100644 --- a/Mage/src/main/java/mage/game/permanent/token/FesteringGoblinToken.java +++ b/Mage/src/main/java/mage/game/permanent/token/FesteringGoblinToken.java @@ -17,7 +17,7 @@ import mage.target.common.TargetCreaturePermanent; public final class FesteringGoblinToken extends TokenImpl { public FesteringGoblinToken() { - super("Festering Goblin", "1/1 black Zombie Goblin creature token named Festering Goblin with \"When Festering Goblin dies, target creature gets -1/-1 until end of turn.\""); + super("Festering Goblin", "1/1 black Zombie Goblin creature token named Festering Goblin. It has \"When Festering Goblin dies, target creature gets -1/-1 until end of turn.\""); cardType.add(CardType.CREATURE); color.setBlack(true); subtype.add(SubType.ZOMBIE); diff --git a/Mage/src/main/java/mage/game/permanent/token/GoldmeadowHarrierToken.java b/Mage/src/main/java/mage/game/permanent/token/GoldmeadowHarrierToken.java index 835566acf1..457d5d4f57 100644 --- a/Mage/src/main/java/mage/game/permanent/token/GoldmeadowHarrierToken.java +++ b/Mage/src/main/java/mage/game/permanent/token/GoldmeadowHarrierToken.java @@ -19,7 +19,7 @@ import mage.target.common.TargetCreaturePermanent; public final class GoldmeadowHarrierToken extends TokenImpl { public GoldmeadowHarrierToken() { - super("Goldmeadow Harrier", "1/1 white Kithkin Soldier creature token named Goldmeadow Harrier with \"{W}, {T}: Tap target creature.\""); + super("Goldmeadow Harrier", "1/1 white Kithkin Soldier creature token named Goldmeadow Harrier. It has \"{W}, {T}: Tap target creature.\""); cardType.add(CardType.CREATURE); color.setWhite(true); subtype.add(SubType.KITHKIN); diff --git a/Mage/src/main/java/mage/game/permanent/token/SparkElementalToken.java b/Mage/src/main/java/mage/game/permanent/token/SparkElementalToken.java index 1cc0a51890..b4625b7b82 100644 --- a/Mage/src/main/java/mage/game/permanent/token/SparkElementalToken.java +++ b/Mage/src/main/java/mage/game/permanent/token/SparkElementalToken.java @@ -15,7 +15,7 @@ import mage.constants.TargetController; public final class SparkElementalToken extends TokenImpl { public SparkElementalToken() { - super("Spark Elemental", "3/1 red Elemental creature token named Spark Elemental with trample, haste, and \"At the beginning of the end step, sacrifice Spark Elemental.\""); + super("Spark Elemental", "3/1 red Elemental creature token named Spark Elemental. It has trample, haste, and \"At the beginning of the end step, sacrifice Spark Elemental.\""); cardType.add(CardType.CREATURE); color.setRed(true); subtype.add(SubType.ELEMENTAL);