From e5846d8d0aa40070eaa6529319f40de1100a5337 Mon Sep 17 00:00:00 2001 From: jmlundeen Date: Thu, 6 Mar 2025 22:36:45 -0600 Subject: [PATCH] [DRC] Saheeli, Radiant Creation --- .../mage/cards/s/SaheeliRadiantCreator.java | 108 ++++++++++++++++++ .../src/mage/sets/AetherdriftCommander.java | 1 + 2 files changed, 109 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/s/SaheeliRadiantCreator.java diff --git a/Mage.Sets/src/mage/cards/s/SaheeliRadiantCreator.java b/Mage.Sets/src/mage/cards/s/SaheeliRadiantCreator.java new file mode 100644 index 00000000000..970968117af --- /dev/null +++ b/Mage.Sets/src/mage/cards/s/SaheeliRadiantCreator.java @@ -0,0 +1,108 @@ +package mage.cards.s; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SpellCastControllerTriggeredAbility; +import mage.abilities.common.delayed.ReflexiveTriggeredAbility; +import mage.abilities.costs.common.PayEnergyCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.CreateTokenCopyTargetEffect; +import mage.abilities.effects.common.DoWhenCostPaid; +import mage.abilities.effects.common.counter.GetEnergyCountersControllerEffect; +import mage.abilities.triggers.BeginningOfCombatTriggeredAbility; +import mage.constants.Outcome; +import mage.constants.SubType; +import mage.constants.SuperType; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.filter.FilterSpell; +import mage.filter.StaticFilters; +import mage.filter.predicate.Predicates; +import mage.game.Game; +import mage.target.TargetPermanent; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author Jmlundeen + */ +public final class SaheeliRadiantCreator extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("Artificer or artifact spell"); + + static { + filter.add(Predicates.or( + SubType.ARTIFICER.getPredicate(), + CardType.ARTIFACT.getPredicate()) + ); + } + + public SaheeliRadiantCreator(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{G}{U}{R}"); + + this.supertype.add(SuperType.LEGENDARY); + this.subtype.add(SubType.HUMAN); + this.subtype.add(SubType.ARTIFICER); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Whenever you cast an Artificer or artifact spell, you get {E}. + Ability ability = new SpellCastControllerTriggeredAbility( + new GetEnergyCountersControllerEffect(1), + filter, false); + this.addAbility(ability); + + // At the beginning of combat on your turn, you may pay {E}{E}{E}. When you do, create a token that's a copy of target permanent you control, except it's a 5/5 artifact creature in addition to its other types and has haste. Sacrifice it at the beginning of the next end step. + ReflexiveTriggeredAbility reflexiveAbility = new ReflexiveTriggeredAbility( + new SaheeliRadiantCreatorCopyEffect(), false + ); + reflexiveAbility.addTarget(new TargetPermanent(StaticFilters.FILTER_CONTROLLED_A_PERMANENT)); + Ability combatTriggeredAbility = new BeginningOfCombatTriggeredAbility( + new DoWhenCostPaid(reflexiveAbility, new PayEnergyCost(3), + "Pay {E}{E}{E}?") + ); + this.addAbility(combatTriggeredAbility); + } + + private SaheeliRadiantCreator(final SaheeliRadiantCreator card) { + super(card); + } + + @Override + public SaheeliRadiantCreator copy() { + return new SaheeliRadiantCreator(this); + } +} + +class SaheeliRadiantCreatorCopyEffect extends OneShotEffect { + + public SaheeliRadiantCreatorCopyEffect() { + super(Outcome.Copy); + staticText = "create a token that's a copy of target permanent you control, " + + "except it's a 5/5 artifact creature in addition to its other types and has haste. " + + "Sacrifice it at the beginning of the next end step."; + } + + public SaheeliRadiantCreatorCopyEffect(final SaheeliRadiantCreatorCopyEffect effect) { + super(effect); + } + + @Override + public SaheeliRadiantCreatorCopyEffect copy() { + return new SaheeliRadiantCreatorCopyEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + CreateTokenCopyTargetEffect effect = new CreateTokenCopyTargetEffect(null, CardType.CREATURE, + true, 1, false, false, null, + 5, 5, false); + effect.setBecomesArtifact(true); + effect.setTargetPointer(new FixedTarget(source.getFirstTarget())); + effect.apply(game, source); + effect.sacrificeTokensCreatedAtNextEndStep(game, source); + return true; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/AetherdriftCommander.java b/Mage.Sets/src/mage/sets/AetherdriftCommander.java index 39ca1c770a6..321005e2899 100644 --- a/Mage.Sets/src/mage/sets/AetherdriftCommander.java +++ b/Mage.Sets/src/mage/sets/AetherdriftCommander.java @@ -142,6 +142,7 @@ public final class AetherdriftCommander extends ExpansionSet { cards.add(new SetCardInfo("Rogue Refiner", 118, Rarity.UNCOMMON, mage.cards.r.RogueRefiner.class)); cards.add(new SetCardInfo("Rootbound Crag", 168, Rarity.RARE, mage.cards.r.RootboundCrag.class)); cards.add(new SetCardInfo("Rot Hulk", 98, Rarity.MYTHIC, mage.cards.r.RotHulk.class)); + cards.add(new SetCardInfo("Saheeli, Radiant Creator", 3, Rarity.MYTHIC, mage.cards.s.SaheeliRadiantCreator.class)); cards.add(new SetCardInfo("Saheeli, Sublime Artificer", 119, Rarity.UNCOMMON, mage.cards.s.SaheeliSublimeArtificer.class)); cards.add(new SetCardInfo("Sai, Master Thopterist", 82, Rarity.RARE, mage.cards.s.SaiMasterThopterist.class)); cards.add(new SetCardInfo("Servant of the Conduit", 114, Rarity.UNCOMMON, mage.cards.s.ServantOfTheConduit.class));