@Override public ExileXFromYourGraveCost copy() { return new ExileXFromYourGraveCost(this); }
public ChillHaunting(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{B}"); // As an additional cost to cast Chill Haunting, exile X creature cards from your graveyard. this.getSpellAbility().addCost(new ExileXFromYourGraveCost(StaticFilters.FILTER_CARD_CREATURES_YOUR_GRAVEYARD, true)); // Target creature gets -X/-X until end of turn. this.getSpellAbility().addEffect(new BoostTargetEffect(xval, xval, Duration.EndOfTurn)); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); }
public HauntingMisery(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{B}{B}"); // As an additional cost to cast Haunting Misery, exile X creature cards from your graveyard. this.getSpellAbility().addCost(new ExileXFromYourGraveCost(new FilterCreatureCard())); // Haunting Misery deals X damage to target player. this.getSpellAbility().addTarget(new TargetPlayerOrPlaneswalker()); this.getSpellAbility().addEffect(new DamageTargetEffect(GetXValue.instance)); }
public HarvestPyre(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{R}"); // As an additional cost to cast Harvest Pyre, exile X cards from your graveyard. this.getSpellAbility().addCost(new ExileXFromYourGraveCost(new FilterCard("cards from your graveyard"))); // Harvest Pyre deals X damage to target creature. this.getSpellAbility().addTarget(new TargetCreaturePermanent()); this.getSpellAbility().addEffect(new DamageTargetEffect(GetXValue.instance)); }
public FlashOfInsight(UUID ownerId, CardSetInfo setInfo) { super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{1}{U}"); // Look at the top X cards of your library. Put one of them into your hand and the rest on the bottom of your library in any order. this.getSpellAbility().addEffect(new FlashOfInsightEffect()); // Flashback-{1}{U}, Exile X blue cards from your graveyard. Ability ability = new FlashbackAbility(new ManaCostsImpl("{1}{U}"), TimingRule.INSTANT); FilterCard filter = new FilterCard("blue cards from your graveyard"); filter.add(new ColorPredicate(ObjectColor.BLUE)); filter.add(Predicates.not(new CardIdPredicate(getId()))); ability.addCost(new ExileXFromYourGraveCost(filter)); this.addAbility(ability); }
public Painbringer(UUID ownerId, CardSetInfo setInfo) { super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{B}{B}"); this.subtype.add(SubType.HUMAN); this.subtype.add(SubType.MINION); this.power = new MageInt(1); this.toughness = new MageInt(1); // {tap}, Exile any number of cards from your graveyard: Target creature gets -X/-X until end of turn, where X is the number of cards exiled this way. DynamicValue X = new SignInversionDynamicValue(GetXValue.instance); Effect effect = new BoostTargetEffect(X, X, Duration.EndOfTurn); effect.setText("Target creature gets -X/-X until end of turn, where X is the number of cards exiled this way"); Ability ability = new SimpleActivatedAbility(effect, new TapSourceCost()); ability.addCost(new ExileXFromYourGraveCost(new FilterCard("any number of cards from your graveyard"))); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); }