mirror of
https://github.com/correl/mage.git
synced 2024-12-28 11:14:13 +00:00
[NEO] Awakened Awareness - Use StaticFilter
This commit is contained in:
parent
93f14cdf61
commit
da53bb14a1
1 changed files with 2 additions and 9 deletions
|
@ -11,8 +11,7 @@ import mage.abilities.effects.common.counter.AddCountersAttachedEffect;
|
|||
import mage.constants.*;
|
||||
import mage.abilities.effects.common.AttachEffect;
|
||||
import mage.counters.CounterType;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.target.TargetPermanent;
|
||||
|
@ -26,19 +25,13 @@ import mage.cards.CardSetInfo;
|
|||
*/
|
||||
public final class AwakenedAwareness extends CardImpl {
|
||||
|
||||
private static final FilterPermanent filter = new FilterPermanent("artifact or creature");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(CardType.ARTIFACT.getPredicate(), CardType.CREATURE.getPredicate()));
|
||||
}
|
||||
|
||||
public AwakenedAwareness(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{X}{U}{U}");
|
||||
|
||||
this.subtype.add(SubType.AURA);
|
||||
|
||||
// Enchant artifact or creature
|
||||
TargetPermanent auraTarget = new TargetPermanent(filter);
|
||||
TargetPermanent auraTarget = new TargetPermanent(StaticFilters.FILTER_PERMANENT_ARTIFACT_OR_CREATURE);
|
||||
this.getSpellAbility().addTarget(auraTarget);
|
||||
this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature));
|
||||
this.addAbility(new EnchantAbility(auraTarget.getTargetName()));
|
||||
|
|
Loading…
Reference in a new issue