diff --git a/Mage.Sets/src/mage/cards/a/AudaciousInfiltrator.java b/Mage.Sets/src/mage/cards/a/AudaciousInfiltrator.java index c41a3e39f1..58bab8ce0b 100644 --- a/Mage.Sets/src/mage/cards/a/AudaciousInfiltrator.java +++ b/Mage.Sets/src/mage/cards/a/AudaciousInfiltrator.java @@ -29,7 +29,7 @@ public final class AudaciousInfiltrator extends CardImpl { this.toughness = new MageInt(1); // Audacious Infiltrator can't be blocked by artifact creatures. - Effect effect = new CantBeBlockedByCreaturesSourceEffect(StaticFilters.FILTER_ARTIFACT_CREATURE_PERMANENT, Duration.WhileOnBattlefield); + Effect effect = new CantBeBlockedByCreaturesSourceEffect(StaticFilters.FILTER_PERMANENT_ARTIFACT_CREATURE, Duration.WhileOnBattlefield); effect.setText("{this} can't be blocked by artifact creatures"); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/cards/c/ChiefOfTheFoundry.java b/Mage.Sets/src/mage/cards/c/ChiefOfTheFoundry.java index 364f78eb0d..d9bbd798c8 100644 --- a/Mage.Sets/src/mage/cards/c/ChiefOfTheFoundry.java +++ b/Mage.Sets/src/mage/cards/c/ChiefOfTheFoundry.java @@ -1,32 +1,22 @@ - package mage.cards.c; -import java.util.UUID; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.continuous.BoostControlledEffect; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; -import mage.constants.SubType; import mage.constants.Duration; -import mage.constants.TargetController; -import mage.constants.Zone; -import mage.filter.common.FilterCreaturePermanent; +import mage.constants.SubType; +import mage.filter.StaticFilters; + +import java.util.UUID; /** - * * @author fireshoes */ public final class ChiefOfTheFoundry extends CardImpl { - private static final FilterCreaturePermanent filterBoosted = new FilterCreaturePermanent("Other artifact creatures you control"); - - static { - filterBoosted.add(CardType.ARTIFACT.getPredicate()); - filterBoosted.add(TargetController.YOU.getControllerPredicate()); - } - public ChiefOfTheFoundry(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{3}"); this.subtype.add(SubType.CONSTRUCT); @@ -34,7 +24,10 @@ public final class ChiefOfTheFoundry extends CardImpl { this.toughness = new MageInt(3); // Other artifact creatures you control get +1/+1. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostControlledEffect(1, 1, Duration.WhileOnBattlefield, filterBoosted, true))); + this.addAbility(new SimpleStaticAbility(new BoostControlledEffect( + 1, 1, Duration.WhileOnBattlefield, + StaticFilters.FILTER_PERMANENTS_ARTIFACT_CREATURE, true + ))); } private ChiefOfTheFoundry(final ChiefOfTheFoundry card) { diff --git a/Mage.Sets/src/mage/cards/g/GolemArtisan.java b/Mage.Sets/src/mage/cards/g/GolemArtisan.java index 5eef14e4f1..3ee60a4f3f 100644 --- a/Mage.Sets/src/mage/cards/g/GolemArtisan.java +++ b/Mage.Sets/src/mage/cards/g/GolemArtisan.java @@ -44,12 +44,12 @@ public final class GolemArtisan extends CardImpl { // {2}: Target artifact creature gets +1/+1 until end of turn. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 1, Duration.EndOfTurn), new GenericManaCost(2)); - ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_ARTIFACT_CREATURE_PERMANENT)); + ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_PERMANENT_ARTIFACT_CREATURE)); this.addAbility(ability); // {2}: Target artifact creature gains your choice of flying, trample, or haste until end of turn. ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GolemArtisanEffect(), new GenericManaCost(2)); - ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_ARTIFACT_CREATURE_PERMANENT)); + ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_PERMANENT_ARTIFACT_CREATURE)); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/cards/h/HinterlandDrake.java b/Mage.Sets/src/mage/cards/h/HinterlandDrake.java index 81d09b577e..df9ac61ec0 100644 --- a/Mage.Sets/src/mage/cards/h/HinterlandDrake.java +++ b/Mage.Sets/src/mage/cards/h/HinterlandDrake.java @@ -31,7 +31,7 @@ public final class HinterlandDrake extends CardImpl { this.addAbility(FlyingAbility.getInstance()); // Hinterland Drake can't block artifact creatures. - Effect effect = new CantBlockCreaturesSourceEffect(StaticFilters.FILTER_ARTIFACT_CREATURE_PERMANENT); + Effect effect = new CantBlockCreaturesSourceEffect(StaticFilters.FILTER_PERMANENT_ARTIFACT_CREATURE); effect.setText("{this} can't block artifact creatures"); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/cards/p/PiaNalaar.java b/Mage.Sets/src/mage/cards/p/PiaNalaar.java index f0a0e60f8e..6056d4b9f3 100644 --- a/Mage.Sets/src/mage/cards/p/PiaNalaar.java +++ b/Mage.Sets/src/mage/cards/p/PiaNalaar.java @@ -44,7 +44,7 @@ public final class PiaNalaar extends CardImpl { // {1}{R}: Target artifact creature gets +1/+0 until end of turn. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl<>("{1}{R}")); - ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_ARTIFACT_CREATURE_PERMANENT)); + ability.addTarget(new TargetCreaturePermanent(StaticFilters.FILTER_PERMANENT_ARTIFACT_CREATURE)); this.addAbility(ability); // {1}, Sacrifice an artifact: Target creature can't block this turn. diff --git a/Mage/src/main/java/mage/filter/StaticFilters.java b/Mage/src/main/java/mage/filter/StaticFilters.java index 9ad63e7bd9..f2b186b85c 100644 --- a/Mage/src/main/java/mage/filter/StaticFilters.java +++ b/Mage/src/main/java/mage/filter/StaticFilters.java @@ -246,10 +246,16 @@ public final class StaticFilters { FILTER_PERMANENT_ARTIFACT_OR_ENCHANTMENT.setLockedFilter(true); } - public static final FilterCreaturePermanent FILTER_ARTIFACT_CREATURE_PERMANENT = new FilterArtifactCreaturePermanent(); + public static final FilterCreaturePermanent FILTER_PERMANENT_ARTIFACT_CREATURE = new FilterArtifactCreaturePermanent(); static { - FILTER_ARTIFACT_CREATURE_PERMANENT.setLockedFilter(true); + FILTER_PERMANENT_ARTIFACT_CREATURE.setLockedFilter(true); + } + + public static final FilterCreaturePermanent FILTER_PERMANENTS_ARTIFACT_CREATURE = new FilterArtifactCreaturePermanent("artifact creatures"); + + static { + FILTER_PERMANENTS_ARTIFACT_CREATURE.setLockedFilter(true); } public static final FilterControlledArtifactPermanent FILTER_ARTIFACTS_NON_CREATURE = new FilterControlledArtifactPermanent("Noncreature artifacts");