From 5e19d54f1f927d3f382df3a99df3d76c43639794 Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Mon, 18 Jun 2018 21:18:10 -0400 Subject: [PATCH] Implemented Volley Veteran --- Mage.Sets/src/mage/cards/v/VolleyVeteran.java | 54 +++++++++++++++++++ Mage.Sets/src/mage/sets/CoreSet2019.java | 1 + 2 files changed, 55 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/v/VolleyVeteran.java diff --git a/Mage.Sets/src/mage/cards/v/VolleyVeteran.java b/Mage.Sets/src/mage/cards/v/VolleyVeteran.java new file mode 100644 index 0000000000..dcd41b2ddd --- /dev/null +++ b/Mage.Sets/src/mage/cards/v/VolleyVeteran.java @@ -0,0 +1,54 @@ +package mage.cards.v; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.constants.SubType; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetOpponentsCreaturePermanent; + +/** + * + * @author TheElk801 + */ +public final class VolleyVeteran extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("Goblins you control"); + + static { + filter.add(new SubtypePredicate(SubType.GOBLIN)); + } + + public VolleyVeteran(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{R}"); + + this.subtype.add(SubType.GOBLIN); + this.subtype.add(SubType.WARRIOR); + this.power = new MageInt(4); + this.toughness = new MageInt(2); + + // When Volley Veteran enters the battlefield, it deals damage to target creature an opponent controls equal to the number of Goblins you control. + Ability ability = new EntersBattlefieldTriggeredAbility( + new DamageTargetEffect(new PermanentsOnBattlefieldCount(filter)) + .setText("it deals damage to target creature an opponent controls equal to the number of Goblins you control") + ); + ability.addTarget(new TargetOpponentsCreaturePermanent()); + this.addAbility(ability); + } + + public VolleyVeteran(final VolleyVeteran card) { + super(card); + } + + @Override + public VolleyVeteran copy() { + return new VolleyVeteran(this); + } +} diff --git a/Mage.Sets/src/mage/sets/CoreSet2019.java b/Mage.Sets/src/mage/sets/CoreSet2019.java index af466206ac..691a4f1e23 100644 --- a/Mage.Sets/src/mage/sets/CoreSet2019.java +++ b/Mage.Sets/src/mage/sets/CoreSet2019.java @@ -181,6 +181,7 @@ public final class CoreSet2019 extends ExpansionSet { cards.add(new SetCardInfo("Vivien's Invocation", 209, Rarity.RARE, mage.cards.v.ViviensInvocation.class)); cards.add(new SetCardInfo("Vivien's Jaguar", 305, Rarity.UNCOMMON, mage.cards.v.ViviensJaguar.class)); cards.add(new SetCardInfo("Volcanic Dragon", 167, Rarity.UNCOMMON, mage.cards.v.VolcanicDragon.class)); + cards.add(new SetCardInfo("Volley Veteran", 168, Rarity.UNCOMMON, mage.cards.v.VolleyVeteran.class)); cards.add(new SetCardInfo("Walking Corpse", 126, Rarity.COMMON, mage.cards.w.WalkingCorpse.class)); cards.add(new SetCardInfo("Wall of Mist", 83, Rarity.COMMON, mage.cards.w.WallOfMist.class)); cards.add(new SetCardInfo("Wall of Vines", 210, Rarity.COMMON, mage.cards.w.WallOfVines.class));