mirror of
https://github.com/correl/mage.git
synced 2025-01-13 19:11:33 +00:00
Improve text generation for DamageMultiEffect
This commit is contained in:
parent
c4a0a18066
commit
faf2e4ec82
37 changed files with 94 additions and 168 deletions
|
@ -1,8 +1,6 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.cards.CardImpl;
|
||||
|
@ -28,11 +26,8 @@ public final class AerialVolley extends CardImpl {
|
|||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{G}");
|
||||
|
||||
// Aerial Volley deals 3 damage divided as you choose among one, two, or three target creatures with flying.
|
||||
Effect effect = new DamageMultiEffect(3);
|
||||
effect.setText("{this} deals 3 damage divided as you choose among one, two, or three target creatures with flying");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3, filter));
|
||||
|
||||
}
|
||||
|
||||
private AerialVolley(final AerialVolley card) {
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
|
||||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -18,7 +16,7 @@ public final class ArcLightning extends CardImpl {
|
|||
public ArcLightning(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{R}");
|
||||
|
||||
// Arc Lightning deals 3 damage divided as you choose among one, two, or three target creatures and/or players.
|
||||
// Arc Lightning deals 3 damage divided as you choose among one, two, or three targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(3));
|
||||
}
|
||||
|
@ -31,4 +29,4 @@ public final class ArcLightning extends CardImpl {
|
|||
public ArcLightning copy() {
|
||||
return new ArcLightning(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -8,7 +7,6 @@ import mage.abilities.common.SimpleActivatedAbility;
|
|||
import mage.abilities.costs.common.DiscardCardCost;
|
||||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
|
@ -30,10 +28,8 @@ public final class ArcMage extends CardImpl {
|
|||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// {2}{R}, {tap}, Discard a card: Arc Mage deals 2 damage divided as you choose among one or two target creatures and/or players.
|
||||
Effect effect = new DamageMultiEffect(2);
|
||||
effect.setText("{this} deals 2 damage divided as you choose among one or two target creatures and/or players");
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{2}{R}"));
|
||||
// {2}{R}, {tap}, Discard a card: Arc Mage deals 2 damage divided as you choose among one or two targets.
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageMultiEffect(2), new ManaCostsImpl("{2}{R}"));
|
||||
ability.addCost(new TapSourceCost());
|
||||
ability.addCost(new DiscardCardCost());
|
||||
ability.addTarget(new TargetAnyTargetAmount(2));
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.a;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -11,7 +10,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.filter.common.FilterAttackingCreature;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetCreaturePermanentAmount;
|
||||
|
||||
|
@ -29,8 +28,7 @@ public final class ArrowVolleyTrap extends CardImpl {
|
|||
|
||||
// Arrow Volley Trap deals 5 damage divided as you choose among any number of target attacking creatures.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(5));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(5, new FilterAttackingCreature("attacking creatures")));
|
||||
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(5, StaticFilters.FILTER_ATTACKING_CREATURES));
|
||||
}
|
||||
|
||||
private ArrowVolleyTrap(final ArrowVolleyTrap card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.b;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -17,7 +16,7 @@ public final class Boulderfall extends CardImpl {
|
|||
public Boulderfall(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{6}{R}{R}");
|
||||
|
||||
// Boulderfall deals 5 damage divided as you choose among any number of target creatures and/or players.
|
||||
// Boulderfall deals 5 damage divided as you choose among any number of targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(5));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(5));
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -15,7 +14,7 @@ import mage.target.TargetPlayer;
|
|||
*/
|
||||
public final class CelestialFlare extends CardImpl {
|
||||
|
||||
private static final FilterAttackingOrBlockingCreature filter = new FilterAttackingOrBlockingCreature("attacking or blocking creature");
|
||||
private static final FilterAttackingOrBlockingCreature filter = new FilterAttackingOrBlockingCreature("an attacking or blocking creature");
|
||||
|
||||
public CelestialFlare(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{W}{W}");
|
||||
|
@ -35,4 +34,4 @@ public final class CelestialFlare extends CardImpl {
|
|||
public CelestialFlare copy() {
|
||||
return new CelestialFlare(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
|
@ -18,9 +17,7 @@ public final class ChandrasPyrohelix extends CardImpl {
|
|||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{R}");
|
||||
|
||||
// Chandra's Pyrohelix deals 2 damage divided as you choose among one or two targets.
|
||||
Effect effect = new DamageMultiEffect(2);
|
||||
effect.setText("{this} deals 2 damage divided as you choose among one or two targets");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(2));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(2));
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.c;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -13,8 +12,7 @@ import mage.abilities.keyword.FlashbackAbility;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.TimingRule;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.game.Game;
|
||||
import mage.target.common.TargetAnyTargetAmount;
|
||||
|
||||
|
@ -27,14 +25,14 @@ public final class Conflagrate extends CardImpl {
|
|||
public Conflagrate(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{R}");
|
||||
|
||||
// Conflagrate deals X damage divided as you choose among any number of target creatures and/or players.
|
||||
// Conflagrate deals X damage divided as you choose among any number of targets.
|
||||
DynamicValue xValue = new ConflagrateVariableValue();
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(xValue));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(xValue));
|
||||
|
||||
// Flashback-{R}{R}, Discard X cards.
|
||||
Ability ability = new FlashbackAbility(this, new ManaCostsImpl("{R}{R}"));
|
||||
ability.addCost(new DiscardXTargetCost(new FilterCard("cards")));
|
||||
ability.addCost(new DiscardXTargetCost(StaticFilters.FILTER_CARD_CARDS));
|
||||
this.addAbility(ability);
|
||||
|
||||
}
|
||||
|
|
|
@ -1,13 +1,11 @@
|
|||
|
||||
package mage.cards.d;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.common.FilterAttackingOrBlockingCreature;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetCreaturePermanentAmount;
|
||||
|
||||
/**
|
||||
|
@ -20,10 +18,8 @@ public final class DeftDismissal extends CardImpl {
|
|||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{3}{W}");
|
||||
|
||||
// Deft Dismissal deals 3 damage divided as you choose among one, two, or three target attacking or blocking creatures.
|
||||
Effect effect = new DamageMultiEffect(3);
|
||||
effect.setText("{this} deals 3 damage divided as you choose among one, two, or three target attacking or blocking creatures");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3, new FilterAttackingOrBlockingCreature("attacking or blocking creatures")));
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3, StaticFilters.FILTER_ATTACKING_OR_BLOCKING_CREATURES));
|
||||
}
|
||||
|
||||
private DeftDismissal(final DeftDismissal card) {
|
||||
|
|
|
@ -22,7 +22,7 @@ import mage.target.common.TargetCreatureOrPlaneswalkerAmount;
|
|||
*/
|
||||
public final class DragonlordAtarka extends CardImpl {
|
||||
|
||||
private static final FilterCreatureOrPlaneswalkerPermanent filter = new FilterCreatureOrPlaneswalkerPermanent("target creatures and/or planeswalkers your opponents control");
|
||||
private static final FilterCreatureOrPlaneswalkerPermanent filter = new FilterCreatureOrPlaneswalkerPermanent("creatures and/or planeswalkers your opponents control");
|
||||
|
||||
static {
|
||||
filter.add(TargetController.OPPONENT.getControllerPredicate());
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
|
||||
package mage.cards.e;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
import mage.cards.CardImpl;
|
||||
|
@ -19,11 +17,8 @@ public final class Electrolyze extends CardImpl {
|
|||
public Electrolyze(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{U}{R}");
|
||||
|
||||
|
||||
// Electrolyze deals 2 damage divided as you choose among one or two target creatures and/or players.
|
||||
Effect effect = new DamageMultiEffect(2);
|
||||
effect.setText("{this} deals 2 damage divided as you choose among one or two targets");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
// Electrolyze deals 2 damage divided as you choose among one or two targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(2));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(2));
|
||||
// Draw a card.
|
||||
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1).concatBy("<br>"));
|
||||
|
|
|
@ -21,8 +21,7 @@ public final class FieryJustice extends CardImpl {
|
|||
public FieryJustice(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{R}{G}{W}");
|
||||
|
||||
|
||||
// Fiery Justice deals 5 damage divided as you choose among any number of target creatures and/or players. Target opponent gains 5 life.
|
||||
// Fiery Justice deals 5 damage divided as you choose among any number of targets. Target opponent gains 5 life.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(5));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(5));
|
||||
Effect effect = new GainLifeTargetEffect(5);
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.f;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -6,10 +5,7 @@ import mage.abilities.effects.common.DamageMultiEffect;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.permanent.AttackingPredicate;
|
||||
import mage.filter.predicate.permanent.BlockingPredicate;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetCreaturePermanentAmount;
|
||||
|
||||
/**
|
||||
|
@ -19,21 +15,12 @@ import mage.target.common.TargetCreaturePermanentAmount;
|
|||
*/
|
||||
public final class FireAtWill extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("attacking or blocking creatures");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(
|
||||
AttackingPredicate.instance,
|
||||
BlockingPredicate.instance));
|
||||
}
|
||||
|
||||
public FireAtWill(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{R/W}{R/W}{R/W}");
|
||||
|
||||
// Fire at Will deals 3 damage divided as you choose among one, two, or three target attacking or blocking creatures.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3).setText("{this} deals 3 damage divided as you choose among one, two, or three target attacking or blocking creatures."));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3, filter));
|
||||
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3, StaticFilters.FILTER_ATTACKING_OR_BLOCKING_CREATURES));
|
||||
}
|
||||
|
||||
private FireAtWill(final FireAtWill card) {
|
||||
|
|
|
@ -1,8 +1,6 @@
|
|||
|
||||
package mage.cards.f;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
import mage.abilities.effects.common.TapTargetEffect;
|
||||
|
@ -19,10 +17,8 @@ public final class FireIce extends SplitCard {
|
|||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{R}", "{1}{U}", SpellAbilityType.SPLIT);
|
||||
|
||||
// Fire
|
||||
// Fire deals 2 damage divided as you choose among one or two target creatures and/or players.
|
||||
Effect effect = new DamageMultiEffect(2);
|
||||
effect.setText("Fire deals 2 damage divided as you choose among one or two target creatures and/or players");
|
||||
getLeftHalfCard().getSpellAbility().addEffect(effect);
|
||||
// Fire deals 2 damage divided as you choose among one or two targets.
|
||||
getLeftHalfCard().getSpellAbility().addEffect(new DamageMultiEffect(2, "Fire"));
|
||||
getLeftHalfCard().getSpellAbility().addTarget(new TargetAnyTargetAmount(2));
|
||||
|
||||
// Ice
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.f;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -17,8 +16,7 @@ public final class FlamesOfTheFirebrand extends CardImpl {
|
|||
public FlamesOfTheFirebrand(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{2}{R}");
|
||||
|
||||
|
||||
// Flames of the Firebrand deals 3 damage divided as you choose among one, two, or three target creatures and/or players.
|
||||
// Flames of the Firebrand deals 3 damage divided as you choose among one, two, or three targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(3));
|
||||
}
|
||||
|
|
|
@ -32,7 +32,7 @@ public final class Flameshot extends CardImpl {
|
|||
this.addAbility(new AlternativeCostSourceAbility(new DiscardTargetCost(new TargetCardInHand(filter))));
|
||||
|
||||
// Flameshot deals 3 damage divided as you choose among one, two, or three target creatures.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3).setText("{this} deals 3 damage divided as you choose among one, two, or three target creatures"));
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3));
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package mage.cards.f;
|
||||
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
|
@ -17,10 +16,8 @@ public final class ForkedBolt extends CardImpl {
|
|||
public ForkedBolt(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{R}");
|
||||
|
||||
// Forked Bolt deals 2 damage divided as you choose among one or two target creatures and/or players.
|
||||
Effect effect = new DamageMultiEffect(2);
|
||||
effect.setText("{this} deals 2 damage divided as you choose among one or two target creatures and/or players");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
// Forked Bolt deals 2 damage divided as you choose among one or two targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(2));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(2));
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.g;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -26,7 +25,7 @@ public final class GangOfDevils extends CardImpl {
|
|||
this.power = new MageInt(3);
|
||||
this.toughness = new MageInt(3);
|
||||
|
||||
// When Gang of Devils dies, it deals 3 damage divided as you choose among one, two, or three target creatures and/or players.
|
||||
// When Gang of Devils dies, it deals 3 damage divided as you choose among one, two, or three targets.
|
||||
Ability ability = new DiesSourceTriggeredAbility(new DamageMultiEffect(3, "it"));
|
||||
ability.addTarget(new TargetAnyTargetAmount(3));
|
||||
this.addAbility(ability);
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.h;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -7,7 +6,7 @@ import mage.abilities.effects.common.DamageMultiEffect;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.common.FilterAttackingCreature;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetCreaturePermanentAmount;
|
||||
|
||||
/**
|
||||
|
@ -21,7 +20,7 @@ public final class HailOfArrows extends CardImpl {
|
|||
|
||||
// Hail of Arrows deals X damage divided as you choose among any number of target attacking creatures.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(ManacostVariableValue.REGULAR));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(ManacostVariableValue.REGULAR, new FilterAttackingCreature()));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(ManacostVariableValue.REGULAR, StaticFilters.FILTER_ATTACKING_CREATURES));
|
||||
}
|
||||
|
||||
private HailOfArrows(final HailOfArrows card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.i;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -29,9 +28,8 @@ public final class IgniteDisorder extends CardImpl {
|
|||
public IgniteDisorder(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{R}");
|
||||
|
||||
|
||||
// Ignite Disorder deals 3 damage divided as you choose among one, two, or three target white and/or blue creatures.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3).setText("{this} deals 3 damage divided as you choose among one, two, or three target white and/or blue creatures"));
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(3));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3, filter));
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.i;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -6,15 +5,12 @@ import mage.MageInt;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.EntersBattlefieldOrAttacksSourceTriggeredAbility;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.costs.mana.ColoredManaCost;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.abilities.effects.common.continuous.BoostSourceEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.Zone;
|
||||
import mage.constants.*;
|
||||
import mage.target.common.TargetAnyTargetAmount;
|
||||
|
||||
/**
|
||||
|
@ -31,9 +27,9 @@ public final class InfernoTitan extends CardImpl {
|
|||
this.toughness = new MageInt(6);
|
||||
|
||||
// {R}: Inferno Titan gets +1/+0 until end of turn.
|
||||
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{R}")));
|
||||
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), new ColoredManaCost(ColoredManaSymbol.R)));
|
||||
|
||||
// Whenever Inferno Titan enters the battlefield or attacks, it deals 3 damage divided as you choose among one, two, or three target creatures and/or players.
|
||||
// Whenever Inferno Titan enters the battlefield or attacks, it deals 3 damage divided as you choose among one, two, or three targets.
|
||||
Ability ability = new EntersBattlefieldOrAttacksSourceTriggeredAbility(new DamageMultiEffect(3, "it"));
|
||||
ability.addTarget(new TargetAnyTargetAmount(3));
|
||||
this.addAbility(ability);
|
||||
|
@ -47,5 +43,4 @@ public final class InfernoTitan extends CardImpl {
|
|||
public InfernoTitan copy() {
|
||||
return new InfernoTitan(this);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.j;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -17,25 +16,24 @@ import mage.target.common.TargetAnyTargetAmount;
|
|||
* @author jeffwadsworth
|
||||
*/
|
||||
public final class JawsOfStone extends CardImpl {
|
||||
|
||||
|
||||
static final private FilterControlledLandPermanent filter = new FilterControlledLandPermanent("mountains you control");
|
||||
|
||||
|
||||
static {
|
||||
filter.add(SubType.MOUNTAIN.getPredicate());
|
||||
}
|
||||
|
||||
static final private String rule = "{this} deals X damage divided as you choose among any number of target creatures and/or players, where X is the number of Mountains you control as you cast {this}";
|
||||
|
||||
static final private String rule = "{this} deals X damage divided as you choose among any number of targets, where X is the number of Mountains you control as you cast this spell";
|
||||
|
||||
public JawsOfStone(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{5}{R}");
|
||||
|
||||
// Jaws of Stone deals X damage divided as you choose among any number of target creatures and/or players, where X is the number of Mountains you control as you cast Jaws of Stone.
|
||||
// Jaws of Stone deals X damage divided as you choose among any number of targets, where X is the number of Mountains you control as you cast this spell.
|
||||
PermanentsOnBattlefieldCount mountains = new PermanentsOnBattlefieldCount(filter, null);
|
||||
Effect effect = new DamageMultiEffect(mountains);
|
||||
effect.setText(rule);
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(mountains));
|
||||
|
||||
}
|
||||
|
||||
private JawsOfStone(final JawsOfStone card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.k;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -11,7 +10,7 @@ import mage.cards.CardImpl;
|
|||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.filter.common.FilterControlledArtifactPermanent;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetControlledPermanent;
|
||||
import mage.target.common.TargetAnyTargetAmount;
|
||||
|
||||
|
@ -28,9 +27,9 @@ public final class KuldothaFlamefiend extends CardImpl {
|
|||
this.power = new MageInt(4);
|
||||
this.toughness = new MageInt(4);
|
||||
|
||||
// When Kuldotha Flamefiend enters the battlefield, you may sacrifice an artifact. If you do, Kuldotha Flamefiend deals 4 damage divided as you choose among any number of target creatures and/or players.
|
||||
// When Kuldotha Flamefiend enters the battlefield, you may sacrifice an artifact. If you do, Kuldotha Flamefiend deals 4 damage divided as you choose among any number of targets.
|
||||
EntersBattlefieldTriggeredAbility ability =
|
||||
new EntersBattlefieldTriggeredAbility(new DoIfCostPaid(new DamageMultiEffect(4), new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledArtifactPermanent("an artifact")))), false);
|
||||
new EntersBattlefieldTriggeredAbility(new DoIfCostPaid(new DamageMultiEffect(4), new SacrificeTargetCost(new TargetControlledPermanent(StaticFilters.FILTER_CONTROLLED_PERMANENT_ARTIFACT_AN))), false);
|
||||
ability.addTarget(new TargetAnyTargetAmount(4));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
@ -35,7 +35,7 @@ public final class MagmaOpus extends CardImpl {
|
|||
this.getSpellAbility().addEffect(new TapTargetEffect("tap two target permanents").setTargetPointer(new SecondTargetPointer()));
|
||||
this.getSpellAbility().addTarget(new TargetPermanent(2, StaticFilters.FILTER_PERMANENTS).withChooseHint("tap"));
|
||||
this.getSpellAbility().addEffect(new CreateTokenEffect(new Elemental44Token()));
|
||||
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(2).setText("Draw two cards"));
|
||||
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(2));
|
||||
|
||||
// {U/R}{U/R}, Discard Magma Opus: Create a Treasure token.
|
||||
Ability ability = new SimpleActivatedAbility(
|
||||
|
|
|
@ -20,7 +20,7 @@ public final class MeteorShower extends CardImpl {
|
|||
public MeteorShower(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{R}");
|
||||
|
||||
// Meteor Shower deals X plus 1 damage divided as you choose among any number of target creatures and/or players.
|
||||
// Meteor Shower deals X plus 1 damage divided as you choose among any number of targets.
|
||||
DynamicValue xValue = new IntPlusDynamicValue(1, ManacostVariableValue.REGULAR);
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(xValue));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(xValue));
|
||||
|
|
|
@ -18,7 +18,7 @@ public final class Pyrotechnics extends CardImpl {
|
|||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{4}{R}");
|
||||
|
||||
|
||||
// Pyrotechnics deals 4 damage divided as you choose among any number of target creatures and/or players.
|
||||
// Pyrotechnics deals 4 damage divided as you choose among any number of targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(4));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(4));
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -9,11 +8,9 @@ import mage.abilities.keyword.FlyingAbility;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.common.FilterAttackingOrBlockingCreature;
|
||||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.mageobject.AbilityPredicate;
|
||||
import mage.filter.predicate.permanent.AttackingPredicate;
|
||||
import mage.filter.predicate.permanent.BlockingPredicate;
|
||||
import mage.target.common.TargetCreaturePermanentAmount;
|
||||
|
||||
/**
|
||||
|
@ -22,13 +19,9 @@ import mage.target.common.TargetCreaturePermanentAmount;
|
|||
*/
|
||||
public final class RockSlide extends CardImpl {
|
||||
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("attacking or blocking creatures without flying");
|
||||
private static final FilterAttackingOrBlockingCreature filter = new FilterAttackingOrBlockingCreature("attacking or blocking creatures without flying");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(
|
||||
AttackingPredicate.instance,
|
||||
BlockingPredicate.instance
|
||||
));
|
||||
filter.add(Predicates.not(new AbilityPredicate(FlyingAbility.class)));
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -6,7 +5,7 @@ import mage.abilities.effects.common.DamageMultiEffect;
|
|||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.common.FilterAttackingOrBlockingCreature;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.target.common.TargetCreaturePermanentAmount;
|
||||
|
||||
/**
|
||||
|
@ -20,7 +19,7 @@ public final class RoilsRetribution extends CardImpl {
|
|||
|
||||
// Roil's Retribution deals 5 damage divided as you choose among any number of target attacking or blocking creatures.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(5));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(5, new FilterAttackingOrBlockingCreature("attacking or blocking creatures")));
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(5, StaticFilters.FILTER_ATTACKING_OR_BLOCKING_CREATURES));
|
||||
}
|
||||
|
||||
private RoilsRetribution(final RoilsRetribution card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.r;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -19,7 +18,7 @@ public final class RollingThunder extends CardImpl {
|
|||
public RollingThunder(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{R}{R}");
|
||||
|
||||
// Rolling Thunder deals X damage divided as you choose among any number of target creatures and/or players.
|
||||
// Rolling Thunder deals X damage divided as you choose among any number of targets.
|
||||
DynamicValue xValue = ManacostVariableValue.REGULAR;
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(xValue));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(xValue));
|
||||
|
|
|
@ -26,6 +26,12 @@ import mage.target.common.TargetCreaturePermanent;
|
|||
*/
|
||||
public final class SamutTheTested extends CardImpl {
|
||||
|
||||
private static final FilterCard filter = new FilterCard("creature and/or planeswalker cards");
|
||||
|
||||
static {
|
||||
filter.add(Predicates.or(CardType.CREATURE.getPredicate(), CardType.PLANESWALKER.getPredicate()));
|
||||
}
|
||||
|
||||
public SamutTheTested(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.PLANESWALKER}, "{2}{R}{G}");
|
||||
this.addSuperType(SuperType.LEGENDARY);
|
||||
|
@ -39,19 +45,14 @@ public final class SamutTheTested extends CardImpl {
|
|||
ability.addTarget(new TargetCreaturePermanent(0, 1));
|
||||
this.addAbility(ability);
|
||||
|
||||
// -2: Samut, the Tested deals 2 damage divided as you choose among one or two target creatures and/or players.
|
||||
// -2: Samut, the Tested deals 2 damage divided as you choose among one or two targets.
|
||||
effect = new DamageMultiEffect(2);
|
||||
ability = new LoyaltyAbility(effect, -2);
|
||||
ability.addTarget(new TargetAnyTargetAmount(2));
|
||||
this.addAbility(ability);
|
||||
|
||||
// -7: Search your library or up to two creature and/or planeswalkercards, put them onto the battlefield, then shuffle your library.
|
||||
FilterCard filterCard = new FilterCard("creature or planeswalker card");
|
||||
filterCard.add(Predicates.or(
|
||||
CardType.CREATURE.getPredicate(),
|
||||
CardType.PLANESWALKER.getPredicate()
|
||||
));
|
||||
effect = new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(0, 2, filterCard), false, true);
|
||||
// -7: Search your library for up to two creature and/or planeswalker cards, put them onto the battlefield, then shuffle your library.
|
||||
effect = new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(0, 2, filter), false, true);
|
||||
ability = new LoyaltyAbility(effect, -7);
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.s;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -6,7 +5,6 @@ import mage.MageInt;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.TurnedFaceUpSourceTriggeredAbility;
|
||||
import mage.abilities.costs.common.SacrificeTargetCost;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.abilities.keyword.MorphAbility;
|
||||
import mage.cards.CardImpl;
|
||||
|
@ -23,10 +21,10 @@ import mage.target.common.TargetCreaturePermanentAmount;
|
|||
*/
|
||||
public final class SkirkVolcanist extends CardImpl {
|
||||
|
||||
private static final FilterControlledLandPermanent filterSacrifice = new FilterControlledLandPermanent("two Mountains");
|
||||
private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("Mountains");
|
||||
|
||||
static {
|
||||
filterSacrifice.add(SubType.MOUNTAIN.getPredicate());
|
||||
filter.add(SubType.MOUNTAIN.getPredicate());
|
||||
}
|
||||
|
||||
public SkirkVolcanist(UUID ownerId, CardSetInfo setInfo) {
|
||||
|
@ -36,12 +34,10 @@ public final class SkirkVolcanist extends CardImpl {
|
|||
this.toughness = new MageInt(1);
|
||||
|
||||
// Morph-Sacrifice two Mountains.
|
||||
this.addAbility(new MorphAbility(this, new SacrificeTargetCost(new TargetControlledPermanent(2,2, filterSacrifice, false))));
|
||||
this.addAbility(new MorphAbility(this, new SacrificeTargetCost(new TargetControlledPermanent(2, filter))));
|
||||
|
||||
// When Skirk Volcanist is turned face up, it deals 3 damage divided as you choose among one, two, or three target creatures.
|
||||
Effect effect = new DamageMultiEffect(3);
|
||||
effect.setText("it deals 3 damage divided as you choose among one, two, or three target creatures");
|
||||
Ability ability = new TurnedFaceUpSourceTriggeredAbility(effect);
|
||||
Ability ability = new TurnedFaceUpSourceTriggeredAbility(new DamageMultiEffect(3, "it"));
|
||||
ability.addTarget(new TargetCreaturePermanentAmount(3));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package mage.cards.t;
|
||||
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.DamageMultiEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
|
@ -17,10 +16,8 @@ public final class TwinBolt extends CardImpl {
|
|||
public TwinBolt(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{1}{R}");
|
||||
|
||||
// Twin Bolt deals 2 damage divided as you choose among one or two target creatures and/or players.
|
||||
Effect effect = new DamageMultiEffect(2);
|
||||
effect.setText("{this} deals 2 damage divided as you choose among one or two target creatures and/or players");
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
// Twin Bolt deals 2 damage divided as you choose among one or two targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(2));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(2));
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.v;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -19,8 +18,7 @@ public final class ViolentEruption extends CardImpl {
|
|||
public ViolentEruption(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{1}{R}{R}{R}");
|
||||
|
||||
|
||||
// Violent Eruption deals 4 damage divided as you choose among any number of target creatures and/or players.
|
||||
// Violent Eruption deals 4 damage divided as you choose among any number of targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(4));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(4));
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.v;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -16,14 +15,10 @@ import mage.target.common.TargetCreaturePermanentAmount;
|
|||
* @author tcontis
|
||||
*/
|
||||
public final class VolcanicWind extends CardImpl {
|
||||
|
||||
static final private FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures");
|
||||
|
||||
static {
|
||||
filter.add(CardType.CREATURE.getPredicate());
|
||||
}
|
||||
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures");
|
||||
|
||||
static final private String rule = "{this} deals X damage divided as you choose among any number of target creatures, where X is the number of creatures on the battlefield as you cast {this}";
|
||||
private static final String rule = "{this} deals X damage divided as you choose among any number of target creatures, where X is the number of creatures on the battlefield as you cast this spell";
|
||||
|
||||
public VolcanicWind(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{4}{R}{R}");
|
||||
|
@ -34,7 +29,6 @@ public final class VolcanicWind extends CardImpl {
|
|||
effect.setText(rule);
|
||||
this.getSpellAbility().addEffect(effect);
|
||||
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(creatures));
|
||||
|
||||
}
|
||||
|
||||
private VolcanicWind(final VolcanicWind card) {
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
package mage.cards.v;
|
||||
|
||||
import java.util.UUID;
|
||||
|
@ -20,8 +19,7 @@ public final class VolleyOfBoulders extends CardImpl {
|
|||
public VolleyOfBoulders(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{8}{R}");
|
||||
|
||||
|
||||
// Volley of Boulders deals 6 damage divided as you choose among any number of target creatures and/or players.
|
||||
// Volley of Boulders deals 6 damage divided as you choose among any number of targets.
|
||||
this.getSpellAbility().addEffect(new DamageMultiEffect(6));
|
||||
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(6));
|
||||
// Flashback {R}{R}{R}{R}{R}{R}
|
||||
|
|
|
@ -12,9 +12,7 @@ import mage.game.permanent.Permanent;
|
|||
import mage.players.Player;
|
||||
import mage.target.Target;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
import java.util.UUID;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @author BetaSteward_at_googlemail.com
|
||||
|
@ -79,10 +77,21 @@ 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";
|
||||
StringBuilder sb = new StringBuilder(sourceName);
|
||||
sb.append(" deals ");
|
||||
|
||||
String amountString = amount.toString();
|
||||
sb.append(amountString);
|
||||
sb.append(" damage divided as you choose among ");
|
||||
sb.append(amountString.equals("2") ? "one or two " : amountString.equals("3") ? "one, two, or three " : "any number of ");
|
||||
|
||||
String targetName = mode.getTargets().get(0).getTargetName();
|
||||
if (!targetName.contains("target")) {
|
||||
sb.append("target ");
|
||||
}
|
||||
return this.sourceName + " deals " + amount.toString() + " damage divided as you choose among any number of " + mode.getTargets().get(0).getTargetName();
|
||||
sb.append(targetName);
|
||||
|
||||
return sb.toString();
|
||||
}
|
||||
|
||||
public String getSourceName() {
|
||||
|
|
|
@ -756,6 +756,12 @@ public final class StaticFilters {
|
|||
FILTER_ATTACKING_CREATURES.setLockedFilter(true);
|
||||
}
|
||||
|
||||
public static final FilterAttackingOrBlockingCreature FILTER_ATTACKING_OR_BLOCKING_CREATURES = new FilterAttackingOrBlockingCreature("attacking or blocking creatures");
|
||||
|
||||
static {
|
||||
FILTER_ATTACKING_OR_BLOCKING_CREATURES.setLockedFilter(true);
|
||||
}
|
||||
|
||||
public static final FilterPermanent FILTER_PERMANENT_AURA = new FilterPermanent();
|
||||
|
||||
static {
|
||||
|
|
Loading…
Reference in a new issue