From 3989f410a126a3a1114913acd7e65e3e32b47653 Mon Sep 17 00:00:00 2001 From: Grath <1895280+Grath@users.noreply.github.com> Date: Wed, 8 Feb 2023 21:35:39 -0500 Subject: [PATCH] [ONC] Implement Urtet, Remnant of Memnarch (#9914) --- .../mage/cards/u/UrtetRemnantOfMemnarch.java | 66 +++++++++++++++++++ .../sets/PhyrexiaAllWillBeOneCommander.java | 1 + 2 files changed, 67 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/u/UrtetRemnantOfMemnarch.java diff --git a/Mage.Sets/src/mage/cards/u/UrtetRemnantOfMemnarch.java b/Mage.Sets/src/mage/cards/u/UrtetRemnantOfMemnarch.java new file mode 100644 index 00000000000..33344cfaf1d --- /dev/null +++ b/Mage.Sets/src/mage/cards/u/UrtetRemnantOfMemnarch.java @@ -0,0 +1,66 @@ +package mage.cards.u; + +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.ActivateIfConditionActivatedAbility; +import mage.abilities.common.BeginningOfCombatTriggeredAbility; +import mage.abilities.common.SpellCastControllerTriggeredAbility; +import mage.abilities.condition.common.MyTurnCondition; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.UntapAllControllerEffect; +import mage.abilities.effects.common.counter.AddCountersAllEffect; +import mage.abilities.hint.common.MyTurnHint; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.*; +import mage.counters.CounterType; +import mage.filter.FilterSpell; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.game.permanent.token.MyrToken; + +import java.util.UUID; + +/** + * @author Grath + */ +public final class UrtetRemnantOfMemnarch extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("a Myr spell"); + private static final FilterControlledCreaturePermanent filter2 = new FilterControlledCreaturePermanent(SubType.MYR); + + static { + filter.add(SubType.MYR.getPredicate()); + } + + public UrtetRemnantOfMemnarch(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{3}"); + + this.addSuperType(SuperType.LEGENDARY); + this.subtype.add(SubType.MYR); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever you cast a Myr spell, create a 1/1 colorless Myr artifact creature token. + this.addAbility(new SpellCastControllerTriggeredAbility(new CreateTokenEffect(new MyrToken()), filter, false)); + + //At the beginning of combat on your turn, untap each Myr you control. + this.addAbility(new BeginningOfCombatTriggeredAbility(new UntapAllControllerEffect(filter2, "untap each Myr you control"), TargetController.YOU, false)); + + // {W}{U}{B}{R}{G}, {T}: Put three +1/+1 counters on each Myr you control. Activate only during your turn. + Ability ability = new ActivateIfConditionActivatedAbility(Zone.BATTLEFIELD, new AddCountersAllEffect(CounterType.P1P1.createInstance(3), filter2), new ManaCostsImpl<>("{W}{U}{B}{R}{G}"), MyTurnCondition.instance); + ability.addCost(new TapSourceCost()); + ability.addHint(MyTurnHint.instance); + this.addAbility(ability); + } + + private UrtetRemnantOfMemnarch(final UrtetRemnantOfMemnarch card) { + super(card); + } + + @Override + public UrtetRemnantOfMemnarch copy() { + return new UrtetRemnantOfMemnarch(this); + } +} diff --git a/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOneCommander.java b/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOneCommander.java index d8aa6e0ccc8..97d93df2f62 100644 --- a/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOneCommander.java +++ b/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOneCommander.java @@ -135,6 +135,7 @@ public final class PhyrexiaAllWillBeOneCommander extends ExpansionSet { cards.add(new SetCardInfo("Temple of Triumph", 173, Rarity.RARE, mage.cards.t.TempleOfTriumph.class)); cards.add(new SetCardInfo("Temple of the False God", 172, Rarity.UNCOMMON, mage.cards.t.TempleOfTheFalseGod.class)); cards.add(new SetCardInfo("Trailblazer's Boots", 144, Rarity.UNCOMMON, mage.cards.t.TrailblazersBoots.class)); + cards.add(new SetCardInfo("Urtet, Remnant of Memnarch", 28, Rarity.MYTHIC, mage.cards.u.UrtetRemnantOfMemnarch.class)); cards.add(new SetCardInfo("Viridian Corrupter", 113, Rarity.UNCOMMON, mage.cards.v.ViridianCorrupter.class)); cards.add(new SetCardInfo("White Sun's Zenith", 90, Rarity.RARE, mage.cards.w.WhiteSunsZenith.class)); cards.add(new SetCardInfo("Windborn Muse", 91, Rarity.RARE, mage.cards.w.WindbornMuse.class));