diff --git a/Mage.Sets/src/mage/cards/c/CrackleWithPower.java b/Mage.Sets/src/mage/cards/c/CrackleWithPower.java new file mode 100644 index 0000000000..42beef5a4c --- /dev/null +++ b/Mage.Sets/src/mage/cards/c/CrackleWithPower.java @@ -0,0 +1,52 @@ +package mage.cards.c; + +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.dynamicvalue.MultipliedValue; +import mage.abilities.dynamicvalue.common.ManacostVariableValue; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.game.Game; +import mage.target.common.TargetAnyTarget; +import mage.target.targetadjustment.TargetAdjuster; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class CrackleWithPower extends CardImpl { + + private static final DynamicValue value = new MultipliedValue(ManacostVariableValue.instance, 5); + + public CrackleWithPower(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{X}{R}{R}"); + + // Crackle with Power deals five times X damage to up to X targets. + this.getSpellAbility().addEffect( + new DamageTargetEffect(value).setText("{this} deals five times X damage to up to X targets") + ); + this.getSpellAbility().setTargetAdjuster(CrackleWithPowerAdjuster.instance); + } + + private CrackleWithPower(final CrackleWithPower card) { + super(card); + } + + @Override + public CrackleWithPower copy() { + return new CrackleWithPower(this); + } +} + +enum CrackleWithPowerAdjuster implements TargetAdjuster { + instance; + + @Override + public void adjustTargets(Ability ability, Game game) { + ability.getTargets().clear(); + ability.addTarget(new TargetAnyTarget(0, ability.getManaCostsToPay().getX())); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java b/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java index d7841d5cc7..db0e00728b 100644 --- a/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java +++ b/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java @@ -42,6 +42,7 @@ public final class StrixhavenSchoolOfMages extends ExpansionSet { cards.add(new SetCardInfo("Campus Guide", 252, Rarity.COMMON, mage.cards.c.CampusGuide.class)); cards.add(new SetCardInfo("Clever Lumimancer", 10, Rarity.UNCOMMON, mage.cards.c.CleverLumimancer.class)); cards.add(new SetCardInfo("Combat Professor", 11, Rarity.COMMON, mage.cards.c.CombatProfessor.class)); + cards.add(new SetCardInfo("Crackle with Power", 95, Rarity.MYTHIC, mage.cards.c.CrackleWithPower.class)); cards.add(new SetCardInfo("Creative Outburst", 171, Rarity.UNCOMMON, mage.cards.c.CreativeOutburst.class)); cards.add(new SetCardInfo("Culmination of Studies", 173, Rarity.RARE, mage.cards.c.CulminationOfStudies.class)); cards.add(new SetCardInfo("Curate", 40, Rarity.COMMON, mage.cards.c.Curate.class));