added nonland filter to ability

This commit is contained in:
Tyler Fretz 2020-02-04 00:53:18 -05:00
parent cbfcfa6d5e
commit 4a9b50bb71

View file

@ -8,6 +8,8 @@ import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.SubType;
import mage.filter.FilterPermanent;
import mage.filter.common.FilterNonlandPermanent;
import mage.target.TargetPermanent;
import java.util.UUID;
@ -17,6 +19,8 @@ import java.util.UUID;
*/
public final class StingingLionfish extends CardImpl {
private static final FilterPermanent filter = new FilterNonlandPermanent("nonland permanent");
public StingingLionfish(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT, CardType.CREATURE}, "{1}{U}");
@ -28,7 +32,7 @@ public final class StingingLionfish extends CardImpl {
Ability ability = new FirstSpellOpponentsTurnTriggeredAbility(
new MayTapOrUntapTargetEffect(), false
);
ability.addTarget(new TargetPermanent());
ability.addTarget(new TargetPermanent(filter));
this.addAbility(ability);
}