package mage.cards.p; import mage.abilities.Mode; import mage.abilities.effects.common.CreateTokenEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; import mage.filter.FilterPermanent; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.AbilityPredicate; import mage.game.permanent.token.FoodToken; import mage.target.TargetPermanent; import mage.target.common.TargetEnchantmentPermanent; import java.util.UUID; /** * @author TheElk801 */ public final class PawpatchFormation extends CardImpl { private static final FilterPermanent filter = new FilterCreaturePermanent("creature with flying"); static { filter.add(new AbilityPredicate(FlyingAbility.class)); } public PawpatchFormation(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{G}"); // Choose one -- // * Destroy target creature with flying. this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addTarget(new TargetPermanent(filter)); // * Destroy target enchantment. this.getSpellAbility().addMode(new Mode(new DestroyTargetEffect()).addTarget(new TargetEnchantmentPermanent())); // * Draw a card. Create a Food token. this.getSpellAbility().addMode(new Mode(new DrawCardSourceControllerEffect(1)) .addEffect(new CreateTokenEffect(new FoodToken()))); } private PawpatchFormation(final PawpatchFormation card) { super(card); } @Override public PawpatchFormation copy() { return new PawpatchFormation(this); } }