[LTR] Implement Mirkwood Spider

This commit is contained in:
theelk801 2023-06-09 09:20:38 -04:00
parent ca2988fc43
commit d408719b8d
3 changed files with 58 additions and 0 deletions

View file

@ -0,0 +1,49 @@
package mage.cards.m;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.AttacksTriggeredAbility;
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
import mage.abilities.keyword.DeathtouchAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Duration;
import mage.constants.SubType;
import mage.filter.StaticFilters;
import mage.target.TargetPermanent;
import java.util.UUID;
/**
* @author TheElk801
*/
public final class MirkwoodSpider extends CardImpl {
public MirkwoodSpider(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{G}");
this.subtype.add(SubType.SPIDER);
this.power = new MageInt(1);
this.toughness = new MageInt(1);
// Deathtouch
this.addAbility(DeathtouchAbility.getInstance());
// Whenever Mirkwood Spider attacks, target legendary creature you control gains deathtouch until end of turn.
Ability ability = new AttacksTriggeredAbility(new GainAbilityTargetEffect(
DeathtouchAbility.getInstance(), Duration.EndOfTurn
));
ability.addTarget(new TargetPermanent(StaticFilters.FILTER_CONTROLLED_CREATURE_LEGENDARY));
this.addAbility(ability);
}
private MirkwoodSpider(final MirkwoodSpider card) {
super(card);
}
@Override
public MirkwoodSpider copy() {
return new MirkwoodSpider(this);
}
}

View file

@ -93,6 +93,7 @@ public final class TheLordOfTheRingsTalesOfMiddleEarth extends ExpansionSet {
cards.add(new SetCardInfo("Meriadoc Brandybuck", 177, Rarity.UNCOMMON, mage.cards.m.MeriadocBrandybuck.class));
cards.add(new SetCardInfo("Minas Tirith", 256, Rarity.RARE, mage.cards.m.MinasTirith.class));
cards.add(new SetCardInfo("Mines of Moria", 257, Rarity.RARE, mage.cards.m.MinesOfMoria.class));
cards.add(new SetCardInfo("Mirkwood Spider", 178, Rarity.COMMON, mage.cards.m.MirkwoodSpider.class));
cards.add(new SetCardInfo("Morgul-Knife Wound", 98, Rarity.COMMON, mage.cards.m.MorgulKnifeWound.class));
cards.add(new SetCardInfo("Moria Marauder", 138, Rarity.RARE, mage.cards.m.MoriaMarauder.class));
cards.add(new SetCardInfo("Mount Doom", 258, Rarity.MYTHIC, mage.cards.m.MountDoom.class));

View file

@ -1103,6 +1103,14 @@ public final class StaticFilters {
FILTER_CREATURES_LEGENDARY.setLockedFilter(true);
}
public static final FilterCreaturePermanent FILTER_CONTROLLED_CREATURE_LEGENDARY = new FilterCreaturePermanent("legendary creature you control");
static {
FILTER_CONTROLLED_CREATURE_LEGENDARY.add(TargetController.YOU.getControllerPredicate());
FILTER_CONTROLLED_CREATURE_LEGENDARY.add(SuperType.LEGENDARY.getPredicate());
FILTER_CONTROLLED_CREATURE_LEGENDARY.setLockedFilter(true);
}
public static final FilterCard FILTER_CARD_ARTIFACT_OR_CREATURE = new FilterCard("artifact or creature card");
static {