* Recurring Nightmare - Fixed that permanents instead of creatures could be sacrificed to activate the ability.

This commit is contained in:
LevelX2 2015-07-27 22:11:51 +02:00
parent edd7861fd3
commit a08e86be97

View file

@ -37,7 +37,7 @@ import mage.cards.CardImpl;
import mage.constants.CardType; import mage.constants.CardType;
import mage.constants.Rarity; import mage.constants.Rarity;
import mage.constants.Zone; import mage.constants.Zone;
import mage.filter.common.FilterControlledPermanent; import mage.filter.common.FilterControlledCreaturePermanent;
import mage.filter.common.FilterCreatureCard; import mage.filter.common.FilterCreatureCard;
import mage.target.common.TargetCardInYourGraveyard; import mage.target.common.TargetCardInYourGraveyard;
import mage.target.common.TargetControlledPermanent; import mage.target.common.TargetControlledPermanent;
@ -49,13 +49,12 @@ import mage.target.common.TargetControlledPermanent;
public class RecurringNightmare extends CardImpl { public class RecurringNightmare extends CardImpl {
private static final FilterCreatureCard filter = new FilterCreatureCard("creature card in your graveyard"); private static final FilterCreatureCard filter = new FilterCreatureCard("creature card in your graveyard");
private static final FilterControlledPermanent filter2 = new FilterControlledPermanent("creature"); private static final FilterControlledCreaturePermanent filter2 = new FilterControlledCreaturePermanent("creature");
public RecurringNightmare(UUID ownerId) { public RecurringNightmare(UUID ownerId) {
super(ownerId, 72, "Recurring Nightmare", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); super(ownerId, 72, "Recurring Nightmare", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}");
this.expansionSetCode = "EXO"; this.expansionSetCode = "EXO";
// Sacrifice a creature, Return Recurring Nightmare to its owner's hand: Return target creature card from your graveyard to the battlefield. Activate this ability only any time you could cast a sorcery. // Sacrifice a creature, Return Recurring Nightmare to its owner's hand: Return target creature card from your graveyard to the battlefield. Activate this ability only any time you could cast a sorcery.
Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new SacrificeTargetCost(new TargetControlledPermanent(filter2))); Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new SacrificeTargetCost(new TargetControlledPermanent(filter2)));
ability.addTarget(new TargetCardInYourGraveyard(filter)); ability.addTarget(new TargetCardInYourGraveyard(filter));