forked from External/mage
Implemented Plague Mare
This commit is contained in:
parent
8c01cd72f9
commit
60b0fd82ff
3 changed files with 69 additions and 8 deletions
|
|
@ -1,5 +1,3 @@
|
|||
|
||||
|
||||
package mage.cards.m;
|
||||
|
||||
import java.util.UUID;
|
||||
|
|
@ -28,8 +26,8 @@ import mage.target.targetpointer.FixedTarget;
|
|||
*/
|
||||
public final class MassacreWurm extends CardImpl {
|
||||
|
||||
public MassacreWurm (UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.CREATURE},"{3}{B}{B}{B}");
|
||||
public MassacreWurm(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{B}{B}{B}");
|
||||
this.subtype.add(SubType.WURM);
|
||||
|
||||
this.power = new MageInt(6);
|
||||
|
|
@ -38,7 +36,7 @@ public final class MassacreWurm extends CardImpl {
|
|||
this.addAbility(new MassacreWurmTriggeredAbility());
|
||||
}
|
||||
|
||||
public MassacreWurm (final MassacreWurm card) {
|
||||
public MassacreWurm(final MassacreWurm card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
|
|
@ -50,6 +48,7 @@ public final class MassacreWurm extends CardImpl {
|
|||
}
|
||||
|
||||
class MassacreWurmTriggeredAbility extends TriggeredAbilityImpl {
|
||||
|
||||
MassacreWurmTriggeredAbility() {
|
||||
super(Zone.BATTLEFIELD, new LoseLifeTargetEffect(2));
|
||||
}
|
||||
|
|
@ -70,7 +69,7 @@ class MassacreWurmTriggeredAbility extends TriggeredAbilityImpl {
|
|||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
if (((ZoneChangeEvent)event).isDiesEvent()) {
|
||||
if (((ZoneChangeEvent) event).isDiesEvent()) {
|
||||
Permanent p = (Permanent) game.getLastKnownInformation(event.getTargetId(), Zone.BATTLEFIELD);
|
||||
if (p != null && p.isCreature() && game.getOpponents(this.getControllerId()).contains(p.getControllerId())) {
|
||||
for (Effect effect : this.getEffects()) {
|
||||
|
|
@ -84,6 +83,6 @@ class MassacreWurmTriggeredAbility extends TriggeredAbilityImpl {
|
|||
|
||||
@Override
|
||||
public String getRule() {
|
||||
return "Whenever a creature an opponent controls is put into a graveyard from the battlefield, " + super.getRule();
|
||||
return "Whenever a creature an opponent controls dies, " + super.getRule();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
61
Mage.Sets/src/mage/cards/p/PlagueMare.java
Normal file
61
Mage.Sets/src/mage/cards/p/PlagueMare.java
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
package mage.cards.p;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.ObjectColor;
|
||||
import mage.abilities.common.EntersBattlefieldTriggeredAbility;
|
||||
import mage.abilities.common.SimpleStaticAbility;
|
||||
import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostOpponentsEffect;
|
||||
import mage.constants.SubType;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.mageobject.ColorPredicate;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class PlagueMare extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white creatures");
|
||||
|
||||
static {
|
||||
filter.add(new ColorPredicate(ObjectColor.WHITE));
|
||||
}
|
||||
|
||||
public PlagueMare(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{B}{B}");
|
||||
|
||||
this.subtype.add(SubType.NIGHTMARE);
|
||||
this.subtype.add(SubType.HORSE);
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// Plague Mare can't be blocked by white creatures.
|
||||
this.addAbility(new SimpleStaticAbility(
|
||||
Zone.BATTLEFIELD,
|
||||
new CantBeBlockedByCreaturesSourceEffect(
|
||||
filter, Duration.WhileOnBattlefield
|
||||
)
|
||||
));
|
||||
|
||||
// When Plague Mare enters the battlefield, creatures your opponents control get -1/-1 until end of turn.
|
||||
this.addAbility(new EntersBattlefieldTriggeredAbility(
|
||||
new BoostOpponentsEffect(-1, -1, Duration.EndOfTurn)
|
||||
));
|
||||
}
|
||||
|
||||
public PlagueMare(final PlagueMare card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public PlagueMare copy() {
|
||||
return new PlagueMare(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -139,6 +139,7 @@ public final class CoreSet2019 extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Palladia-Mors, the Ruiner", 219, Rarity.MYTHIC, mage.cards.p.PalladiaMorsTheRuiner.class));
|
||||
cards.add(new SetCardInfo("Patient Rebuilding", 67, Rarity.RARE, mage.cards.p.PatientRebuilding.class));
|
||||
cards.add(new SetCardInfo("Pegasus Courser", 32, Rarity.COMMON, mage.cards.p.PegasusCourser.class));
|
||||
cards.add(new SetCardInfo("Plague Mare", 114, Rarity.UNCOMMON, mage.cards.p.PlagueMare.class));
|
||||
cards.add(new SetCardInfo("Plummet", 193, Rarity.COMMON, mage.cards.p.Plummet.class));
|
||||
cards.add(new SetCardInfo("Prodigious Growth", 194, Rarity.RARE, mage.cards.p.ProdigiousGrowth.class));
|
||||
cards.add(new SetCardInfo("Psychic Symbiont", 221, Rarity.UNCOMMON, mage.cards.p.PsychicSymbiont.class));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue