From fffb299581e79ceb71e156a4037e5fd5347dd38a Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Fri, 7 Sep 2018 23:26:28 -0400 Subject: [PATCH] Implemented Ral, Caller of Storms --- .../src/mage/cards/r/RalCallerOfStorms.java | 57 +++++++++++++++++++ Mage.Sets/src/mage/sets/GuildsOfRavnica.java | 1 + .../effects/common/DamageMultiEffect.java | 4 +- 3 files changed, 61 insertions(+), 1 deletion(-) create mode 100644 Mage.Sets/src/mage/cards/r/RalCallerOfStorms.java diff --git a/Mage.Sets/src/mage/cards/r/RalCallerOfStorms.java b/Mage.Sets/src/mage/cards/r/RalCallerOfStorms.java new file mode 100644 index 0000000000..7359b2352c --- /dev/null +++ b/Mage.Sets/src/mage/cards/r/RalCallerOfStorms.java @@ -0,0 +1,57 @@ +package mage.cards.r; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.LoyaltyAbility; +import mage.abilities.common.PlanswalkerEntersWithLoyalityCountersAbility; +import mage.abilities.effects.common.DamageAllEffect; +import mage.abilities.effects.common.DamageMultiEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.constants.SubType; +import mage.constants.SuperType; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.filter.common.FilterCreaturePermanent; +import mage.target.common.TargetAnyTargetAmount; + +/** + * + * @author TheElk801 + */ +public final class RalCallerOfStorms extends CardImpl { + + public static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature your opponents control"); + + public RalCallerOfStorms(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.PLANESWALKER}, "{4}{U}{R}"); + + this.addSuperType(SuperType.LEGENDARY); + this.subtype.add(SubType.RAL); + this.addAbility(new PlanswalkerEntersWithLoyalityCountersAbility(4)); + + // +1: Draw a card. + this.addAbility(new LoyaltyAbility( + new DrawCardSourceControllerEffect(1), 1 + )); + + // -2: Ral, Caller of Storms deals 3 damage divided as you choose among one, two, or three targets. + Ability ability = new LoyaltyAbility(new DamageMultiEffect(3), -2); + ability.addTarget(new TargetAnyTargetAmount(3)); + this.addAbility(ability); + + // -7: Draw seven cards. Ral, Caller of Storms deals 7 damage to each creature your opponents control. + ability = new LoyaltyAbility(new DrawCardSourceControllerEffect(7), -7); + ability.addEffect(new DamageAllEffect(7, filter)); + this.addAbility(ability); + } + + public RalCallerOfStorms(final RalCallerOfStorms card) { + super(card); + } + + @Override + public RalCallerOfStorms copy() { + return new RalCallerOfStorms(this); + } +} diff --git a/Mage.Sets/src/mage/sets/GuildsOfRavnica.java b/Mage.Sets/src/mage/sets/GuildsOfRavnica.java index c48a3e76cd..a0256d8b47 100644 --- a/Mage.Sets/src/mage/sets/GuildsOfRavnica.java +++ b/Mage.Sets/src/mage/sets/GuildsOfRavnica.java @@ -47,6 +47,7 @@ public final class GuildsOfRavnica extends ExpansionSet { cards.add(new SetCardInfo("Plains", 260, Rarity.LAND, mage.cards.basiclands.Plains.class, NON_FULL_USE_VARIOUS)); cards.add(new SetCardInfo("Quasiduplicate", 51, Rarity.RARE, mage.cards.q.Quasiduplicate.class)); cards.add(new SetCardInfo("Radical Idea", 52, Rarity.COMMON, mage.cards.r.RadicalIdea.class)); + cards.add(new SetCardInfo("Ral, Caller of Storms", 265, Rarity.MYTHIC, mage.cards.r.RalCallerOfStorms.class)); cards.add(new SetCardInfo("Ral, Izzet Viceroy", 195, Rarity.MYTHIC, mage.cards.r.RalIzzetViceroy.class)); cards.add(new SetCardInfo("Rosemane Centaur", 197, Rarity.COMMON, mage.cards.r.RosemaneCentaur.class)); cards.add(new SetCardInfo("Sacred Foundry", 254, Rarity.RARE, mage.cards.s.SacredFoundry.class)); diff --git a/Mage/src/main/java/mage/abilities/effects/common/DamageMultiEffect.java b/Mage/src/main/java/mage/abilities/effects/common/DamageMultiEffect.java index 5e15a0c802..df18d2d691 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/DamageMultiEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/DamageMultiEffect.java @@ -1,4 +1,3 @@ - package mage.abilities.effects.common; import java.util.UUID; @@ -71,6 +70,9 @@ public class DamageMultiEffect extends OneShotEffect { if (staticText != null && !staticText.isEmpty()) { return staticText; } + if (amount.toString().equals("3")) { + return this.sourceName + " deals 3 damage divided as you choose among one, two, or three targets"; + } return this.sourceName + " deals " + amount.toString() + " damage divided as you choose among any number of " + mode.getTargets().get(0).getTargetName(); }