[LCI] Implement Mischievous Pup

This commit is contained in:
Susucre 2023-10-26 12:30:23 +02:00
parent 1a205ff193
commit 1a19570d37
2 changed files with 55 additions and 0 deletions

View file

@ -0,0 +1,54 @@
package mage.cards.m;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
import mage.abilities.effects.common.ReturnToHandTargetEffect;
import mage.abilities.keyword.FlashAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.SubType;
import mage.filter.common.FilterControlledPermanent;
import mage.filter.predicate.mageobject.AnotherPredicate;
import mage.target.common.TargetControlledPermanent;
import java.util.UUID;
/**
* @author Susucr
*/
public final class MischievousPup extends CardImpl {
private static final FilterControlledPermanent filter =
new FilterControlledPermanent("other target permanent you control");
static {
filter.add(AnotherPredicate.instance);
}
public MischievousPup(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}");
this.subtype.add(SubType.DOG);
this.power = new MageInt(3);
this.toughness = new MageInt(1);
// Flash
this.addAbility(FlashAbility.getInstance());
// When Mischievous Pup enters the battlefield, return up to one other target permanent you control to its owner's hand.
Ability ability = new EntersBattlefieldTriggeredAbility(new ReturnToHandTargetEffect());
ability.addTarget(new TargetControlledPermanent(0, 1, filter, false));
this.addAbility(ability);
}
private MischievousPup(final MischievousPup card) {
super(card);
}
@Override
public MischievousPup copy() {
return new MischievousPup(this);
}
}

View file

@ -44,6 +44,7 @@ public final class TheLostCavernsOfIxalan extends ExpansionSet {
cards.add(new SetCardInfo("Jadelight Spelunker", 196, Rarity.RARE, mage.cards.j.JadelightSpelunker.class));
cards.add(new SetCardInfo("Kellan, Daring Traveler", 231, Rarity.RARE, mage.cards.k.KellanDaringTraveler.class));
cards.add(new SetCardInfo("Miner's Guidewing", 24, Rarity.COMMON, mage.cards.m.MinersGuidewing.class));
cards.add(new SetCardInfo("Mischievous Pup", 25, Rarity.UNCOMMON, mage.cards.m.MischievousPup.class));
cards.add(new SetCardInfo("Mountain", 399, Rarity.LAND, mage.cards.basiclands.Mountain.class, NON_FULL_USE_VARIOUS));
cards.add(new SetCardInfo("Ojer Axonil, Deepest Might", 158, Rarity.MYTHIC, mage.cards.o.OjerAxonilDeepestMight.class));
cards.add(new SetCardInfo("Plains", 393, Rarity.LAND, mage.cards.basiclands.Plains.class, NON_FULL_USE_VARIOUS));