From a66b465bf214b2a1324fbba6431bf495e2372a52 Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Wed, 3 Nov 2021 09:18:34 -0400 Subject: [PATCH] [VOW] Implemented Stensia Uprising --- .../src/mage/cards/s/StensiaUprising.java | 69 +++++++++++++++++++ .../src/mage/sets/InnistradCrimsonVow.java | 1 + 2 files changed, 70 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/s/StensiaUprising.java diff --git a/Mage.Sets/src/mage/cards/s/StensiaUprising.java b/Mage.Sets/src/mage/cards/s/StensiaUprising.java new file mode 100644 index 0000000000..265c641088 --- /dev/null +++ b/Mage.Sets/src/mage/cards/s/StensiaUprising.java @@ -0,0 +1,69 @@ +package mage.cards.s; + +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.delayed.ReflexiveTriggeredAbility; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DoWhenCostPaid; +import mage.abilities.hint.Hint; +import mage.abilities.hint.ValueHint; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.constants.ComparisonType; +import mage.constants.TargetController; +import mage.filter.StaticFilters; +import mage.game.permanent.token.RedHumanToken; +import mage.target.common.TargetAnyTarget; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class StensiaUprising extends CardImpl { + + private static final Condition condition = new PermanentsOnTheBattlefieldCondition( + StaticFilters.FILTER_PERMANENT, ComparisonType.EQUAL_TO, 13, true + ); + private static final Hint hint = new ValueHint( + "Permanents you control", + new PermanentsOnBattlefieldCount( + StaticFilters.FILTER_CONTROLLED_PERMANENT + ) + ); + + public StensiaUprising(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}{R}"); + + // At the beginning of your end step, create a 1/1 red Human creature token. Then if you control exactly thirteen permanents, you may sacrifice Stensia Uprising. When you do, it deals 7 damage to any target. + ReflexiveTriggeredAbility reflexiveTrigger = new ReflexiveTriggeredAbility( + new DamageTargetEffect(7), false, "{this} deals 7 damage to any target" + ); + reflexiveTrigger.addTarget(new TargetAnyTarget()); + Ability ability = new BeginningOfUpkeepTriggeredAbility( + new CreateTokenEffect(new RedHumanToken()), TargetController.YOU, false + ); + ability.addEffect(new ConditionalOneShotEffect( + new DoWhenCostPaid(reflexiveTrigger, new SacrificeSourceCost(), "Sacrifice {this}?"), + condition, "Then if you control exactly thirteen permanents, " + + "you may sacrifice {this}. When you do, it deals 7 damage to any target." + )); + this.addAbility(ability.addHint(hint)); + } + + private StensiaUprising(final StensiaUprising card) { + super(card); + } + + @Override + public StensiaUprising copy() { + return new StensiaUprising(this); + } +} diff --git a/Mage.Sets/src/mage/sets/InnistradCrimsonVow.java b/Mage.Sets/src/mage/sets/InnistradCrimsonVow.java index f811b71e4e..bd0c57e32f 100644 --- a/Mage.Sets/src/mage/sets/InnistradCrimsonVow.java +++ b/Mage.Sets/src/mage/sets/InnistradCrimsonVow.java @@ -107,6 +107,7 @@ public final class InnistradCrimsonVow extends ExpansionSet { cards.add(new SetCardInfo("Scattered Thoughts", 74, Rarity.COMMON, mage.cards.s.ScatteredThoughts.class)); cards.add(new SetCardInfo("Shattered Sanctum", 264, Rarity.RARE, mage.cards.s.ShatteredSanctum.class)); cards.add(new SetCardInfo("Sorin the Mirthless", 131, Rarity.MYTHIC, mage.cards.s.SorinTheMirthless.class)); + cards.add(new SetCardInfo("Stensia Uprising", 178, Rarity.RARE, mage.cards.s.StensiaUprising.class)); cards.add(new SetCardInfo("Stormcarved Coast", 265, Rarity.RARE, mage.cards.s.StormcarvedCoast.class)); cards.add(new SetCardInfo("Sundown Pass", 266, Rarity.RARE, mage.cards.s.SundownPass.class)); cards.add(new SetCardInfo("Swamp", 272, Rarity.LAND, mage.cards.basiclands.Swamp.class, FULL_ART_BFZ_VARIOUS));