diff --git a/Mage.Sets/src/mage/cards/h/HaldirLorienLieutenant.java b/Mage.Sets/src/mage/cards/h/HaldirLorienLieutenant.java new file mode 100644 index 0000000000..d30f9a82e5 --- /dev/null +++ b/Mage.Sets/src/mage/cards/h/HaldirLorienLieutenant.java @@ -0,0 +1,70 @@ +package mage.cards.h; + +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.dynamicvalue.common.CountersSourceCount; +import mage.abilities.effects.common.EntersBattlefieldWithXCountersEffect; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.SubType; +import mage.constants.SuperType; +import mage.counters.CounterType; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class HaldirLorienLieutenant extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent(SubType.ELF, ""); + private static final FilterCreaturePermanent filter2 = new FilterCreaturePermanent(SubType.ELF, ""); + private static final DynamicValue xValue = new CountersSourceCount(CounterType.P1P1); + + public HaldirLorienLieutenant(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{X}{G}"); + + this.supertype.add(SuperType.LEGENDARY); + this.subtype.add(SubType.ELF); + this.subtype.add(SubType.SOLDIER); + this.power = new MageInt(0); + this.toughness = new MageInt(0); + + // Haldir, Lorien Lieutenant enters the battlefield with X +1/+1 counters on it. + this.addAbility(new SimpleStaticAbility( + new EntersBattlefieldWithXCountersEffect(CounterType.P1P1.createInstance()) + )); + + // Vigilance + this.addAbility(VigilanceAbility.getInstance()); + + // {5}{G}: Until end of turn, other Elves you control gain vigilance and get +1/+1 for each +1/+1 counter on Haldir. + Ability ability = new SimpleActivatedAbility(new GainAbilityControlledEffect( + VigilanceAbility.getInstance(), Duration.EndOfTurn, filter, true + ).setText("until end of turn, other Elves you control gain vigilance"), new ManaCostsImpl<>("{5}{G}")); + ability.addEffect(new BoostControlledEffect( + xValue, xValue, Duration.EndOfTurn, filter2, true, true + ).setText("and get +1/+1 for each +1/+1 counter on {this}")); + this.addAbility(ability); + } + + private HaldirLorienLieutenant(final HaldirLorienLieutenant card) { + super(card); + } + + @Override + public HaldirLorienLieutenant copy() { + return new HaldirLorienLieutenant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/TalesOfMiddleEarthCommander.java b/Mage.Sets/src/mage/sets/TalesOfMiddleEarthCommander.java index cc4a0b99c6..f94256b604 100644 --- a/Mage.Sets/src/mage/sets/TalesOfMiddleEarthCommander.java +++ b/Mage.Sets/src/mage/sets/TalesOfMiddleEarthCommander.java @@ -113,6 +113,7 @@ public final class TalesOfMiddleEarthCommander extends ExpansionSet { cards.add(new SetCardInfo("Grey Host Reinforcements", 98, Rarity.RARE, mage.cards.g.GreyHostReinforcements.class, NON_FULL_USE_VARIOUS)); cards.add(new SetCardInfo("Growth Spiral", 267, Rarity.COMMON, mage.cards.g.GrowthSpiral.class)); cards.add(new SetCardInfo("Guttersnipe", 220, Rarity.UNCOMMON, mage.cards.g.Guttersnipe.class)); + cards.add(new SetCardInfo("Haldir, Lorien Lieutenant", 39, Rarity.RARE, mage.cards.h.HaldirLorienLieutenant.class)); cards.add(new SetCardInfo("Harmonize", 248, Rarity.UNCOMMON, mage.cards.h.Harmonize.class)); cards.add(new SetCardInfo("Harsh Mentor", 221, Rarity.RARE, mage.cards.h.HarshMentor.class)); cards.add(new SetCardInfo("Heirloom Blade", 279, Rarity.UNCOMMON, mage.cards.h.HeirloomBlade.class));