From 4461f331637858969ece39a661ece72b525a6dbe Mon Sep 17 00:00:00 2001 From: theelk801 Date: Sat, 21 Jan 2023 10:22:42 -0500 Subject: [PATCH] [ONE] Implement Surgical Spellbomb --- .../src/mage/cards/s/SurgicalSkullbomb.java | 52 +++++++++++++++++++ .../src/mage/sets/PhyrexiaAllWillBeOne.java | 1 + 2 files changed, 53 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/s/SurgicalSkullbomb.java diff --git a/Mage.Sets/src/mage/cards/s/SurgicalSkullbomb.java b/Mage.Sets/src/mage/cards/s/SurgicalSkullbomb.java new file mode 100644 index 0000000000..eff102d3ec --- /dev/null +++ b/Mage.Sets/src/mage/cards/s/SurgicalSkullbomb.java @@ -0,0 +1,52 @@ +package mage.cards.s; + +import java.util.UUID; + +import mage.abilities.Ability; +import mage.abilities.common.ActivateAsSorceryActivatedAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.counters.CounterType; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * @author TheElk801 + */ +public final class SurgicalSkullbomb extends CardImpl { + + public SurgicalSkullbomb(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{1}"); + + // {1}, Sacrifice Surgical Skullbomb: Draw a card. + Ability ability = new SimpleActivatedAbility( + new DrawCardSourceControllerEffect(1), new GenericManaCost(1) + ); + ability.addCost(new SacrificeSourceCost()); + this.addAbility(ability); + + // {2}{U}, Sacrifice Surgical Skullbomb: Return target creature to its owner's hand. Draw a card. Activate only as a sorcery. + ability = new ActivateAsSorceryActivatedAbility(new ReturnToHandTargetEffect(), new ManaCostsImpl<>("{2}{U}")); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new DrawCardSourceControllerEffect(1)); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + private SurgicalSkullbomb(final SurgicalSkullbomb card) { + super(card); + } + + @Override + public SurgicalSkullbomb copy() { + return new SurgicalSkullbomb(this); + } +} diff --git a/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOne.java b/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOne.java index 84c918e498..f4c69216e1 100644 --- a/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOne.java +++ b/Mage.Sets/src/mage/sets/PhyrexiaAllWillBeOne.java @@ -89,6 +89,7 @@ public final class PhyrexiaAllWillBeOne extends ExpansionSet { cards.add(new SetCardInfo("Sinew Dancer", 32, Rarity.COMMON, mage.cards.s.SinewDancer.class)); cards.add(new SetCardInfo("Skrelv's Hive", 34, Rarity.RARE, mage.cards.s.SkrelvsHive.class)); cards.add(new SetCardInfo("Staff of Compleation", 242, Rarity.MYTHIC, mage.cards.s.StaffOfCompleation.class)); + cards.add(new SetCardInfo("Surgical Skullbomb", 243, Rarity.COMMON, mage.cards.s.SurgicalSkullbomb.class)); cards.add(new SetCardInfo("Swamp", 274, Rarity.LAND, mage.cards.basiclands.Swamp.class, NON_FULL_USE_VARIOUS)); cards.add(new SetCardInfo("Swooping Lookout", 35, Rarity.UNCOMMON, mage.cards.s.SwoopingLookout.class)); cards.add(new SetCardInfo("Tablet of Compleation", 245, Rarity.RARE, mage.cards.t.TabletOfCompleation.class));