diff --git a/Mage.Sets/src/mage/cards/c/CradleToGrave.java b/Mage.Sets/src/mage/cards/c/CradleToGrave.java index 30d497fd7d..2dcd87ae9d 100644 --- a/Mage.Sets/src/mage/cards/c/CradleToGrave.java +++ b/Mage.Sets/src/mage/cards/c/CradleToGrave.java @@ -23,7 +23,7 @@ public final class CradleToGrave extends CardImpl { static { filter.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); - filter.add(new EnteredThisTurnPredicate()); + filter.add(EnteredThisTurnPredicate.instance); } public CradleToGrave(UUID ownerId, CardSetInfo setInfo) { diff --git a/Mage.Sets/src/mage/cards/f/ForceOfDespair.java b/Mage.Sets/src/mage/cards/f/ForceOfDespair.java index f182f037d3..bb2177fcab 100644 --- a/Mage.Sets/src/mage/cards/f/ForceOfDespair.java +++ b/Mage.Sets/src/mage/cards/f/ForceOfDespair.java @@ -30,7 +30,7 @@ public final class ForceOfDespair extends CardImpl { static { filter.add(new ColorPredicate(ObjectColor.BLACK)); - filter2.add(new EnteredThisTurnPredicate()); + filter2.add(EnteredThisTurnPredicate.instance); } public ForceOfDespair(UUID ownerId, CardSetInfo setInfo) { diff --git a/Mage.Sets/src/mage/cards/f/ForgeOfHeroes.java b/Mage.Sets/src/mage/cards/f/ForgeOfHeroes.java index b745f92800..42b58af29f 100644 --- a/Mage.Sets/src/mage/cards/f/ForgeOfHeroes.java +++ b/Mage.Sets/src/mage/cards/f/ForgeOfHeroes.java @@ -30,7 +30,7 @@ public final class ForgeOfHeroes extends CardImpl { static { filter.add(CommanderPredicate.instance); - filter.add(new EnteredThisTurnPredicate()); + filter.add(EnteredThisTurnPredicate.instance); } public ForgeOfHeroes(UUID ownerId, CardSetInfo setInfo) { diff --git a/Mage.Sets/src/mage/cards/r/RuinsOfOranRief.java b/Mage.Sets/src/mage/cards/r/RuinsOfOranRief.java index 47d2869fdc..b9cb0426b8 100644 --- a/Mage.Sets/src/mage/cards/r/RuinsOfOranRief.java +++ b/Mage.Sets/src/mage/cards/r/RuinsOfOranRief.java @@ -28,7 +28,7 @@ public final class RuinsOfOranRief extends CardImpl { static { filter.add(ColorlessPredicate.instance); - filter.add(new EnteredThisTurnPredicate()); + filter.add(EnteredThisTurnPredicate.instance); } public RuinsOfOranRief(UUID ownerId, CardSetInfo setInfo) { diff --git a/Mage.Sets/src/mage/cards/s/SweetGumRecluse.java b/Mage.Sets/src/mage/cards/s/SweetGumRecluse.java new file mode 100644 index 0000000000..b043e1c9e9 --- /dev/null +++ b/Mage.Sets/src/mage/cards/s/SweetGumRecluse.java @@ -0,0 +1,66 @@ +package mage.cards.s; + +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.abilities.keyword.CascadeAbility; +import mage.abilities.keyword.FlashAbility; +import mage.abilities.keyword.ReachAbility; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.constants.SubType; +import mage.counters.CounterType; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.EnteredThisTurnPredicate; +import mage.target.TargetPermanent; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class SweetGumRecluse extends CardImpl { + + private static final FilterPermanent filter + = new FilterCreaturePermanent("creatures that entered the battlefield this turn"); + + static { + filter.add(EnteredThisTurnPredicate.instance); + } + + public SweetGumRecluse(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{G}{G}"); + + this.subtype.add(SubType.SPIDER); + this.power = new MageInt(0); + this.toughness = new MageInt(3); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // Cascade + this.addAbility(new CascadeAbility()); + + // Reach + this.addAbility(ReachAbility.getInstance()); + + // When Sweet-Gum Recluse enters the battlefield, put three +1/+1 counters on each of any number of target creatures that entered the battlefield this turn. + Ability ability = new EntersBattlefieldTriggeredAbility( + new AddCountersTargetEffect(CounterType.P1P1.createInstance(3)) + ); + ability.addTarget(new TargetPermanent(0, Integer.MAX_VALUE, filter, false)); + this.addAbility(ability); + } + + private SweetGumRecluse(final SweetGumRecluse card) { + super(card); + } + + @Override + public SweetGumRecluse copy() { + return new SweetGumRecluse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/CommanderLegends.java b/Mage.Sets/src/mage/sets/CommanderLegends.java index 0f5b54157f..617a2da19a 100644 --- a/Mage.Sets/src/mage/sets/CommanderLegends.java +++ b/Mage.Sets/src/mage/sets/CommanderLegends.java @@ -107,6 +107,7 @@ public final class CommanderLegends extends ExpansionSet { cards.add(new SetCardInfo("Spectator Seating", 356, Rarity.RARE, mage.cards.s.SpectatorSeating.class)); cards.add(new SetCardInfo("Staff of Domination", 343, Rarity.RARE, mage.cards.s.StaffOfDomination.class)); cards.add(new SetCardInfo("Supreme Will", 102, Rarity.UNCOMMON, mage.cards.s.SupremeWill.class)); + cards.add(new SetCardInfo("Sweet-Gum Recluse", 260, Rarity.RARE, mage.cards.s.SweetGumRecluse.class)); cards.add(new SetCardInfo("Tevesh Szat, Doom of Fools", 153, Rarity.MYTHIC, mage.cards.t.TeveshSzatDoomOfFools.class)); cards.add(new SetCardInfo("Thorn of the Black Rose", 154, Rarity.COMMON, mage.cards.t.ThornOfTheBlackRose.class)); cards.add(new SetCardInfo("Three Visits", 261, Rarity.UNCOMMON, mage.cards.t.ThreeVisits.class)); diff --git a/Mage/src/main/java/mage/filter/predicate/permanent/EnteredThisTurnPredicate.java b/Mage/src/main/java/mage/filter/predicate/permanent/EnteredThisTurnPredicate.java index 797af90a25..07b0e6ac77 100644 --- a/Mage/src/main/java/mage/filter/predicate/permanent/EnteredThisTurnPredicate.java +++ b/Mage/src/main/java/mage/filter/predicate/permanent/EnteredThisTurnPredicate.java @@ -1,8 +1,3 @@ -/* - * To change this license header, choose License Headers in Project Properties. - * To change this template file, choose Tools | Templates - * and open the template in the editor. - */ package mage.filter.predicate.permanent; import mage.filter.predicate.Predicate; @@ -10,10 +5,10 @@ import mage.game.Game; import mage.game.permanent.Permanent; /** - * * @author LevelX2 */ -public class EnteredThisTurnPredicate implements Predicate { +public enum EnteredThisTurnPredicate implements Predicate { + instance; @Override public boolean apply(Permanent input, Game game) {