From 02406e2c7cf7bec9377de85d878dbe8634af08cd Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Wed, 19 Dec 2018 18:22:57 -0500 Subject: [PATCH] Implemented Bedevil --- Mage.Sets/src/mage/cards/b/Bedevil.java | 45 +++++++++++++++++++ .../src/mage/sets/RavnicaAllegiance.java | 1 + 2 files changed, 46 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/b/Bedevil.java diff --git a/Mage.Sets/src/mage/cards/b/Bedevil.java b/Mage.Sets/src/mage/cards/b/Bedevil.java new file mode 100644 index 0000000000..83e9390810 --- /dev/null +++ b/Mage.Sets/src/mage/cards/b/Bedevil.java @@ -0,0 +1,45 @@ +package mage.cards.b; + +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class Bedevil extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or planeswalker"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.PLANESWALKER) + )); + } + + public Bedevil(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{B}{B}{R}"); + + // Destroy target artifact, creature, or planeswalker. + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + } + + public Bedevil(final Bedevil card) { + super(card); + } + + @Override + public Bedevil copy() { + return new Bedevil(this); + } +} diff --git a/Mage.Sets/src/mage/sets/RavnicaAllegiance.java b/Mage.Sets/src/mage/sets/RavnicaAllegiance.java index 1eb775a000..e0f226ae83 100644 --- a/Mage.Sets/src/mage/sets/RavnicaAllegiance.java +++ b/Mage.Sets/src/mage/sets/RavnicaAllegiance.java @@ -33,6 +33,7 @@ public final class RavnicaAllegiance extends ExpansionSet { this.maxCardNumberInBooster = 259; cards.add(new SetCardInfo("Aeromunculus", 152, Rarity.COMMON, mage.cards.a.Aeromunculus.class)); + cards.add(new SetCardInfo("Bedevil", 157, Rarity.RARE, mage.cards.b.Bedevil.class)); cards.add(new SetCardInfo("Gate Colossus", 232, Rarity.UNCOMMON, mage.cards.g.GateColossus.class)); cards.add(new SetCardInfo("Growth Spiral", 178, Rarity.COMMON, mage.cards.g.GrowthSpiral.class)); cards.add(new SetCardInfo("Imperious Oligarch", 184, Rarity.COMMON, mage.cards.i.ImperiousOligarch.class));