diff --git a/Mage.Sets/src/mage/cards/a/AbandonHope.java b/Mage.Sets/src/mage/cards/a/AbandonHope.java
index 3c3e6e538c..ca314d3902 100644
--- a/Mage.Sets/src/mage/cards/a/AbandonHope.java
+++ b/Mage.Sets/src/mage/cards/a/AbandonHope.java
@@ -36,7 +36,7 @@ public final class AbandonHope extends CardImpl {
// Look at target opponent's hand and choose X cards from it. That player discards those cards.
this.getSpellAbility().addEffect(
- new DiscardCardYouChooseTargetEffect(ManacostVariableValue.instance, TargetController.ANY)
+ new DiscardCardYouChooseTargetEffect(ManacostVariableValue.REGULAR, TargetController.ANY)
.setText("Look at target opponent's hand and choose X cards from it. That player discards those cards"));
this.getSpellAbility().addTarget(new TargetOpponent());
this.getSpellAbility().setCostAdjuster(AbandonHopeAdjuster.instance);
diff --git a/Mage.Sets/src/mage/cards/a/AlabasterPotion.java b/Mage.Sets/src/mage/cards/a/AlabasterPotion.java
index 8f934ae453..4877d3aceb 100644
--- a/Mage.Sets/src/mage/cards/a/AlabasterPotion.java
+++ b/Mage.Sets/src/mage/cards/a/AlabasterPotion.java
@@ -23,10 +23,10 @@ public final class AlabasterPotion extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{W}{W}");
// Choose one - Target player gains X life; or prevent the next X damage that would be dealt to any target this turn.
- this.getSpellAbility().addEffect(new GainLifeTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new GainLifeTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetPlayer());
Mode mode = new Mode();
- mode.addEffect(new PreventDamageToTargetEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.instance));
+ mode.addEffect(new PreventDamageToTargetEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.REGULAR));
mode.addTarget(new TargetAnyTarget());
this.getSpellAbility().addMode(mode);
}
diff --git a/Mage.Sets/src/mage/cards/a/ArashiTheSkyAsunder.java b/Mage.Sets/src/mage/cards/a/ArashiTheSkyAsunder.java
index 493cecdf6a..f7e122917b 100644
--- a/Mage.Sets/src/mage/cards/a/ArashiTheSkyAsunder.java
+++ b/Mage.Sets/src/mage/cards/a/ArashiTheSkyAsunder.java
@@ -43,13 +43,13 @@ public final class ArashiTheSkyAsunder extends CardImpl {
this.toughness = new MageInt(5);
// {X}{G}, {tap}: Arashi, the Sky Asunder deals X damage to target creature with flying.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{G}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{G}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetPermanent(filter));
this.addAbility(ability);
// Channel - {X}{G}{G}, Discard Arashi: Arashi deals X damage to each creature with flying.
- this.addAbility(new ChannelAbility("{X}{G}{G}", new DamageAllEffect(ManacostVariableValue.instance, filter)));
+ this.addAbility(new ChannelAbility("{X}{G}{G}", new DamageAllEffect(ManacostVariableValue.REGULAR, filter)));
}
private ArashiTheSkyAsunder(final ArashiTheSkyAsunder card) {
diff --git a/Mage.Sets/src/mage/cards/a/AtalyaSamiteMaster.java b/Mage.Sets/src/mage/cards/a/AtalyaSamiteMaster.java
index 849b84024a..a86d36f13c 100644
--- a/Mage.Sets/src/mage/cards/a/AtalyaSamiteMaster.java
+++ b/Mage.Sets/src/mage/cards/a/AtalyaSamiteMaster.java
@@ -41,7 +41,7 @@ public final class AtalyaSamiteMaster extends CardImpl {
this.toughness = new MageInt(3);
// {X}, {tap}: Choose one - Prevent the next X damage that would be dealt to target creature this turn; or you gain X life. Spend only white mana on X.
- PreventDamageToTargetEffect effect = new PreventDamageToTargetEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.instance);
+ PreventDamageToTargetEffect effect = new PreventDamageToTargetEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.REGULAR);
effect.setText("Prevent the next X damage that would be dealt to target creature this turn. Spend only white mana on X.");
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{X}"));
ability.addCost(new TapSourceCost());
@@ -55,7 +55,7 @@ public final class AtalyaSamiteMaster extends CardImpl {
// or you gain X life
Mode mode = new Mode();
- mode.addEffect(new GainLifeEffect(ManacostVariableValue.instance).setText("You gain X life. Spend only white mana on X."));
+ mode.addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR).setText("You gain X life. Spend only white mana on X."));
ability.addMode(mode);
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/a/AureliasFury.java b/Mage.Sets/src/mage/cards/a/AureliasFury.java
index c487c51c03..7b37b87ed4 100644
--- a/Mage.Sets/src/mage/cards/a/AureliasFury.java
+++ b/Mage.Sets/src/mage/cards/a/AureliasFury.java
@@ -61,7 +61,7 @@ public final class AureliasFury extends CardImpl {
// Aurelia's Fury deals X damage divided as you choose among any number of target creatures and/or players.
// Tap each creature dealt damage this way. Players dealt damage this way can't cast noncreature spells this turn.
- DynamicValue xValue = ManacostVariableValue.instance;
+ DynamicValue xValue = ManacostVariableValue.REGULAR;
this.getSpellAbility().addEffect(new DamageMultiEffect(xValue));
this.getSpellAbility().addEffect(new AureliasFuryEffect());
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(xValue));
diff --git a/Mage.Sets/src/mage/cards/b/BalduvianRage.java b/Mage.Sets/src/mage/cards/b/BalduvianRage.java
index 4501f8d174..21a307d0ac 100644
--- a/Mage.Sets/src/mage/cards/b/BalduvianRage.java
+++ b/Mage.Sets/src/mage/cards/b/BalduvianRage.java
@@ -25,7 +25,7 @@ public final class BalduvianRage extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{R}");
// Target attacking creature gets +X/+0 until end of turn.
- this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.instance, StaticValue.get(0), Duration.EndOfTurn));
+ this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.REGULAR, StaticValue.get(0), Duration.EndOfTurn));
this.getSpellAbility().addTarget(new TargetCreaturePermanent(new FilterAttackingCreature()));
// Draw a card at the beginning of the next turn's upkeep.
diff --git a/Mage.Sets/src/mage/cards/b/BallistaSquad.java b/Mage.Sets/src/mage/cards/b/BallistaSquad.java
index 0f1c794eca..fe6bf6085e 100644
--- a/Mage.Sets/src/mage/cards/b/BallistaSquad.java
+++ b/Mage.Sets/src/mage/cards/b/BallistaSquad.java
@@ -30,7 +30,7 @@ public final class BallistaSquad extends CardImpl {
this.toughness = new MageInt(2);
// {X}{W}, {T}: Ballista Squad deals X damage to target attacking or blocking creature.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{W}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{W}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetAttackingOrBlockingCreature());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/b/Banefire.java b/Mage.Sets/src/mage/cards/b/Banefire.java
index 331be2a053..ccf67d35f2 100644
--- a/Mage.Sets/src/mage/cards/b/Banefire.java
+++ b/Mage.Sets/src/mage/cards/b/Banefire.java
@@ -17,7 +17,6 @@ import mage.constants.Outcome;
import mage.constants.Zone;
import mage.game.Game;
import mage.game.events.GameEvent;
-import mage.game.events.GameEvent.EventType;
import mage.game.permanent.Permanent;
import mage.game.stack.Spell;
import mage.players.Player;
@@ -106,7 +105,7 @@ class BaneFireEffect extends OneShotEffect {
class BanefireCantCounterEffect extends ContinuousRuleModifyingEffectImpl {
- Condition condition = new testCondition(ManacostVariableValue.instance, 5);
+ Condition condition = new testCondition(ManacostVariableValue.REGULAR, 5);
public BanefireCantCounterEffect() {
super(Duration.WhileOnStack, Outcome.Benefit);
diff --git a/Mage.Sets/src/mage/cards/b/Banshee.java b/Mage.Sets/src/mage/cards/b/Banshee.java
index 2661b5c4e1..e272dff634 100644
--- a/Mage.Sets/src/mage/cards/b/Banshee.java
+++ b/Mage.Sets/src/mage/cards/b/Banshee.java
@@ -31,9 +31,9 @@ public final class Banshee extends CardImpl {
this.toughness = new MageInt(1);
// {X}, {T}: Banshee deals half X damage, rounded down, to any target, and half X damage, rounded up, to you.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(new HalfValue(ManacostVariableValue.instance, false)).setText("Banshee deals half X damage, rounded down, to any target,"), new ManaCostsImpl("{X}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(new HalfValue(ManacostVariableValue.REGULAR, false)).setText("Banshee deals half X damage, rounded down, to any target,"), new ManaCostsImpl("{X}"));
ability.addCost(new TapSourceCost());
- ability.addEffect(new DamageControllerEffect(new HalfValue(ManacostVariableValue.instance, true)).setText(" and half X damage, rounded up, to you"));
+ ability.addEffect(new DamageControllerEffect(new HalfValue(ManacostVariableValue.REGULAR, true)).setText(" and half X damage, rounded up, to you"));
ability.addTarget(new TargetAnyTarget());
this.addAbility(ability);
}
diff --git a/Mage.Sets/src/mage/cards/b/BattleAtTheBridge.java b/Mage.Sets/src/mage/cards/b/BattleAtTheBridge.java
index d2f092c368..79f54b2350 100644
--- a/Mage.Sets/src/mage/cards/b/BattleAtTheBridge.java
+++ b/Mage.Sets/src/mage/cards/b/BattleAtTheBridge.java
@@ -27,10 +27,10 @@ public final class BattleAtTheBridge extends CardImpl {
addAbility(new ImproviseAbility());
// Target creature gets -X/-X until end of turn. You gain X life.
- DynamicValue x = new SignInversionDynamicValue(ManacostVariableValue.instance);
+ DynamicValue x = new SignInversionDynamicValue(ManacostVariableValue.REGULAR);
this.getSpellAbility().addEffect(new BoostTargetEffect(x, x, Duration.EndOfTurn, true));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
- this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR));
}
private BattleAtTheBridge(final BattleAtTheBridge card) {
diff --git a/Mage.Sets/src/mage/cards/b/BelbesArmor.java b/Mage.Sets/src/mage/cards/b/BelbesArmor.java
index f3b1409964..d47b2459d1 100644
--- a/Mage.Sets/src/mage/cards/b/BelbesArmor.java
+++ b/Mage.Sets/src/mage/cards/b/BelbesArmor.java
@@ -25,8 +25,8 @@ public final class BelbesArmor extends CardImpl {
// {X}, {tap}: Target creature gets -X/+X until end of turn.
Ability ability = new SimpleActivatedAbility(new BoostTargetEffect(
- new MultipliedValue(ManacostVariableValue.instance, -1),
- ManacostVariableValue.instance, Duration.EndOfTurn
+ new MultipliedValue(ManacostVariableValue.REGULAR, -1),
+ ManacostVariableValue.REGULAR, Duration.EndOfTurn
).setText("Target creature gets -X/+X until end of turn"), new ManaCostsImpl("{X}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
diff --git a/Mage.Sets/src/mage/cards/b/BergStrider.java b/Mage.Sets/src/mage/cards/b/BergStrider.java
index 80dbf49013..8643843243 100644
--- a/Mage.Sets/src/mage/cards/b/BergStrider.java
+++ b/Mage.Sets/src/mage/cards/b/BergStrider.java
@@ -79,13 +79,11 @@ class BergStriderEffect extends OneShotEffect {
@Override
public boolean apply(Game game, Ability source) {
- ManaSpentToCastWatcher watcher = game.getState().getWatcher(
- ManaSpentToCastWatcher.class, source.getSourceId()
- );
+ ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class);
if (watcher == null) {
return false;
}
- Mana payment = watcher.getAndResetLastPayment();
+ Mana payment = watcher.getAndResetLastPayment(source.getSourceId());
if (payment == null || payment.getSnow() < 1) {
return false;
}
diff --git a/Mage.Sets/src/mage/cards/b/BiomassMutation.java b/Mage.Sets/src/mage/cards/b/BiomassMutation.java
index d01c1ddba8..9bccb523c1 100644
--- a/Mage.Sets/src/mage/cards/b/BiomassMutation.java
+++ b/Mage.Sets/src/mage/cards/b/BiomassMutation.java
@@ -22,7 +22,7 @@ public final class BiomassMutation extends CardImpl {
// Creatures you control have base power and toughness X/X until end of turn.
- DynamicValue variableMana = ManacostVariableValue.instance;
+ DynamicValue variableMana = ManacostVariableValue.REGULAR;
this.getSpellAbility().addEffect(new SetPowerToughnessAllEffect(variableMana, variableMana, Duration.EndOfTurn, new FilterControlledCreaturePermanent("Creatures you control"), true));
}
diff --git a/Mage.Sets/src/mage/cards/b/BlastZone.java b/Mage.Sets/src/mage/cards/b/BlastZone.java
index 94a9728508..60c5c3a5a5 100644
--- a/Mage.Sets/src/mage/cards/b/BlastZone.java
+++ b/Mage.Sets/src/mage/cards/b/BlastZone.java
@@ -46,7 +46,7 @@ public final class BlastZone extends CardImpl {
// {X}{X}, {T}: Put X charge counters on Blast Zone.
Ability ability = new SimpleActivatedAbility(new AddCountersSourceEffect(
- CounterType.CHARGE.createInstance(), ManacostVariableValue.instance, true
+ CounterType.CHARGE.createInstance(), ManacostVariableValue.REGULAR, true
), new ManaCostsImpl("{X}{X}"));
ability.addCost(new TapSourceCost());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/b/Blaze.java b/Mage.Sets/src/mage/cards/b/Blaze.java
index 85ba35664c..8a12e8c9ce 100644
--- a/Mage.Sets/src/mage/cards/b/Blaze.java
+++ b/Mage.Sets/src/mage/cards/b/Blaze.java
@@ -20,7 +20,7 @@ public final class Blaze extends CardImpl {
// Blaze deals X damage to any target.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
}
diff --git a/Mage.Sets/src/mage/cards/b/BlotOutTheSky.java b/Mage.Sets/src/mage/cards/b/BlotOutTheSky.java
index c303992fdc..b68272384a 100644
--- a/Mage.Sets/src/mage/cards/b/BlotOutTheSky.java
+++ b/Mage.Sets/src/mage/cards/b/BlotOutTheSky.java
@@ -33,7 +33,7 @@ public final class BlotOutTheSky extends CardImpl {
// Create X tapped 2/1 white and black Inkling creature tokens with flying. If X is 6 or more, destroy all noncreature, nonland permanents.
this.getSpellAbility().addEffect(new CreateTokenEffect(
- new SilverquillToken(), ManacostVariableValue.instance, true, false
+ new SilverquillToken(), ManacostVariableValue.REGULAR, true, false
));
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
new DestroyAllEffect(filter), BlotOutTheSkyCondition.instance,
diff --git a/Mage.Sets/src/mage/cards/b/BlueSunsZenith.java b/Mage.Sets/src/mage/cards/b/BlueSunsZenith.java
index 2e94941db5..ea134dd700 100644
--- a/Mage.Sets/src/mage/cards/b/BlueSunsZenith.java
+++ b/Mage.Sets/src/mage/cards/b/BlueSunsZenith.java
@@ -21,7 +21,7 @@ public final class BlueSunsZenith extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{U}{U}{U}");
// Target player draws X cards. Shuffle Blue Sun's Zenith into its owner's library.
- this.getSpellAbility().addEffect(new DrawCardTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addEffect(ShuffleSpellEffect.getInstance());
this.getSpellAbility().addTarget(new TargetPlayer());
}
diff --git a/Mage.Sets/src/mage/cards/b/BondOfAgony.java b/Mage.Sets/src/mage/cards/b/BondOfAgony.java
index 7e2e700a55..ff95d54d15 100644
--- a/Mage.Sets/src/mage/cards/b/BondOfAgony.java
+++ b/Mage.Sets/src/mage/cards/b/BondOfAgony.java
@@ -18,7 +18,7 @@ public final class BondOfAgony extends CardImpl {
public BondOfAgony(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{B}");
- DynamicValue xValue = ManacostVariableValue.instance;
+ DynamicValue xValue = ManacostVariableValue.REGULAR;
// As an additional cost to cast Bond of Agony, pay X life.
// magenoxx: here we don't use PayVariableLifeCost as {X} shouldn't actually be announced
diff --git a/Mage.Sets/src/mage/cards/b/BorrowingTheEastWind.java b/Mage.Sets/src/mage/cards/b/BorrowingTheEastWind.java
index f3793a3d58..e94140c533 100644
--- a/Mage.Sets/src/mage/cards/b/BorrowingTheEastWind.java
+++ b/Mage.Sets/src/mage/cards/b/BorrowingTheEastWind.java
@@ -27,7 +27,7 @@ public final class BorrowingTheEastWind extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{G}{G}");
// Borrowing the East Wind deals X damage to each creature with horsemanship and each player.
- this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.instance, filter)); }
+ this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.REGULAR, filter)); }
private BorrowingTheEastWind(final BorrowingTheEastWind card) {
super(card);
diff --git a/Mage.Sets/src/mage/cards/b/Braingeyser.java b/Mage.Sets/src/mage/cards/b/Braingeyser.java
index 7c9041ca4d..0aa9a0dc16 100644
--- a/Mage.Sets/src/mage/cards/b/Braingeyser.java
+++ b/Mage.Sets/src/mage/cards/b/Braingeyser.java
@@ -21,7 +21,7 @@ public final class Braingeyser extends CardImpl {
// Target player draws X cards.
- this.getSpellAbility().addEffect(new DrawCardTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetPlayer());
}
diff --git a/Mage.Sets/src/mage/cards/b/Brightflame.java b/Mage.Sets/src/mage/cards/b/Brightflame.java
index 606e805e42..cdb83cbc2f 100644
--- a/Mage.Sets/src/mage/cards/b/Brightflame.java
+++ b/Mage.Sets/src/mage/cards/b/Brightflame.java
@@ -27,7 +27,7 @@ public final class Brightflame extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{R}{R}{W}{W}");
// Radiance - Brightflame deals X damage to target creature and each other creature that shares a color with it. You gain life equal to the damage dealt this way.
- this.getSpellAbility().addEffect(new BrightflameEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new BrightflameEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
this.getSpellAbility().setAbilityWord(AbilityWord.RADIANCE);
}
diff --git a/Mage.Sets/src/mage/cards/b/BrokenAmbitions.java b/Mage.Sets/src/mage/cards/b/BrokenAmbitions.java
index d1899824a3..ad7c0ef751 100644
--- a/Mage.Sets/src/mage/cards/b/BrokenAmbitions.java
+++ b/Mage.Sets/src/mage/cards/b/BrokenAmbitions.java
@@ -25,7 +25,7 @@ public final class BrokenAmbitions extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{U}");
// Counter target spell unless its controller pays {X}. Clash with an opponent. If you win, that spell's controller puts the top four cards of their library into their graveyard.
- this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addEffect(new BrokenAmbitionsEffect());
this.getSpellAbility().addTarget(new TargetSpell());
}
diff --git a/Mage.Sets/src/mage/cards/c/CabalInterrogator.java b/Mage.Sets/src/mage/cards/c/CabalInterrogator.java
index 58494a5050..8fff1f7921 100644
--- a/Mage.Sets/src/mage/cards/c/CabalInterrogator.java
+++ b/Mage.Sets/src/mage/cards/c/CabalInterrogator.java
@@ -78,7 +78,7 @@ class CabalInterrogatorEffect extends OneShotEffect {
return false;
}
- int amountToReveal = (ManacostVariableValue.instance).calculate(game, source, this);
+ int amountToReveal = (ManacostVariableValue.REGULAR).calculate(game, source, this);
Cards revealedCards = new CardsImpl();
if (amountToReveal > 0 && targetPlayer.getHand().size() > amountToReveal) {
diff --git a/Mage.Sets/src/mage/cards/c/CacklingWitch.java b/Mage.Sets/src/mage/cards/c/CacklingWitch.java
index 70ae8f0b93..f3e8de91f4 100644
--- a/Mage.Sets/src/mage/cards/c/CacklingWitch.java
+++ b/Mage.Sets/src/mage/cards/c/CacklingWitch.java
@@ -33,7 +33,7 @@ public final class CacklingWitch extends CardImpl {
this.toughness = new MageInt(1);
// {X}{B}, {tap}, Discard a card: Target creature gets +X/+0 until end of turn.
- ManacostVariableValue manaX = ManacostVariableValue.instance;
+ ManacostVariableValue manaX = ManacostVariableValue.REGULAR;
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
new BoostTargetEffect(manaX, StaticValue.get(0), Duration.EndOfTurn),
new ManaCostsImpl("{X}{B}"));
diff --git a/Mage.Sets/src/mage/cards/c/ChamberSentry.java b/Mage.Sets/src/mage/cards/c/ChamberSentry.java
index 68b810e85e..da52d4c0c8 100644
--- a/Mage.Sets/src/mage/cards/c/ChamberSentry.java
+++ b/Mage.Sets/src/mage/cards/c/ChamberSentry.java
@@ -44,7 +44,7 @@ public final class ChamberSentry extends CardImpl {
"with a +1/+1 counter on it for each color of mana spent to cast it"));
// {X}, {T}, Remove X +1/+1 counters from Chamber Sentry: It deals X damage to any target.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance)
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR)
.setText("It deals X damage to any target"),
new ManaCostsImpl("{X}"));
ability.addCost(new TapSourceCost());
diff --git a/Mage.Sets/src/mage/cards/c/CinderElemental.java b/Mage.Sets/src/mage/cards/c/CinderElemental.java
index e2ffbec054..3df2891dd6 100644
--- a/Mage.Sets/src/mage/cards/c/CinderElemental.java
+++ b/Mage.Sets/src/mage/cards/c/CinderElemental.java
@@ -31,7 +31,7 @@ public final class CinderElemental extends CardImpl {
this.toughness = new MageInt(2);
// {X}{R}, {tap}, Sacrifice Cinder Elemental: Cinder Elemental deals X damage to any target.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{R}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{R}"));
ability.addCost(new TapSourceCost());
ability.addCost(new SacrificeSourceCost());
ability.addTarget(new TargetAnyTarget());
diff --git a/Mage.Sets/src/mage/cards/c/ClanDefiance.java b/Mage.Sets/src/mage/cards/c/ClanDefiance.java
index 266a48f324..4ae9cb1daa 100644
--- a/Mage.Sets/src/mage/cards/c/ClanDefiance.java
+++ b/Mage.Sets/src/mage/cards/c/ClanDefiance.java
@@ -35,16 +35,16 @@ public final class ClanDefiance extends CardImpl {
this.getSpellAbility().getModes().setMinModes(1);
this.getSpellAbility().getModes().setMaxModes(3);
// Clan Defiance deals X damage to target creature with flying;
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetCreaturePermanent(filterFlying).withChooseHint("deals X damage, with flying"));
// Clan Defiance deals X damage to target creature without flying;
Mode mode1 = new Mode();
- mode1.addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ mode1.addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
mode1.addTarget(new TargetCreaturePermanent(filterWithoutFlying).withChooseHint("deals X damage, without flying"));
this.getSpellAbility().addMode(mode1);
// and/or Clan Defiance deals X damage to target player.
Mode mode2 = new Mode();
- mode2.addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ mode2.addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
mode2.addTarget(new TargetPlayerOrPlaneswalker().withChooseHint("deals X damage"));
this.getSpellAbility().addMode(mode2);
diff --git a/Mage.Sets/src/mage/cards/c/ClashOfWills.java b/Mage.Sets/src/mage/cards/c/ClashOfWills.java
index f2a32edfb8..e57ebdbabc 100644
--- a/Mage.Sets/src/mage/cards/c/ClashOfWills.java
+++ b/Mage.Sets/src/mage/cards/c/ClashOfWills.java
@@ -19,7 +19,7 @@ public final class ClashOfWills extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{U}");
// Counter target spell unless its controller pays {X}.
- this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetSpell());
}
diff --git a/Mage.Sets/src/mage/cards/c/ClockworkAvian.java b/Mage.Sets/src/mage/cards/c/ClockworkAvian.java
index 4d8d737e9d..ca67107e04 100644
--- a/Mage.Sets/src/mage/cards/c/ClockworkAvian.java
+++ b/Mage.Sets/src/mage/cards/c/ClockworkAvian.java
@@ -63,7 +63,7 @@ public final class ClockworkAvian extends CardImpl {
Zone.BATTLEFIELD,
new AvianAddCountersSourceEffect(
CounterType.P1P0.createInstance(),
- ManacostVariableValue.instance,
+ ManacostVariableValue.REGULAR,
true, true
),
new ManaCostsImpl("{X}"),
diff --git a/Mage.Sets/src/mage/cards/c/ClockworkBeast.java b/Mage.Sets/src/mage/cards/c/ClockworkBeast.java
index 88ac3efd56..48e257ada3 100644
--- a/Mage.Sets/src/mage/cards/c/ClockworkBeast.java
+++ b/Mage.Sets/src/mage/cards/c/ClockworkBeast.java
@@ -59,7 +59,7 @@ public final class ClockworkBeast extends CardImpl {
Zone.BATTLEFIELD,
new BeastAddCountersSourceEffect(
CounterType.P1P0.createInstance(),
- ManacostVariableValue.instance,
+ ManacostVariableValue.REGULAR,
true, true
),
new ManaCostsImpl("{X}"),
diff --git a/Mage.Sets/src/mage/cards/c/ClockworkSteed.java b/Mage.Sets/src/mage/cards/c/ClockworkSteed.java
index 11d09e1f3a..dac9760b5e 100644
--- a/Mage.Sets/src/mage/cards/c/ClockworkSteed.java
+++ b/Mage.Sets/src/mage/cards/c/ClockworkSteed.java
@@ -69,7 +69,7 @@ public final class ClockworkSteed extends CardImpl {
Zone.BATTLEFIELD,
new ClockworkSteedAddCountersSourceEffect(
CounterType.P1P0.createInstance(),
- ManacostVariableValue.instance,
+ ManacostVariableValue.REGULAR,
true, true
),
new ManaCostsImpl("{X}"),
diff --git a/Mage.Sets/src/mage/cards/c/ClockworkSwarm.java b/Mage.Sets/src/mage/cards/c/ClockworkSwarm.java
index 63ab60021b..02e88b6d08 100644
--- a/Mage.Sets/src/mage/cards/c/ClockworkSwarm.java
+++ b/Mage.Sets/src/mage/cards/c/ClockworkSwarm.java
@@ -72,7 +72,7 @@ public final class ClockworkSwarm extends CardImpl {
Zone.BATTLEFIELD,
new SwarmAddCountersSourceEffect(
CounterType.P1P0.createInstance(),
- ManacostVariableValue.instance,
+ ManacostVariableValue.REGULAR,
true, true
),
new ManaCostsImpl("{X}"),
diff --git a/Mage.Sets/src/mage/cards/c/Condescend.java b/Mage.Sets/src/mage/cards/c/Condescend.java
index 9f376b1631..8c3b33fcf6 100644
--- a/Mage.Sets/src/mage/cards/c/Condescend.java
+++ b/Mage.Sets/src/mage/cards/c/Condescend.java
@@ -21,7 +21,7 @@ public final class Condescend extends CardImpl {
// Counter target spell unless its controller pays {X}.
- this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetSpell());
// Scry 2.
this.getSpellAbility().addEffect(new ScryEffect(2));
diff --git a/Mage.Sets/src/mage/cards/c/ConsumeSpirit.java b/Mage.Sets/src/mage/cards/c/ConsumeSpirit.java
index 21a451a872..aff7a131bf 100644
--- a/Mage.Sets/src/mage/cards/c/ConsumeSpirit.java
+++ b/Mage.Sets/src/mage/cards/c/ConsumeSpirit.java
@@ -38,8 +38,8 @@ public final class ConsumeSpirit extends CardImpl {
// Consume Spirit deals X damage to any target and you gain X life.
this.getSpellAbility().addTarget(new TargetAnyTarget());
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
- this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.instance).concatBy("and"));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
+ this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR).concatBy("and"));
VariableCost variableCost = this.getSpellAbility().getManaCostsToPay().getVariableCosts().get(0);
if (variableCost instanceof VariableManaCost) {
((VariableManaCost) variableCost).setFilter(filterBlack);
diff --git a/Mage.Sets/src/mage/cards/c/CorrosiveGale.java b/Mage.Sets/src/mage/cards/c/CorrosiveGale.java
index 375a07e70d..54032508cb 100644
--- a/Mage.Sets/src/mage/cards/c/CorrosiveGale.java
+++ b/Mage.Sets/src/mage/cards/c/CorrosiveGale.java
@@ -27,7 +27,7 @@ public final class CorrosiveGale extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{G/P}");
- this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, filter));
+ this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, filter));
}
private CorrosiveGale(final CorrosiveGale card) {
diff --git a/Mage.Sets/src/mage/cards/c/CrackleWithPower.java b/Mage.Sets/src/mage/cards/c/CrackleWithPower.java
index 74dfe1ea98..af8dbc04e4 100644
--- a/Mage.Sets/src/mage/cards/c/CrackleWithPower.java
+++ b/Mage.Sets/src/mage/cards/c/CrackleWithPower.java
@@ -19,7 +19,7 @@ import java.util.UUID;
*/
public final class CrackleWithPower extends CardImpl {
- private static final DynamicValue value = new MultipliedValue(ManacostVariableValue.instance, 5);
+ private static final DynamicValue value = new MultipliedValue(ManacostVariableValue.REGULAR, 5);
public CrackleWithPower(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{X}{R}{R}");
diff --git a/Mage.Sets/src/mage/cards/c/CratersClaws.java b/Mage.Sets/src/mage/cards/c/CratersClaws.java
index 24ff99fe37..b75d9af796 100644
--- a/Mage.Sets/src/mage/cards/c/CratersClaws.java
+++ b/Mage.Sets/src/mage/cards/c/CratersClaws.java
@@ -24,8 +24,8 @@ public final class CratersClaws extends CardImpl {
// Crater's Claws deals X damage to any target.
// Ferocious — Crater's Claws deals X plus 2 damage to that creature or player instead if you control a creature with power 4 or greater.
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
- new DamageTargetEffect(new IntPlusDynamicValue(2, ManacostVariableValue.instance)),
- new DamageTargetEffect(ManacostVariableValue.instance),
+ new DamageTargetEffect(new IntPlusDynamicValue(2, ManacostVariableValue.REGULAR)),
+ new DamageTargetEffect(ManacostVariableValue.REGULAR),
FerociousCondition.instance,
"{this} deals X damage to any target."
+ "
Ferocious — {this} deals X plus 2 damage instead if you control a creature with power 4 or greater"));
diff --git a/Mage.Sets/src/mage/cards/c/CrimsonHellkite.java b/Mage.Sets/src/mage/cards/c/CrimsonHellkite.java
index ee77c28750..a75cb25909 100644
--- a/Mage.Sets/src/mage/cards/c/CrimsonHellkite.java
+++ b/Mage.Sets/src/mage/cards/c/CrimsonHellkite.java
@@ -43,7 +43,7 @@ public final class CrimsonHellkite extends CardImpl {
// Flying
this.addAbility(FlyingAbility.getInstance());
// {X}, {tap}: Crimson Hellkite deals X damage to target creature. Spend only red mana on X.
- Effect effect = new DamageTargetEffect(ManacostVariableValue.instance);
+ Effect effect = new DamageTargetEffect(ManacostVariableValue.REGULAR);
effect.setText("{this} deals X damage to target creature. Spend only red mana on X");
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{X}"));
ability.addCost(new TapSourceCost());
diff --git a/Mage.Sets/src/mage/cards/c/CryptRats.java b/Mage.Sets/src/mage/cards/c/CryptRats.java
index b9abbaf816..26ebcdba4f 100644
--- a/Mage.Sets/src/mage/cards/c/CryptRats.java
+++ b/Mage.Sets/src/mage/cards/c/CryptRats.java
@@ -38,7 +38,7 @@ public final class CryptRats extends CardImpl {
this.toughness = new MageInt(1);
// {X}: Crypt Rats deals X damage to each creature and each player. Spend only black mana on X.
- Effect effect = new DamageEverythingEffect(ManacostVariableValue.instance);
+ Effect effect = new DamageEverythingEffect(ManacostVariableValue.REGULAR);
effect.setText("{this} deals X damage to each creature and each player. Spend only black mana on X");
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect,new ManaCostsImpl("{X}"));
VariableCost variableCost = ability.getManaCostsToPay().getVariableCosts().get(0);
diff --git a/Mage.Sets/src/mage/cards/c/CutRibbons.java b/Mage.Sets/src/mage/cards/c/CutRibbons.java
index 6620a43fe1..f008463772 100644
--- a/Mage.Sets/src/mage/cards/c/CutRibbons.java
+++ b/Mage.Sets/src/mage/cards/c/CutRibbons.java
@@ -28,7 +28,7 @@ public final class CutRibbons extends SplitCard {
// Ribbons
// Each opponent loses X life.
getRightHalfCard().addAbility(new AftermathAbility().setRuleAtTheTop(true));
- getRightHalfCard().getSpellAbility().addEffect(new LoseLifeOpponentsEffect(ManacostVariableValue.instance));
+ getRightHalfCard().getSpellAbility().addEffect(new LoseLifeOpponentsEffect(ManacostVariableValue.REGULAR));
}
diff --git a/Mage.Sets/src/mage/cards/d/DarkSalvation.java b/Mage.Sets/src/mage/cards/d/DarkSalvation.java
index 3acd719203..972ead00a6 100644
--- a/Mage.Sets/src/mage/cards/d/DarkSalvation.java
+++ b/Mage.Sets/src/mage/cards/d/DarkSalvation.java
@@ -33,7 +33,7 @@ public final class DarkSalvation extends CardImpl {
// Target player creates X 2/2 black Zombie creature tokens, then up to one target creature gets -1/-1 until end of turn for each Zombie that player controls.
this.getSpellAbility().addTarget(new TargetPlayer());
- Effect effect = new CreateTokenTargetEffect(new ZombieToken(), ManacostVariableValue.instance);
+ Effect effect = new CreateTokenTargetEffect(new ZombieToken(), ManacostVariableValue.REGULAR);
effect.setText("Target player creates X 2/2 black Zombie creature tokens");
this.getSpellAbility().addEffect(effect);
DynamicValue value = new ZombiesControlledByTargetPlayerCount();
diff --git a/Mage.Sets/src/mage/cards/d/DawnglowInfusion.java b/Mage.Sets/src/mage/cards/d/DawnglowInfusion.java
index c48878fea3..bea66dae04 100644
--- a/Mage.Sets/src/mage/cards/d/DawnglowInfusion.java
+++ b/Mage.Sets/src/mage/cards/d/DawnglowInfusion.java
@@ -24,7 +24,7 @@ public final class DawnglowInfusion extends CardImpl {
// You gain X life if {G} was spent to cast Dawnglow Infusion and X life if {W} was spent to cast it.
- DynamicValue xValue = ManacostVariableValue.instance;
+ DynamicValue xValue = ManacostVariableValue.REGULAR;
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
new GainLifeEffect(xValue),
new ManaWasSpentCondition(ColoredManaSymbol.G), "You gain X life if {G} was spent to cast this spell"));
diff --git a/Mage.Sets/src/mage/cards/d/DeathCloud.java b/Mage.Sets/src/mage/cards/d/DeathCloud.java
index 606e8b9906..91c4b1a983 100644
--- a/Mage.Sets/src/mage/cards/d/DeathCloud.java
+++ b/Mage.Sets/src/mage/cards/d/DeathCloud.java
@@ -25,7 +25,7 @@ public final class DeathCloud extends CardImpl {
// Each player loses X life, discards X cards, sacrifices X creatures, then sacrifices X lands.
- DynamicValue xValue = ManacostVariableValue.instance;
+ DynamicValue xValue = ManacostVariableValue.REGULAR;
this.getSpellAbility().addEffect(new LoseLifeAllPlayersEffect(xValue));
Effect effect = new DiscardEachPlayerEffect(xValue, false);
effect.setText(", discards X cards");
diff --git a/Mage.Sets/src/mage/cards/d/DeathGrasp.java b/Mage.Sets/src/mage/cards/d/DeathGrasp.java
index 114635e43c..d92c30100f 100644
--- a/Mage.Sets/src/mage/cards/d/DeathGrasp.java
+++ b/Mage.Sets/src/mage/cards/d/DeathGrasp.java
@@ -21,8 +21,8 @@ public final class DeathGrasp extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{W}{B}");
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
- this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
+ this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
}
diff --git a/Mage.Sets/src/mage/cards/d/DeathWind.java b/Mage.Sets/src/mage/cards/d/DeathWind.java
index 83b1418d65..3b157315f4 100644
--- a/Mage.Sets/src/mage/cards/d/DeathWind.java
+++ b/Mage.Sets/src/mage/cards/d/DeathWind.java
@@ -22,7 +22,7 @@ public final class DeathWind extends CardImpl {
// Target creature gets -X/-X until end of turn.
- DynamicValue x = new SignInversionDynamicValue(ManacostVariableValue.instance);
+ DynamicValue x = new SignInversionDynamicValue(ManacostVariableValue.REGULAR);
this.getSpellAbility().addEffect(new BoostTargetEffect(x, x, Duration.EndOfTurn, true));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
}
diff --git a/Mage.Sets/src/mage/cards/d/DecreeOfJustice.java b/Mage.Sets/src/mage/cards/d/DecreeOfJustice.java
index e9afaf4ec4..567d6f7f13 100644
--- a/Mage.Sets/src/mage/cards/d/DecreeOfJustice.java
+++ b/Mage.Sets/src/mage/cards/d/DecreeOfJustice.java
@@ -28,7 +28,7 @@ public final class DecreeOfJustice extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{2}{W}{W}");
// Create X 4/4 white Angel creature tokens with flying.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new AngelToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new AngelToken(), ManacostVariableValue.REGULAR));
// Cycling {2}{W}
this.addAbility(new CyclingAbility(new ManaCostsImpl<>("{2}{W}")));
diff --git a/Mage.Sets/src/mage/cards/d/Demonfire.java b/Mage.Sets/src/mage/cards/d/Demonfire.java
index 646eb520ac..6a8301b096 100644
--- a/Mage.Sets/src/mage/cards/d/Demonfire.java
+++ b/Mage.Sets/src/mage/cards/d/Demonfire.java
@@ -31,7 +31,7 @@ public final class Demonfire extends CardImpl {
// Demonfire deals X damage to any target.
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
- new DamageTargetEffect(ManacostVariableValue.instance),
+ new DamageTargetEffect(ManacostVariableValue.REGULAR),
new InvertCondition(HellbentCondition.instance),
"{this} deals X damage to any target"));
@@ -41,7 +41,7 @@ public final class Demonfire extends CardImpl {
// Hellbent - If you have no cards in hand, Demonfire can't be countered and the damage can't be prevented.
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
- new DamageTargetEffect(ManacostVariableValue.instance, false),
+ new DamageTargetEffect(ManacostVariableValue.REGULAR, false),
HellbentCondition.instance,
"
Hellbent — If you have no cards in hand, this spell can't be countered and the damage can't be prevented."));
// can't be countered
diff --git a/Mage.Sets/src/mage/cards/d/Detonate.java b/Mage.Sets/src/mage/cards/d/Detonate.java
index 783fe1d1ff..2a0996ce82 100644
--- a/Mage.Sets/src/mage/cards/d/Detonate.java
+++ b/Mage.Sets/src/mage/cards/d/Detonate.java
@@ -29,7 +29,7 @@ public final class Detonate extends CardImpl {
// Destroy target artifact with converted mana cost X. It can't be regenerated. Detonate deals X damage to that artifact's controller.
this.getSpellAbility().addEffect(new DestroyTargetEffect(true));
this.getSpellAbility().addTarget(new TargetArtifactPermanent(new FilterArtifactPermanent("artifact with mana value X")));
- Effect effect = new DamageTargetControllerEffect(ManacostVariableValue.instance);
+ Effect effect = new DamageTargetControllerEffect(ManacostVariableValue.REGULAR);
effect.setText("{this} deals X damage to that artifact's controller");
this.getSpellAbility().addEffect(effect);
this.getSpellAbility().setTargetAdjuster(DetonateAdjuster.instance);
diff --git a/Mage.Sets/src/mage/cards/d/DevilsPlay.java b/Mage.Sets/src/mage/cards/d/DevilsPlay.java
index c81609f044..a6b959ccbd 100644
--- a/Mage.Sets/src/mage/cards/d/DevilsPlay.java
+++ b/Mage.Sets/src/mage/cards/d/DevilsPlay.java
@@ -23,7 +23,7 @@ public final class DevilsPlay extends CardImpl {
// Devil's Play deals X damage to any target.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
// Flashback {X}{R}{R}{R}
this.addAbility(new FlashbackAbility(new ManaCostsImpl("{X}{R}{R}{R}"), TimingRule.SORCERY));
diff --git a/Mage.Sets/src/mage/cards/d/Disintegrate.java b/Mage.Sets/src/mage/cards/d/Disintegrate.java
index e4cc76b1d8..b4d6fc9b4f 100644
--- a/Mage.Sets/src/mage/cards/d/Disintegrate.java
+++ b/Mage.Sets/src/mage/cards/d/Disintegrate.java
@@ -23,7 +23,7 @@ public final class Disintegrate extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{R}");
// Disintegrate deals X damage to any target. That creature can't be regenerated this turn. If the creature would die this turn, exile it instead.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addEffect(new CantRegenerateTargetEffect(Duration.EndOfTurn, "That creature"));
Effect effect = new ExileTargetIfDiesEffect();
effect.setText("If the creature would die this turn, exile it instead");
diff --git a/Mage.Sets/src/mage/cards/d/DranaKalastriaBloodchief.java b/Mage.Sets/src/mage/cards/d/DranaKalastriaBloodchief.java
index deef67beac..72334b9d24 100644
--- a/Mage.Sets/src/mage/cards/d/DranaKalastriaBloodchief.java
+++ b/Mage.Sets/src/mage/cards/d/DranaKalastriaBloodchief.java
@@ -37,8 +37,8 @@ public final class DranaKalastriaBloodchief extends CardImpl {
this.toughness = new MageInt(4);
this.addAbility(FlyingAbility.getInstance());
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(StaticValue.get(0), new SignInversionDynamicValue(ManacostVariableValue.instance), Duration.EndOfTurn), new ManaCostsImpl("{X}{B}{B}"));
- ability.addEffect(new BoostSourceEffect(ManacostVariableValue.instance, StaticValue.get(0), Duration.EndOfTurn));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(StaticValue.get(0), new SignInversionDynamicValue(ManacostVariableValue.REGULAR), Duration.EndOfTurn), new ManaCostsImpl("{X}{B}{B}"));
+ ability.addEffect(new BoostSourceEffect(ManacostVariableValue.REGULAR, StaticValue.get(0), Duration.EndOfTurn));
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);
}
diff --git a/Mage.Sets/src/mage/cards/d/DregsOfSorrow.java b/Mage.Sets/src/mage/cards/d/DregsOfSorrow.java
index 1b041c59f2..4861a8bae2 100644
--- a/Mage.Sets/src/mage/cards/d/DregsOfSorrow.java
+++ b/Mage.Sets/src/mage/cards/d/DregsOfSorrow.java
@@ -28,7 +28,7 @@ public final class DregsOfSorrow extends CardImpl {
// Destroy X target nonblack creatures. Draw X cards.
this.getSpellAbility().addEffect(new DestroyTargetEffect("Destroy X target nonblack creatures"));
- this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().setTargetAdjuster(DregsOfSorrowAdjuster.instance);
}
diff --git a/Mage.Sets/src/mage/cards/e/Earthquake.java b/Mage.Sets/src/mage/cards/e/Earthquake.java
index 8784ddc181..2f9bdbcb47 100644
--- a/Mage.Sets/src/mage/cards/e/Earthquake.java
+++ b/Mage.Sets/src/mage/cards/e/Earthquake.java
@@ -29,7 +29,7 @@ public final class Earthquake extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{R}");
// Hurricane deals X damage to each creature with flying and each player.
- this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.instance, filter));
+ this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.REGULAR, filter));
}
private Earthquake(final Earthquake card) {
diff --git a/Mage.Sets/src/mage/cards/e/Electrodominance.java b/Mage.Sets/src/mage/cards/e/Electrodominance.java
index 4b9342fcaa..ede24d1243 100644
--- a/Mage.Sets/src/mage/cards/e/Electrodominance.java
+++ b/Mage.Sets/src/mage/cards/e/Electrodominance.java
@@ -19,9 +19,9 @@ public final class Electrodominance extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{R}{R}");
// Electrodominance deals X damage to any target. You may cast a card with converted mana cost X or less from your hand without paying its mana cost.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
- this.getSpellAbility().addEffect(new CastWithoutPayingManaCostEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CastWithoutPayingManaCostEffect(ManacostVariableValue.REGULAR));
}
private Electrodominance(final Electrodominance card) {
diff --git a/Mage.Sets/src/mage/cards/e/EmptyThePits.java b/Mage.Sets/src/mage/cards/e/EmptyThePits.java
index 3c7a77d0c6..9378cb5f50 100644
--- a/Mage.Sets/src/mage/cards/e/EmptyThePits.java
+++ b/Mage.Sets/src/mage/cards/e/EmptyThePits.java
@@ -24,7 +24,7 @@ public final class EmptyThePits extends CardImpl {
this.addAbility(new DelveAbility());
// create X 2/2 black Zombie creature tokens tapped.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken(), ManacostVariableValue.instance, true, false));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken(), ManacostVariableValue.REGULAR, true, false));
}
private EmptyThePits(final EmptyThePits card) {
diff --git a/Mage.Sets/src/mage/cards/e/EnergyBolt.java b/Mage.Sets/src/mage/cards/e/EnergyBolt.java
index 576e214bb2..8fdd6e2db2 100644
--- a/Mage.Sets/src/mage/cards/e/EnergyBolt.java
+++ b/Mage.Sets/src/mage/cards/e/EnergyBolt.java
@@ -22,10 +22,10 @@ public final class EnergyBolt extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{R}{W}");
// Choose one - Energy Bolt deals X damage to target player; or target player gains X life.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetPlayerOrPlaneswalker());
Mode mode = new Mode();
- mode.addEffect(new GainLifeTargetEffect(ManacostVariableValue.instance));
+ mode.addEffect(new GainLifeTargetEffect(ManacostVariableValue.REGULAR));
mode.addTarget(new TargetPlayer());
this.getSpellAbility().addMode(mode);
}
diff --git a/Mage.Sets/src/mage/cards/e/EnergyVortex.java b/Mage.Sets/src/mage/cards/e/EnergyVortex.java
index a656432995..e18e704d1c 100644
--- a/Mage.Sets/src/mage/cards/e/EnergyVortex.java
+++ b/Mage.Sets/src/mage/cards/e/EnergyVortex.java
@@ -56,7 +56,7 @@ public final class EnergyVortex extends CardImpl {
Zone.BATTLEFIELD,
new AddCountersSourceEffect(
CounterType.VORTEX.createInstance(),
- ManacostVariableValue.instance, true
+ ManacostVariableValue.REGULAR, true
), new ManaCostsImpl("{X}"),
new IsStepCondition(PhaseStep.UPKEEP)
));
diff --git a/Mage.Sets/src/mage/cards/e/Enrage.java b/Mage.Sets/src/mage/cards/e/Enrage.java
index 20d914cb32..d40c72c34e 100644
--- a/Mage.Sets/src/mage/cards/e/Enrage.java
+++ b/Mage.Sets/src/mage/cards/e/Enrage.java
@@ -22,7 +22,7 @@ public final class Enrage extends CardImpl {
// Target creature gets +X/+0 until end of turn.
- this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.instance, StaticValue.get(0), Duration.EndOfTurn));
+ this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.REGULAR, StaticValue.get(0), Duration.EndOfTurn));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
}
diff --git a/Mage.Sets/src/mage/cards/e/EnshrinedMemories.java b/Mage.Sets/src/mage/cards/e/EnshrinedMemories.java
index 25b6013acf..588e9c89d9 100644
--- a/Mage.Sets/src/mage/cards/e/EnshrinedMemories.java
+++ b/Mage.Sets/src/mage/cards/e/EnshrinedMemories.java
@@ -19,7 +19,7 @@ public final class EnshrinedMemories extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{G}");
// Reveal the top X cards of your library. Put all creature cards revealed this way into your hand and the rest on the bottom of your library in any order.
- this.getSpellAbility().addEffect(new RevealLibraryPutIntoHandEffect(ManacostVariableValue.instance, StaticFilters.FILTER_CARD_CREATURE, Zone.LIBRARY, true));
+ this.getSpellAbility().addEffect(new RevealLibraryPutIntoHandEffect(ManacostVariableValue.REGULAR, StaticFilters.FILTER_CARD_CREATURE, Zone.LIBRARY, true));
}
private EnshrinedMemories(final EnshrinedMemories card) {
diff --git a/Mage.Sets/src/mage/cards/e/EntreatTheAngels.java b/Mage.Sets/src/mage/cards/e/EntreatTheAngels.java
index 0276141bbd..719f833f99 100644
--- a/Mage.Sets/src/mage/cards/e/EntreatTheAngels.java
+++ b/Mage.Sets/src/mage/cards/e/EntreatTheAngels.java
@@ -22,7 +22,7 @@ public final class EntreatTheAngels extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{W}{W}{W}");
// Create X 4/4 white Angel creature tokens with flying.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new AngelToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new AngelToken(), ManacostVariableValue.REGULAR));
// Miracle {X}{W}{W}
this.addAbility(new MiracleAbility(this, new ManaCostsImpl("{X}{W}{W}")));
diff --git a/Mage.Sets/src/mage/cards/e/ErebossIntervention.java b/Mage.Sets/src/mage/cards/e/ErebossIntervention.java
index 11842dc4ef..b1136c3161 100644
--- a/Mage.Sets/src/mage/cards/e/ErebossIntervention.java
+++ b/Mage.Sets/src/mage/cards/e/ErebossIntervention.java
@@ -30,9 +30,9 @@ public final class ErebossIntervention extends CardImpl {
// Choose one —
// • Target creature gets -X/-X until end of turn. You gain X life.
- DynamicValue x = new SignInversionDynamicValue(ManacostVariableValue.instance);
+ DynamicValue x = new SignInversionDynamicValue(ManacostVariableValue.REGULAR);
this.getSpellAbility().addEffect(new BoostTargetEffect(x,x,Duration.EndOfTurn));
- this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.instance)
+ this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR)
.setText("You gain X life"));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
diff --git a/Mage.Sets/src/mage/cards/e/Excise.java b/Mage.Sets/src/mage/cards/e/Excise.java
index 8a31c6ff9a..e390c7ba97 100644
--- a/Mage.Sets/src/mage/cards/e/Excise.java
+++ b/Mage.Sets/src/mage/cards/e/Excise.java
@@ -28,7 +28,7 @@ public final class Excise extends CardImpl {
// Excise target nonwhite attacking creature unless its controller pays {X}.
this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter));
- this.getSpellAbility().addEffect(new DoUnlessTargetPlayerOrTargetsControllerPaysEffect(new ExileTargetEffect(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DoUnlessTargetPlayerOrTargetsControllerPaysEffect(new ExileTargetEffect(), ManacostVariableValue.REGULAR));
}
private Excise(final Excise card) {
diff --git a/Mage.Sets/src/mage/cards/f/FallOfTheTitans.java b/Mage.Sets/src/mage/cards/f/FallOfTheTitans.java
index c73511cf02..7594e9ab82 100644
--- a/Mage.Sets/src/mage/cards/f/FallOfTheTitans.java
+++ b/Mage.Sets/src/mage/cards/f/FallOfTheTitans.java
@@ -21,7 +21,7 @@ public final class FallOfTheTitans extends CardImpl {
// Fall of the Titans deals X damage to each of up to two target creatures and/or players.
this.getSpellAbility().addTarget(new TargetAnyTarget(0, 2));
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
// Surge {X}{R}
addAbility(new SurgeAbility(this, "{X}{R}"));
diff --git a/Mage.Sets/src/mage/cards/f/FanningTheFlames.java b/Mage.Sets/src/mage/cards/f/FanningTheFlames.java
index 9d8108b2bb..49213bfe2a 100644
--- a/Mage.Sets/src/mage/cards/f/FanningTheFlames.java
+++ b/Mage.Sets/src/mage/cards/f/FanningTheFlames.java
@@ -23,7 +23,7 @@ public final class FanningTheFlames extends CardImpl {
this.addAbility(new BuybackAbility("{3}"));
// Fanning the Flames deals X damage to any target.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
}
diff --git a/Mage.Sets/src/mage/cards/f/Fascination.java b/Mage.Sets/src/mage/cards/f/Fascination.java
index 4ce727b83d..18702f8040 100644
--- a/Mage.Sets/src/mage/cards/f/Fascination.java
+++ b/Mage.Sets/src/mage/cards/f/Fascination.java
@@ -22,11 +22,11 @@ public final class Fascination extends CardImpl {
// Choose one -
// * Each player draws X cards.
- this.getSpellAbility().addEffect(new DrawCardAllEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardAllEffect(ManacostVariableValue.REGULAR));
// * Each player puts the top X cards of their library into their graveyard.
Mode mode = new Mode();
- mode.addEffect(new MillCardsEachPlayerEffect(ManacostVariableValue.instance, TargetController.ANY));
+ mode.addEffect(new MillCardsEachPlayerEffect(ManacostVariableValue.REGULAR, TargetController.ANY));
this.getSpellAbility().addMode(mode);
}
diff --git a/Mage.Sets/src/mage/cards/f/FestivalOfTheGuildpact.java b/Mage.Sets/src/mage/cards/f/FestivalOfTheGuildpact.java
index 96daa17bed..1e2d6674a4 100644
--- a/Mage.Sets/src/mage/cards/f/FestivalOfTheGuildpact.java
+++ b/Mage.Sets/src/mage/cards/f/FestivalOfTheGuildpact.java
@@ -20,7 +20,7 @@ public final class FestivalOfTheGuildpact extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{W}");
// Prevent the next X damage that would be dealt to you this turn.
- this.getSpellAbility().addEffect(new PreventDamageToControllerEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new PreventDamageToControllerEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.REGULAR));
// Draw a card.
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1));
diff --git a/Mage.Sets/src/mage/cards/f/FinaleOfPromise.java b/Mage.Sets/src/mage/cards/f/FinaleOfPromise.java
index f9372cbfcc..50c4d2bdae 100644
--- a/Mage.Sets/src/mage/cards/f/FinaleOfPromise.java
+++ b/Mage.Sets/src/mage/cards/f/FinaleOfPromise.java
@@ -66,7 +66,7 @@ enum FinaleOfPromiseAdjuster implements TargetAdjuster {
public void adjustTargets(Ability ability, Game game) {
ability.getTargets().clear();
- int xValue = ManacostVariableValue.instance.calculate(game, ability, null);
+ int xValue = ManacostVariableValue.REGULAR.calculate(game, ability, null);
// <= must be replaced to <= for html view
FilterCard filter1 = FinaleOfPromise.filterInstant.copy();
@@ -146,7 +146,7 @@ class FinaleOfPromiseEffect extends OneShotEffect {
}
// If X is 10 or more, copy each of those spells twice. You may choose new targets for the copies
- int xValue = ManacostVariableValue.instance.calculate(game, source, null);
+ int xValue = ManacostVariableValue.REGULAR.calculate(game, source, null);
if (xValue >= 10) {
for (UUID id : cardsToCast) {
Card card = game.getCard(id);
diff --git a/Mage.Sets/src/mage/cards/f/FlowstoneSlide.java b/Mage.Sets/src/mage/cards/f/FlowstoneSlide.java
index ef42f14f43..0c97a0c69c 100644
--- a/Mage.Sets/src/mage/cards/f/FlowstoneSlide.java
+++ b/Mage.Sets/src/mage/cards/f/FlowstoneSlide.java
@@ -20,8 +20,8 @@ public final class FlowstoneSlide extends CardImpl {
public FlowstoneSlide(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{2}{R}{R}");
- DynamicValue xPos = ManacostVariableValue.instance;
- DynamicValue xNeg = new SignInversionDynamicValue(ManacostVariableValue.instance);
+ DynamicValue xPos = ManacostVariableValue.REGULAR;
+ DynamicValue xNeg = new SignInversionDynamicValue(ManacostVariableValue.REGULAR);
// All creatures get +X/-X until end of turn.
this.getSpellAbility().addEffect(new BoostAllEffect(xPos, xNeg, Duration.EndOfTurn));
diff --git a/Mage.Sets/src/mage/cards/f/FolioOfFancies.java b/Mage.Sets/src/mage/cards/f/FolioOfFancies.java
index 1f81cc0be1..aba604bb26 100644
--- a/Mage.Sets/src/mage/cards/f/FolioOfFancies.java
+++ b/Mage.Sets/src/mage/cards/f/FolioOfFancies.java
@@ -36,7 +36,7 @@ public final class FolioOfFancies extends CardImpl {
// {X}{X}, {T}: Each player draws X cards.
Ability ability = new SimpleActivatedAbility(
- new DrawCardAllEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{X}")
+ new DrawCardAllEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{X}")
);
ability.addCost(new TapSourceCost());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/f/ForceLightning.java b/Mage.Sets/src/mage/cards/f/ForceLightning.java
index f963081c3b..9d07d3da97 100644
--- a/Mage.Sets/src/mage/cards/f/ForceLightning.java
+++ b/Mage.Sets/src/mage/cards/f/ForceLightning.java
@@ -24,7 +24,7 @@ public final class ForceLightning extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{R}{R}");
// Force Lightning deals X damage to any target.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
// Scry X.
diff --git a/Mage.Sets/src/mage/cards/f/FractalHarness.java b/Mage.Sets/src/mage/cards/f/FractalHarness.java
index 71785fe42b..f56ab7bf9d 100644
--- a/Mage.Sets/src/mage/cards/f/FractalHarness.java
+++ b/Mage.Sets/src/mage/cards/f/FractalHarness.java
@@ -73,7 +73,7 @@ class FractalHarnessTokenEffect extends OneShotEffect {
public boolean apply(Game game, Ability source) {
Token token = new QuandrixToken();
token.putOntoBattlefield(1, game, source, source.getControllerId());
- int xValue = ManacostVariableValue.instance.calculate(game, source, this);
+ int xValue = ManacostVariableValue.ETB.calculate(game, source, this);
boolean flag = true;
for (UUID tokenId : token.getLastAddedTokenIds()) {
Permanent permanent = game.getPermanent(tokenId);
diff --git a/Mage.Sets/src/mage/cards/f/FractalSummoning.java b/Mage.Sets/src/mage/cards/f/FractalSummoning.java
index 1927b787be..fa94b4365b 100644
--- a/Mage.Sets/src/mage/cards/f/FractalSummoning.java
+++ b/Mage.Sets/src/mage/cards/f/FractalSummoning.java
@@ -21,7 +21,7 @@ public final class FractalSummoning extends CardImpl {
// Create a 0/0 green and blue Fractal creature token. Put X +1/+1 counters on it.
this.getSpellAbility().addEffect(QuandrixToken.getEffect(
- ManacostVariableValue.instance, "Put X +1/+1 counters on it"
+ ManacostVariableValue.REGULAR, "Put X +1/+1 counters on it"
));
}
diff --git a/Mage.Sets/src/mage/cards/g/GadwickTheWizened.java b/Mage.Sets/src/mage/cards/g/GadwickTheWizened.java
index 15aa8dad65..a664619d38 100644
--- a/Mage.Sets/src/mage/cards/g/GadwickTheWizened.java
+++ b/Mage.Sets/src/mage/cards/g/GadwickTheWizened.java
@@ -48,7 +48,7 @@ public final class GadwickTheWizened extends CardImpl {
// When Gadwick, the Wizened enters the battlefield, draw X cards.
this.addAbility(new EntersBattlefieldTriggeredAbility(
- new DrawCardSourceControllerEffect(ManacostVariableValue.instance)
+ new DrawCardSourceControllerEffect(ManacostVariableValue.ETB)
));
// Whenever you cast a blue spell, tap target nonland permanent an opponent controls.
diff --git a/Mage.Sets/src/mage/cards/g/GhiredsBelligerence.java b/Mage.Sets/src/mage/cards/g/GhiredsBelligerence.java
index 39da04db6c..87ea5818fe 100644
--- a/Mage.Sets/src/mage/cards/g/GhiredsBelligerence.java
+++ b/Mage.Sets/src/mage/cards/g/GhiredsBelligerence.java
@@ -31,7 +31,7 @@ public final class GhiredsBelligerence extends CardImpl {
// Ghired's Belligerence deals X damage divided as you choose among any number of target creatures. Whenever a creature dealt damage this way dies this turn, populate.
this.getSpellAbility().addEffect(new GhiredsBelligerenceEffect());
- this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(ManacostVariableValue.instance));
+ this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(ManacostVariableValue.REGULAR));
}
private GhiredsBelligerence(final GhiredsBelligerence card) {
@@ -46,7 +46,7 @@ public final class GhiredsBelligerence extends CardImpl {
class GhiredsBelligerenceEffect extends OneShotEffect {
- private static final DamageMultiEffect effect = new DamageMultiEffect(ManacostVariableValue.instance);
+ private static final DamageMultiEffect effect = new DamageMultiEffect(ManacostVariableValue.REGULAR);
GhiredsBelligerenceEffect() {
super(Outcome.Benefit);
diff --git a/Mage.Sets/src/mage/cards/g/GhituFire.java b/Mage.Sets/src/mage/cards/g/GhituFire.java
index ece50d9aa1..f383065a44 100644
--- a/Mage.Sets/src/mage/cards/g/GhituFire.java
+++ b/Mage.Sets/src/mage/cards/g/GhituFire.java
@@ -23,7 +23,7 @@ public final class GhituFire extends CardImpl {
public GhituFire(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{R}");
- Effect effect = new DamageTargetEffect(ManacostVariableValue.instance);
+ Effect effect = new DamageTargetEffect(ManacostVariableValue.REGULAR);
// You may cast Ghitu Fire as though it had flash if you pay {2} more to cast it.
Ability ability = new PayMoreToCastAsThoughtItHadFlashAbility(this, new ManaCostsImpl("{2}"));
ability.addEffect(effect);
diff --git a/Mage.Sets/src/mage/cards/g/Gigantoplasm.java b/Mage.Sets/src/mage/cards/g/Gigantoplasm.java
index 866b1f5c6f..544388d29c 100644
--- a/Mage.Sets/src/mage/cards/g/Gigantoplasm.java
+++ b/Mage.Sets/src/mage/cards/g/Gigantoplasm.java
@@ -22,7 +22,6 @@ import mage.constants.SubLayer;
import mage.constants.Zone;
import mage.filter.StaticFilters;
import mage.game.Game;
-import mage.game.permanent.Permanent;
import mage.util.functions.CopyApplier;
/**
@@ -57,7 +56,7 @@ class GigantoplasmCopyApplier extends CopyApplier {
@Override
public boolean apply(Game game, MageObject blueprint, Ability source, UUID copyToObjectId) {
- DynamicValue variableMana = ManacostVariableValue.instance;
+ DynamicValue variableMana = ManacostVariableValue.REGULAR;
Effect effect = new SetPowerToughnessSourceEffect(variableMana, Duration.WhileOnBattlefield, SubLayer.SetPT_7b);
effect.setText("This creature has base power and toughness X/X");
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{X}"));
diff --git a/Mage.Sets/src/mage/cards/g/GoblinDynamo.java b/Mage.Sets/src/mage/cards/g/GoblinDynamo.java
index e898821ebf..c8b3ff1df4 100644
--- a/Mage.Sets/src/mage/cards/g/GoblinDynamo.java
+++ b/Mage.Sets/src/mage/cards/g/GoblinDynamo.java
@@ -35,7 +35,7 @@ public final class GoblinDynamo extends CardImpl {
this.addAbility(ability);
//{X}{R}, {T}, Sacrifice Goblin Dynamo: Goblin Dynamo deals X damage to any target.
- ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{R}"));
+ ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{R}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetAnyTarget());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/g/GoblinOffensive.java b/Mage.Sets/src/mage/cards/g/GoblinOffensive.java
index 35fa32cadb..6d11a6d884 100644
--- a/Mage.Sets/src/mage/cards/g/GoblinOffensive.java
+++ b/Mage.Sets/src/mage/cards/g/GoblinOffensive.java
@@ -19,7 +19,7 @@ public final class GoblinOffensive extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{1}{R}{R}");
// create X 1/1 red Goblin creature tokens.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new GoblinToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new GoblinToken(), ManacostVariableValue.REGULAR));
}
private GoblinOffensive(final GoblinOffensive card) {
diff --git a/Mage.Sets/src/mage/cards/g/GreelMindRaker.java b/Mage.Sets/src/mage/cards/g/GreelMindRaker.java
index d615d2a683..0d06e966fe 100644
--- a/Mage.Sets/src/mage/cards/g/GreelMindRaker.java
+++ b/Mage.Sets/src/mage/cards/g/GreelMindRaker.java
@@ -37,7 +37,7 @@ public final class GreelMindRaker extends CardImpl {
// {X}{B}, {tap}, Discard two cards: Target player discards X cards at random.
Ability ability = new SimpleActivatedAbility(new DiscardTargetEffect(
- ManacostVariableValue.instance, true
+ ManacostVariableValue.REGULAR, true
), new ManaCostsImpl("{X}{B}"));
ability.addCost(new TapSourceCost());
ability.addCost(new DiscardTargetCost(new TargetCardInHand(2, filter)));
diff --git a/Mage.Sets/src/mage/cards/h/HailOfArrows.java b/Mage.Sets/src/mage/cards/h/HailOfArrows.java
index 3d89ab07d3..a6d58a05a3 100644
--- a/Mage.Sets/src/mage/cards/h/HailOfArrows.java
+++ b/Mage.Sets/src/mage/cards/h/HailOfArrows.java
@@ -20,8 +20,8 @@ public final class HailOfArrows extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{W}");
// Hail of Arrows deals X damage divided as you choose among any number of target attacking creatures.
- this.getSpellAbility().addEffect(new DamageMultiEffect(ManacostVariableValue.instance));
- this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(ManacostVariableValue.instance, new FilterAttackingCreature()));
+ this.getSpellAbility().addEffect(new DamageMultiEffect(ManacostVariableValue.REGULAR));
+ this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(ManacostVariableValue.REGULAR, new FilterAttackingCreature()));
}
private HailOfArrows(final HailOfArrows card) {
diff --git a/Mage.Sets/src/mage/cards/h/HeatRay.java b/Mage.Sets/src/mage/cards/h/HeatRay.java
index 94746a5e0b..9975b2d0dd 100644
--- a/Mage.Sets/src/mage/cards/h/HeatRay.java
+++ b/Mage.Sets/src/mage/cards/h/HeatRay.java
@@ -19,7 +19,7 @@ public final class HeatRay extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{R}");
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
}
diff --git a/Mage.Sets/src/mage/cards/h/HeavenEarth.java b/Mage.Sets/src/mage/cards/h/HeavenEarth.java
index 098a4fced3..607ff5bdf5 100644
--- a/Mage.Sets/src/mage/cards/h/HeavenEarth.java
+++ b/Mage.Sets/src/mage/cards/h/HeavenEarth.java
@@ -32,13 +32,13 @@ public final class HeavenEarth extends SplitCard {
// Falling
// Falling deals X damage to each creature with flying.
- getLeftHalfCard().getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, filterFlying));
+ getLeftHalfCard().getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, filterFlying));
// to
// Earth
// Earth deals X damage to each creature without flying.
getRightHalfCard().addAbility(new AftermathAbility().setRuleAtTheTop(true));
- getRightHalfCard().getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, filterWithouFlying));
+ getRightHalfCard().getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, filterWithouFlying));
}
private HeavenEarth(final HeavenEarth card) {
diff --git a/Mage.Sets/src/mage/cards/h/HeliodsIntervention.java b/Mage.Sets/src/mage/cards/h/HeliodsIntervention.java
index 4fe2198f3b..092753bf4b 100644
--- a/Mage.Sets/src/mage/cards/h/HeliodsIntervention.java
+++ b/Mage.Sets/src/mage/cards/h/HeliodsIntervention.java
@@ -23,7 +23,7 @@ import java.util.UUID;
*/
public final class HeliodsIntervention extends CardImpl {
- private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.instance, 2);
+ private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.REGULAR, 2);
public HeliodsIntervention(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{W}{W}");
diff --git a/Mage.Sets/src/mage/cards/h/HelixPinnacle.java b/Mage.Sets/src/mage/cards/h/HelixPinnacle.java
index c1a55e7122..4cf9dbf7e0 100644
--- a/Mage.Sets/src/mage/cards/h/HelixPinnacle.java
+++ b/Mage.Sets/src/mage/cards/h/HelixPinnacle.java
@@ -34,7 +34,7 @@ public final class HelixPinnacle extends CardImpl {
// {X}: Put X tower counters on Helix Pinnacle.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD,
- new AddCountersSourceEffect(CounterType.TOWER.createInstance(), ManacostVariableValue.instance, true),
+ new AddCountersSourceEffect(CounterType.TOWER.createInstance(), ManacostVariableValue.REGULAR, true),
new ManaCostsImpl("{X}")));
// At the beginning of your upkeep, if there are 100 or more tower counters on Helix Pinnacle, you win the game.
diff --git a/Mage.Sets/src/mage/cards/h/HelmOfObedience.java b/Mage.Sets/src/mage/cards/h/HelmOfObedience.java
index a42bb5098e..a925bb5a9f 100644
--- a/Mage.Sets/src/mage/cards/h/HelmOfObedience.java
+++ b/Mage.Sets/src/mage/cards/h/HelmOfObedience.java
@@ -69,7 +69,7 @@ class HelmOfObedienceEffect extends OneShotEffect {
public boolean apply(Game game, Ability source) {
Player controller = game.getPlayer(source.getControllerId());
Player targetOpponent = game.getPlayer(source.getFirstTarget());
- int max = ManacostVariableValue.instance.calculate(game, source, this);
+ int max = ManacostVariableValue.REGULAR.calculate(game, source, this);
if (targetOpponent == null || controller == null || max < 1) {
return false;
}
diff --git a/Mage.Sets/src/mage/cards/h/HowlFromBeyond.java b/Mage.Sets/src/mage/cards/h/HowlFromBeyond.java
index 7c30e38852..108178c225 100644
--- a/Mage.Sets/src/mage/cards/h/HowlFromBeyond.java
+++ b/Mage.Sets/src/mage/cards/h/HowlFromBeyond.java
@@ -23,7 +23,7 @@ public final class HowlFromBeyond extends CardImpl {
// Target creature gets +X/+0 until end of turn.
- this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.instance, StaticValue.get(0), Duration.EndOfTurn));
+ this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.REGULAR, StaticValue.get(0), Duration.EndOfTurn));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
}
diff --git a/Mage.Sets/src/mage/cards/h/HuntToExtinction.java b/Mage.Sets/src/mage/cards/h/HuntToExtinction.java
index 2636e5afb6..0f64cb90d0 100644
--- a/Mage.Sets/src/mage/cards/h/HuntToExtinction.java
+++ b/Mage.Sets/src/mage/cards/h/HuntToExtinction.java
@@ -33,10 +33,10 @@ public final class HuntToExtinction extends CardImpl {
this.getSpellAbility().addTarget(new TargetOpponentsCreaturePermanent(0, 1));
// Hunt to Extinction deals X damage to each creature.
- this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, new FilterCreaturePermanent()));
+ this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, new FilterCreaturePermanent()));
// Hunt to Exctinction deals an additional X damage to each creature with a bounty counter on it.
- Effect effect = new DamageAllEffect(ManacostVariableValue.instance, new FilterCreaturePermanent(filter));
+ Effect effect = new DamageAllEffect(ManacostVariableValue.REGULAR, new FilterCreaturePermanent(filter));
effect.setText("Hunt to Exctinction deals an additional X damage to each creature with a bounty counter on it");
this.getSpellAbility().addEffect(effect);
diff --git a/Mage.Sets/src/mage/cards/h/Hurricane.java b/Mage.Sets/src/mage/cards/h/Hurricane.java
index fc249d2cc5..ff28a61cc2 100644
--- a/Mage.Sets/src/mage/cards/h/Hurricane.java
+++ b/Mage.Sets/src/mage/cards/h/Hurricane.java
@@ -28,7 +28,7 @@ public final class Hurricane extends CardImpl {
// Hurricane deals X damage to each creature with flying and each player.
- this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.instance, filter));
+ this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.REGULAR, filter));
}
private Hurricane(final Hurricane card) {
diff --git a/Mage.Sets/src/mage/cards/i/Illuminate.java b/Mage.Sets/src/mage/cards/i/Illuminate.java
index b923103df1..dced3323cb 100644
--- a/Mage.Sets/src/mage/cards/i/Illuminate.java
+++ b/Mage.Sets/src/mage/cards/i/Illuminate.java
@@ -28,14 +28,14 @@ public final class Illuminate extends CardImpl {
kickerAbility.addKickerCost("{3}{U}");
this.addAbility(kickerAbility);
// Illuminate deals X damage to target creature. If Illuminate was kicked with its {2}{R} kicker, it deals X damage to that creature's controller. If Illuminate was kicked with its {3}{U} kicker, you draw X cards.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
- new DamageTargetControllerEffect(ManacostVariableValue.instance),
+ new DamageTargetControllerEffect(ManacostVariableValue.REGULAR),
new KickedCostCondition("{2}{R}"),
"if this spell was kicked with its {2}{R} kicker, it deals X damage to that creature's controller."));
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
- new DrawCardSourceControllerEffect(ManacostVariableValue.instance),
+ new DrawCardSourceControllerEffect(ManacostVariableValue.REGULAR),
new KickedCostCondition("{3}{U}"),
" if this spell was kicked with its {3}{U} kicker, you draw X cards."));
diff --git a/Mage.Sets/src/mage/cards/i/InvokeTheFiremind.java b/Mage.Sets/src/mage/cards/i/InvokeTheFiremind.java
index 98d72c5df1..923a95958c 100644
--- a/Mage.Sets/src/mage/cards/i/InvokeTheFiremind.java
+++ b/Mage.Sets/src/mage/cards/i/InvokeTheFiremind.java
@@ -21,9 +21,9 @@ public final class InvokeTheFiremind extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{U}{U}{R}");
- this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.REGULAR));
Mode mode = new Mode();
- mode.addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ mode.addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
mode.addTarget(new TargetAnyTarget());
this.getSpellAbility().addMode(mode);
}
diff --git a/Mage.Sets/src/mage/cards/j/JayasImmolatingInferno.java b/Mage.Sets/src/mage/cards/j/JayasImmolatingInferno.java
index f435a73c80..abb7488144 100644
--- a/Mage.Sets/src/mage/cards/j/JayasImmolatingInferno.java
+++ b/Mage.Sets/src/mage/cards/j/JayasImmolatingInferno.java
@@ -25,7 +25,7 @@ public final class JayasImmolatingInferno extends CardImpl {
this.addAbility(new LegendarySpellAbility());
// Jaya's Immolating Inferno deals X damage to each of up to three targets.
- Effect effect = new DamageTargetEffect(ManacostVariableValue.instance);
+ Effect effect = new DamageTargetEffect(ManacostVariableValue.REGULAR);
effect.setText("{this} deals X damage to each of up to three targets");
this.getSpellAbility().addEffect(effect);
this.getSpellAbility().addTarget(new TargetAnyTarget(1, 3));
diff --git a/Mage.Sets/src/mage/cards/j/JiwariTheEarthAflame.java b/Mage.Sets/src/mage/cards/j/JiwariTheEarthAflame.java
index ce041754c5..6d7b6326c2 100644
--- a/Mage.Sets/src/mage/cards/j/JiwariTheEarthAflame.java
+++ b/Mage.Sets/src/mage/cards/j/JiwariTheEarthAflame.java
@@ -44,13 +44,13 @@ public final class JiwariTheEarthAflame extends CardImpl {
this.toughness = new MageInt(3);
// {X}{R}, {tap}: Jiwari, the Earth Aflame deals X damage to target creature without flying.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{R}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{R}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent(filter));
this.addAbility(ability);
// Channel - {X}{R}{R}{R}, Discard Jiwari: Jiwari deals X damage to each creature without flying.
- this.addAbility(new ChannelAbility("{X}{R}{R}{R}", new DamageAllEffect(ManacostVariableValue.instance, filter)));
+ this.addAbility(new ChannelAbility("{X}{R}{R}{R}", new DamageAllEffect(ManacostVariableValue.REGULAR, filter)));
}
private JiwariTheEarthAflame(final JiwariTheEarthAflame card) {
diff --git a/Mage.Sets/src/mage/cards/k/KaerveksTorch.java b/Mage.Sets/src/mage/cards/k/KaerveksTorch.java
index a266e5d3f5..945f02f66e 100644
--- a/Mage.Sets/src/mage/cards/k/KaerveksTorch.java
+++ b/Mage.Sets/src/mage/cards/k/KaerveksTorch.java
@@ -34,7 +34,7 @@ public final class KaerveksTorch extends CardImpl {
// As long as Kaervek's Torch is on the stack, spells that target it cost {2} more to cast.
this.addAbility(new SimpleStaticAbility(Zone.STACK, new KaerveksTorchCostIncreaseEffect()));
// Kaervek's Torch deals X damage to any target.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
}
diff --git a/Mage.Sets/src/mage/cards/k/KessigWolfRun.java b/Mage.Sets/src/mage/cards/k/KessigWolfRun.java
index 138ec4808e..22ccd36344 100644
--- a/Mage.Sets/src/mage/cards/k/KessigWolfRun.java
+++ b/Mage.Sets/src/mage/cards/k/KessigWolfRun.java
@@ -34,7 +34,7 @@ public final class KessigWolfRun extends CardImpl {
TrampleAbility.getInstance(), Duration.EndOfTurn
).setText("Target creature gets +X/+0"), new ManaCostsImpl("{X}{R}{G}"));
ability.addEffect(new BoostTargetEffect(
- ManacostVariableValue.instance, StaticValue.get(0), Duration.EndOfTurn
+ ManacostVariableValue.REGULAR, StaticValue.get(0), Duration.EndOfTurn
).setText("and gains trample until end of turn"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
diff --git a/Mage.Sets/src/mage/cards/k/KillingWave.java b/Mage.Sets/src/mage/cards/k/KillingWave.java
index 3a9eec71d5..85cecf77f0 100644
--- a/Mage.Sets/src/mage/cards/k/KillingWave.java
+++ b/Mage.Sets/src/mage/cards/k/KillingWave.java
@@ -61,7 +61,7 @@ class KillingWaveEffect extends OneShotEffect {
return false;
}
- int amount = (ManacostVariableValue.instance).calculate(game, source, this);
+ int amount = (ManacostVariableValue.REGULAR).calculate(game, source, this);
if (amount > 0) {
List sacrifices = new LinkedList<>();
Map lifePaidAmounts = new HashMap<>();
diff --git a/Mage.Sets/src/mage/cards/k/KnollspineInvocation.java b/Mage.Sets/src/mage/cards/k/KnollspineInvocation.java
index 8a6243381a..79ca003c7e 100644
--- a/Mage.Sets/src/mage/cards/k/KnollspineInvocation.java
+++ b/Mage.Sets/src/mage/cards/k/KnollspineInvocation.java
@@ -32,7 +32,7 @@ public final class KnollspineInvocation extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{R}{R}");
// {X}, Discard a card with converted mana cost X: Knollspine Invocation deals X damage to any target.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance, true), new ManaCostsImpl<>("{X}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR, true), new ManaCostsImpl<>("{X}"));
ability.addCost(new DiscardTargetCost(new TargetCardInHand(filter)));
ability.addTarget(new TargetAnyTarget());
ability.setCostAdjuster(KnollspineInvocationAdjuster.instance);
diff --git a/Mage.Sets/src/mage/cards/l/LatullaKeldonOverseer.java b/Mage.Sets/src/mage/cards/l/LatullaKeldonOverseer.java
index cc2b6b6c2f..a1334d7968 100644
--- a/Mage.Sets/src/mage/cards/l/LatullaKeldonOverseer.java
+++ b/Mage.Sets/src/mage/cards/l/LatullaKeldonOverseer.java
@@ -35,7 +35,7 @@ public final class LatullaKeldonOverseer extends CardImpl {
this.toughness = new MageInt(3);
// {X}{R}, {tap}, Discard two cards: Latulla, Keldon Overseer deals X damage to any target.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{R}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{R}"));
ability.addCost(new TapSourceCost());
ability.addCost(new DiscardTargetCost(new TargetCardInHand(2, 2, new FilterCard("two cards"))));
ability.addTarget(new TargetAnyTarget());
diff --git a/Mage.Sets/src/mage/cards/l/LavaclawReaches.java b/Mage.Sets/src/mage/cards/l/LavaclawReaches.java
index 3ce191f447..a8ae2337a2 100644
--- a/Mage.Sets/src/mage/cards/l/LavaclawReaches.java
+++ b/Mage.Sets/src/mage/cards/l/LavaclawReaches.java
@@ -60,7 +60,7 @@ class LavaclawReachesToken extends TokenImpl {
color.setBlack(true);
power = new MageInt(2);
toughness = new MageInt(2);
- addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(ManacostVariableValue.instance, StaticValue.get(0), Duration.EndOfTurn), new ManaCostsImpl("{X}")));
+ addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(ManacostVariableValue.REGULAR, StaticValue.get(0), Duration.EndOfTurn), new ManaCostsImpl("{X}")));
}
public LavaclawReachesToken(final LavaclawReachesToken token) {
super(token);
diff --git a/Mage.Sets/src/mage/cards/l/Lavalanche.java b/Mage.Sets/src/mage/cards/l/Lavalanche.java
index a89dc79acd..b9432f0e63 100644
--- a/Mage.Sets/src/mage/cards/l/Lavalanche.java
+++ b/Mage.Sets/src/mage/cards/l/Lavalanche.java
@@ -27,7 +27,7 @@ public final class Lavalanche extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{B}{R}{G}");
// Lavalanche deals X damage to target player and each creature they control.
- this.getSpellAbility().addEffect(new LavalancheEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new LavalancheEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetPlayerOrPlaneswalker());
}
diff --git a/Mage.Sets/src/mage/cards/l/LifecraftAwakening.java b/Mage.Sets/src/mage/cards/l/LifecraftAwakening.java
index fdbe39600a..782cb47515 100644
--- a/Mage.Sets/src/mage/cards/l/LifecraftAwakening.java
+++ b/Mage.Sets/src/mage/cards/l/LifecraftAwakening.java
@@ -37,7 +37,7 @@ public final class LifecraftAwakening extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{G}");
// Put X +1/+1 counters on target artifact you control. If it isn't a creature or Vehicle, it becomes a 0/0 Construct artifact creature.
- ManacostVariableValue manaX = ManacostVariableValue.instance;
+ ManacostVariableValue manaX = ManacostVariableValue.REGULAR;
getSpellAbility().addEffect(new AddCountersTargetEffect(CounterType.P1P1.createInstance(), manaX));
getSpellAbility().addTarget(new TargetArtifactPermanent(filter));
getSpellAbility().addEffect(new LifecraftAwakeningEffect());
diff --git a/Mage.Sets/src/mage/cards/l/LogicKnot.java b/Mage.Sets/src/mage/cards/l/LogicKnot.java
index 800f871774..c6daf3e969 100644
--- a/Mage.Sets/src/mage/cards/l/LogicKnot.java
+++ b/Mage.Sets/src/mage/cards/l/LogicKnot.java
@@ -24,7 +24,7 @@ public final class LogicKnot extends CardImpl {
this.addAbility(new DelveAbility());
// Counter target spell unless its controller pays {X}.
- this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetSpell());
}
diff --git a/Mage.Sets/src/mage/cards/m/Magmaquake.java b/Mage.Sets/src/mage/cards/m/Magmaquake.java
index 04355cae89..4bada2e85c 100644
--- a/Mage.Sets/src/mage/cards/m/Magmaquake.java
+++ b/Mage.Sets/src/mage/cards/m/Magmaquake.java
@@ -33,7 +33,7 @@ public final class Magmaquake extends CardImpl {
// Magmaquake deals X damage to each creature without flying and each planeswalker.
- this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, filter));
+ this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, filter));
}
private Magmaquake(final Magmaquake card) {
diff --git a/Mage.Sets/src/mage/cards/m/MaliciousAdvice.java b/Mage.Sets/src/mage/cards/m/MaliciousAdvice.java
index 6cbc882de9..5355c6eab5 100644
--- a/Mage.Sets/src/mage/cards/m/MaliciousAdvice.java
+++ b/Mage.Sets/src/mage/cards/m/MaliciousAdvice.java
@@ -29,7 +29,7 @@ public final class MaliciousAdvice extends CardImpl {
Effect effect = new TapTargetEffect();
effect.setText("X target artifacts, creatures, and/or lands");
this.getSpellAbility().addEffect(effect);
- this.getSpellAbility().addEffect(new LoseLifeSourceControllerEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new LoseLifeSourceControllerEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().setTargetAdjuster(MaliciousAdviceAdjuster.instance);
}
diff --git a/Mage.Sets/src/mage/cards/m/MarathWillOfTheWild.java b/Mage.Sets/src/mage/cards/m/MarathWillOfTheWild.java
index c62667f144..0761fc9cdf 100644
--- a/Mage.Sets/src/mage/cards/m/MarathWillOfTheWild.java
+++ b/Mage.Sets/src/mage/cards/m/MarathWillOfTheWild.java
@@ -55,7 +55,7 @@ public final class MarathWillOfTheWild extends CardImpl {
this.addAbility(new EntersBattlefieldAbility(effect));
// {X}, Remove X +1/+1 counters from Marath: Choose one - Put X +1/+1 counters on target creature;
- effect = new AddCountersTargetEffect(CounterType.P1P1.createInstance(0), ManacostVariableValue.instance);
+ effect = new AddCountersTargetEffect(CounterType.P1P1.createInstance(0), ManacostVariableValue.REGULAR);
effect.setText("Put X +1/+1 counters on target creature");
Ability ability = new SimpleActivatedAbility(effect, new ManaCostsImpl("{X}"));
ability.addCost(new MarathWillOfTheWildRemoveCountersCost());
@@ -63,7 +63,7 @@ public final class MarathWillOfTheWild extends CardImpl {
// or Marath deals X damage to any target;
Mode mode = new Mode();
- mode.addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ mode.addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
mode.addTarget(new TargetAnyTarget());
ability.addMode(mode);
@@ -112,7 +112,7 @@ class MarathWillOfTheWildCreateTokenEffect extends OneShotEffect {
public boolean apply(Game game, Ability source) {
Player player = game.getPlayer(source.getControllerId());
if (player != null) {
- int amount = ManacostVariableValue.instance.calculate(game, source, this);
+ int amount = ManacostVariableValue.REGULAR.calculate(game, source, this);
Token token = new MarathWillOfTheWildElementalToken();
token.getPower().modifyBaseValue(amount);
token.getToughness().modifyBaseValue(amount);
@@ -145,7 +145,7 @@ class MarathWillOfTheWildRemoveCountersCost extends CostImpl {
@Override
public boolean pay(Ability ability, Game game, Ability source, UUID controllerId, boolean noMana, Cost costToPay) {
- int amount = ManacostVariableValue.instance.calculate(game, ability, null);
+ int amount = ManacostVariableValue.REGULAR.calculate(game, ability, null);
Permanent permanent = game.getPermanent(source.getSourceId());
if (permanent != null && permanent.getCounters(game).getCount(CounterType.P1P1) >= amount) {
permanent.removeCounters(CounterType.P1P1.getName(), amount, source, game);
diff --git a/Mage.Sets/src/mage/cards/m/MarchOfTheMultitudes.java b/Mage.Sets/src/mage/cards/m/MarchOfTheMultitudes.java
index c07daaf410..5a88761ebb 100644
--- a/Mage.Sets/src/mage/cards/m/MarchOfTheMultitudes.java
+++ b/Mage.Sets/src/mage/cards/m/MarchOfTheMultitudes.java
@@ -24,7 +24,7 @@ public final class MarchOfTheMultitudes extends CardImpl {
// Create X 1/1 white Soldier creature tokens with lifelink.
this.getSpellAbility().addEffect(new CreateTokenEffect(
new SoldierLifelinkToken(),
- ManacostVariableValue.instance
+ ManacostVariableValue.REGULAR
));
}
diff --git a/Mage.Sets/src/mage/cards/m/MeteorShower.java b/Mage.Sets/src/mage/cards/m/MeteorShower.java
index 9054e3091c..5d2955a540 100644
--- a/Mage.Sets/src/mage/cards/m/MeteorShower.java
+++ b/Mage.Sets/src/mage/cards/m/MeteorShower.java
@@ -21,7 +21,7 @@ public final class MeteorShower extends CardImpl {
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.
- DynamicValue xValue = new IntPlusDynamicValue(1, ManacostVariableValue.instance);
+ DynamicValue xValue = new IntPlusDynamicValue(1, ManacostVariableValue.REGULAR);
this.getSpellAbility().addEffect(new DamageMultiEffect(xValue));
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(xValue));
}
diff --git a/Mage.Sets/src/mage/cards/m/MindShatter.java b/Mage.Sets/src/mage/cards/m/MindShatter.java
index 411b3ffd95..788a955021 100644
--- a/Mage.Sets/src/mage/cards/m/MindShatter.java
+++ b/Mage.Sets/src/mage/cards/m/MindShatter.java
@@ -19,7 +19,7 @@ public final class MindShatter extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{B}{B}");
// Target player discards X cards at random.
- this.getSpellAbility().addEffect(new DiscardTargetEffect(ManacostVariableValue.instance, true));
+ this.getSpellAbility().addEffect(new DiscardTargetEffect(ManacostVariableValue.REGULAR, true));
this.getSpellAbility().addTarget(new TargetPlayer());
}
diff --git a/Mage.Sets/src/mage/cards/m/MindSpring.java b/Mage.Sets/src/mage/cards/m/MindSpring.java
index aebc129e15..fa71768f05 100644
--- a/Mage.Sets/src/mage/cards/m/MindSpring.java
+++ b/Mage.Sets/src/mage/cards/m/MindSpring.java
@@ -18,7 +18,7 @@ public final class MindSpring extends CardImpl {
public MindSpring(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{U}{U}");
- this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.REGULAR));
}
private MindSpring(final MindSpring card) {
diff --git a/Mage.Sets/src/mage/cards/m/MindTwist.java b/Mage.Sets/src/mage/cards/m/MindTwist.java
index f13a3618de..c38398af0d 100644
--- a/Mage.Sets/src/mage/cards/m/MindTwist.java
+++ b/Mage.Sets/src/mage/cards/m/MindTwist.java
@@ -20,7 +20,7 @@ public final class MindTwist extends CardImpl {
// Target player discards X cards at random.
- this.getSpellAbility().addEffect(new DiscardTargetEffect(ManacostVariableValue.instance, true));
+ this.getSpellAbility().addEffect(new DiscardTargetEffect(ManacostVariableValue.REGULAR, true));
this.getSpellAbility().addTarget(new TargetPlayer());
}
diff --git a/Mage.Sets/src/mage/cards/m/Mindswipe.java b/Mage.Sets/src/mage/cards/m/Mindswipe.java
index 235c24a2a9..77d713b486 100644
--- a/Mage.Sets/src/mage/cards/m/Mindswipe.java
+++ b/Mage.Sets/src/mage/cards/m/Mindswipe.java
@@ -28,7 +28,7 @@ public final class Mindswipe extends CardImpl {
// Counter target spell unless its controller pays {X}. Mindswipe deals X damage to that spell's controller.
- Effect effect = new CounterUnlessPaysEffect(ManacostVariableValue.instance);
+ Effect effect = new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR);
effect.setText("Counter target spell unless its controller pays {X}.");
this.getSpellAbility().addEffect(effect);
this.getSpellAbility().addTarget(new TargetSpell());
@@ -73,7 +73,7 @@ class MindswipeEffect extends OneShotEffect {
Spell spell = (Spell) object;
Player spellController = game.getPlayer(spell.getControllerId());
if (spellController != null) {
- int damage = ManacostVariableValue.instance.calculate(game, source, this);
+ int damage = ManacostVariableValue.REGULAR.calculate(game, source, this);
spellController.damage(damage, source.getSourceId(), source, game);
}
return true;
diff --git a/Mage.Sets/src/mage/cards/m/MirrorEntity.java b/Mage.Sets/src/mage/cards/m/MirrorEntity.java
index 729ca2a08e..b4a1f25e68 100644
--- a/Mage.Sets/src/mage/cards/m/MirrorEntity.java
+++ b/Mage.Sets/src/mage/cards/m/MirrorEntity.java
@@ -36,7 +36,7 @@ public final class MirrorEntity extends CardImpl {
// {X}: Until end of turn, creatures you control have base power and toughness X/X and gain all creature types.
Ability ability = new SimpleActivatedAbility(new SetPowerToughnessAllEffect(
- ManacostVariableValue.instance, ManacostVariableValue.instance,
+ ManacostVariableValue.REGULAR, ManacostVariableValue.REGULAR,
Duration.EndOfTurn, StaticFilters.FILTER_CONTROLLED_CREATURES, true
).setText("Until end of turn, creatures you control have base power and toughness X/X"), new VariableManaCost());
ability.addEffect(new MirrorEntityEffect());
diff --git a/Mage.Sets/src/mage/cards/m/Molder.java b/Mage.Sets/src/mage/cards/m/Molder.java
index 0302c2e383..a4f80e6031 100644
--- a/Mage.Sets/src/mage/cards/m/Molder.java
+++ b/Mage.Sets/src/mage/cards/m/Molder.java
@@ -28,7 +28,7 @@ public final class Molder extends CardImpl {
// Destroy target artifact or enchantment with converted mana cost X. It can't be regenerated. You gain X life.
this.getSpellAbility().addEffect(new DestroyTargetEffect("Destroy target artifact or enchantment with mana value X", true));
- this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().setTargetAdjuster(MolderAdjuster.instance);
}
diff --git a/Mage.Sets/src/mage/cards/n/NecropolisFiend.java b/Mage.Sets/src/mage/cards/n/NecropolisFiend.java
index 59c347163c..f7d666275c 100644
--- a/Mage.Sets/src/mage/cards/n/NecropolisFiend.java
+++ b/Mage.Sets/src/mage/cards/n/NecropolisFiend.java
@@ -53,7 +53,7 @@ public final class NecropolisFiend extends CardImpl {
this.addAbility(FlyingAbility.getInstance());
// {X}, {T}, Exile X cards from your graveyard: Target creature gets -X/-X until end of turn.
- DynamicValue xValue = new SignInversionDynamicValue(ManacostVariableValue.instance);
+ DynamicValue xValue = new SignInversionDynamicValue(ManacostVariableValue.REGULAR);
Effect effect = new BoostTargetEffect(xValue, xValue, Duration.EndOfTurn);
effect.setText("Target creature gets -X/-X until end of turn");
Ability ability = new SimpleActivatedAbility(
diff --git a/Mage.Sets/src/mage/cards/n/NikoAris.java b/Mage.Sets/src/mage/cards/n/NikoAris.java
index c43af1c828..5f2871f4b5 100644
--- a/Mage.Sets/src/mage/cards/n/NikoAris.java
+++ b/Mage.Sets/src/mage/cards/n/NikoAris.java
@@ -56,7 +56,7 @@ public final class NikoAris extends CardImpl {
// When Niko Aris enters the battlefield, create X Shard tokens.
this.addAbility(new EntersBattlefieldTriggeredAbility(
- new CreateTokenEffect(new ShardToken(), ManacostVariableValue.instance)
+ new CreateTokenEffect(new ShardToken(), ManacostVariableValue.ETB)
));
// +1: Up to one target creature you control can't be blocked this turn. Whenever that creature deals damage this turn, return it to its owner's hand.
diff --git a/Mage.Sets/src/mage/cards/n/NyleasIntervention.java b/Mage.Sets/src/mage/cards/n/NyleasIntervention.java
index ce5df91be8..4ab142f94f 100644
--- a/Mage.Sets/src/mage/cards/n/NyleasIntervention.java
+++ b/Mage.Sets/src/mage/cards/n/NyleasIntervention.java
@@ -33,7 +33,7 @@ public final class NyleasIntervention extends CardImpl {
filter.add(new AbilityPredicate(FlyingAbility.class));
}
- private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.instance, 2);
+ private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.REGULAR, 2);
public NyleasIntervention(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{G}{G}");
diff --git a/Mage.Sets/src/mage/cards/o/OracleOfNectars.java b/Mage.Sets/src/mage/cards/o/OracleOfNectars.java
index 52c8fa15f4..02a5ef8b61 100644
--- a/Mage.Sets/src/mage/cards/o/OracleOfNectars.java
+++ b/Mage.Sets/src/mage/cards/o/OracleOfNectars.java
@@ -30,7 +30,7 @@ public final class OracleOfNectars extends CardImpl {
this.toughness = new MageInt(2);
// {X}, {tap}: You gain X life.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}"));
ability.addCost(new TapSourceCost());
this.addAbility(ability);
}
diff --git a/Mage.Sets/src/mage/cards/o/Overrule.java b/Mage.Sets/src/mage/cards/o/Overrule.java
index 39c24d3b43..e2e0852c6f 100644
--- a/Mage.Sets/src/mage/cards/o/Overrule.java
+++ b/Mage.Sets/src/mage/cards/o/Overrule.java
@@ -20,11 +20,11 @@ public final class Overrule extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{W}{U}");
// Counter target spell unless its controller pays {X}.
- this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetSpell());
// You gain X life.
- this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR));
}
private Overrule(final Overrule card) {
diff --git a/Mage.Sets/src/mage/cards/p/PainKami.java b/Mage.Sets/src/mage/cards/p/PainKami.java
index f8e26b1f82..346ed33124 100644
--- a/Mage.Sets/src/mage/cards/p/PainKami.java
+++ b/Mage.Sets/src/mage/cards/p/PainKami.java
@@ -28,7 +28,7 @@ public final class PainKami extends CardImpl {
this.power = new MageInt(2);
this.toughness = new MageInt(2);
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}{R}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{R}"));
ability.addCost(new SacrificeSourceCost());
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/p/Panacea.java b/Mage.Sets/src/mage/cards/p/Panacea.java
index 5e0c23700d..33ca81d303 100644
--- a/Mage.Sets/src/mage/cards/p/Panacea.java
+++ b/Mage.Sets/src/mage/cards/p/Panacea.java
@@ -25,7 +25,7 @@ public final class Panacea extends CardImpl {
// {X}{X}, {tap}: Prevent the next X damage that would be dealt to any target this turn.
Ability ability = new SimpleActivatedAbility(
- new PreventDamageToTargetEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.instance),
+ new PreventDamageToTargetEffect(Duration.EndOfTurn, false, true, ManacostVariableValue.REGULAR),
new ManaCostsImpl("{X}{X}")
);
ability.addCost(new TapSourceCost());
diff --git a/Mage.Sets/src/mage/cards/p/PestInfestation.java b/Mage.Sets/src/mage/cards/p/PestInfestation.java
index 84843fa58f..7d58c42efd 100644
--- a/Mage.Sets/src/mage/cards/p/PestInfestation.java
+++ b/Mage.Sets/src/mage/cards/p/PestInfestation.java
@@ -22,7 +22,7 @@ import java.util.UUID;
*/
public final class PestInfestation extends CardImpl {
- private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.instance, 2);
+ private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.REGULAR, 2);
public PestInfestation(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{G}");
diff --git a/Mage.Sets/src/mage/cards/p/PrimalMight.java b/Mage.Sets/src/mage/cards/p/PrimalMight.java
index 975933c0dc..8e73d8ffb4 100644
--- a/Mage.Sets/src/mage/cards/p/PrimalMight.java
+++ b/Mage.Sets/src/mage/cards/p/PrimalMight.java
@@ -25,7 +25,7 @@ public final class PrimalMight extends CardImpl {
// Target creature you control gets +X/+X until end of turn. Then it fights up to one target creature you don’t control.
this.getSpellAbility().addTarget(new TargetControlledCreaturePermanent());
- this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.instance, ManacostVariableValue.instance, Duration.EndOfTurn));
+ this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.REGULAR, ManacostVariableValue.REGULAR, Duration.EndOfTurn));
//
this.getSpellAbility().addEffect(new FightTargetsEffect()
.concatBy("Then")
diff --git a/Mage.Sets/src/mage/cards/p/ProfaneCommand.java b/Mage.Sets/src/mage/cards/p/ProfaneCommand.java
index 04d7d0ce49..c574c92634 100644
--- a/Mage.Sets/src/mage/cards/p/ProfaneCommand.java
+++ b/Mage.Sets/src/mage/cards/p/ProfaneCommand.java
@@ -37,7 +37,7 @@ public final class ProfaneCommand extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{B}{B}");
- DynamicValue xValue = ManacostVariableValue.instance;
+ DynamicValue xValue = ManacostVariableValue.REGULAR;
// Choose two -
this.getSpellAbility().getModes().setMinModes(2);
this.getSpellAbility().getModes().setMaxModes(2);
diff --git a/Mage.Sets/src/mage/cards/p/Prosperity.java b/Mage.Sets/src/mage/cards/p/Prosperity.java
index db292793d3..2224a6fe89 100644
--- a/Mage.Sets/src/mage/cards/p/Prosperity.java
+++ b/Mage.Sets/src/mage/cards/p/Prosperity.java
@@ -19,7 +19,7 @@ public final class Prosperity extends CardImpl {
// Each player draws X cards.
- this.getSpellAbility().addEffect(new DrawCardAllEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardAllEffect(ManacostVariableValue.REGULAR));
}
private Prosperity(final Prosperity card) {
diff --git a/Mage.Sets/src/mage/cards/p/PsychicDrain.java b/Mage.Sets/src/mage/cards/p/PsychicDrain.java
index 9ca99ae2ea..fc2ca735fa 100644
--- a/Mage.Sets/src/mage/cards/p/PsychicDrain.java
+++ b/Mage.Sets/src/mage/cards/p/PsychicDrain.java
@@ -21,9 +21,9 @@ public final class PsychicDrain extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{U}{B}");
// Target player puts the top X cards of their library into their graveyard and you gain X life.
- this.getSpellAbility().addEffect(new PutLibraryIntoGraveTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new PutLibraryIntoGraveTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetPlayer());
- Effect effect = new GainLifeEffect(ManacostVariableValue.instance);
+ Effect effect = new GainLifeEffect(ManacostVariableValue.REGULAR);
effect.setText("and you gain X life");
this.getSpellAbility().addEffect(effect);
}
diff --git a/Mage.Sets/src/mage/cards/p/PullFromTomorrow.java b/Mage.Sets/src/mage/cards/p/PullFromTomorrow.java
index 5b8169fff2..300caf7313 100644
--- a/Mage.Sets/src/mage/cards/p/PullFromTomorrow.java
+++ b/Mage.Sets/src/mage/cards/p/PullFromTomorrow.java
@@ -20,7 +20,7 @@ public final class PullFromTomorrow extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{U}{U}");
// Draw X cards, then discard a card.
- getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.instance));
+ getSpellAbility().addEffect(new DrawCardSourceControllerEffect(ManacostVariableValue.REGULAR));
Effect effect = new DiscardControllerEffect(1);
effect.setText(", then discard a card");
getSpellAbility().addEffect(effect);
diff --git a/Mage.Sets/src/mage/cards/p/PurphorossIntervention.java b/Mage.Sets/src/mage/cards/p/PurphorossIntervention.java
index 2fa4e46794..78b9ebb945 100644
--- a/Mage.Sets/src/mage/cards/p/PurphorossIntervention.java
+++ b/Mage.Sets/src/mage/cards/p/PurphorossIntervention.java
@@ -26,7 +26,7 @@ import java.util.UUID;
*/
public final class PurphorossIntervention extends CardImpl {
- private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.instance, 2);
+ private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.REGULAR, 2);
public PurphorossIntervention(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{R}");
diff --git a/Mage.Sets/src/mage/cards/r/RadiantEpicure.java b/Mage.Sets/src/mage/cards/r/RadiantEpicure.java
index 5da5d1862c..0412ca0ff6 100644
--- a/Mage.Sets/src/mage/cards/r/RadiantEpicure.java
+++ b/Mage.Sets/src/mage/cards/r/RadiantEpicure.java
@@ -67,11 +67,11 @@ class RadiantEpicureEffect extends OneShotEffect {
@Override
public boolean apply(Game game, Ability source) {
Player player = game.getPlayer(source.getControllerId());
- ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class, source.getSourceId());
+ ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class);
if (player == null || watcher == null) {
return false;
}
- Mana payment = watcher.getAndResetLastPayment();
+ Mana payment = watcher.getAndResetLastPayment(source.getSourceId());
if (payment == null) {
return false;
}
diff --git a/Mage.Sets/src/mage/cards/r/RakdossReturn.java b/Mage.Sets/src/mage/cards/r/RakdossReturn.java
index b999ce1958..7a1ec1e151 100644
--- a/Mage.Sets/src/mage/cards/r/RakdossReturn.java
+++ b/Mage.Sets/src/mage/cards/r/RakdossReturn.java
@@ -27,7 +27,7 @@ public final class RakdossReturn extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{B}{R}");
// Rakdos's Return deals X damage to target opponent or planeswalker. That player or that planeswalker’s controller discards X cards.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addEffect(new RakdossReturnEffect());
this.getSpellAbility().addTarget(new TargetOpponentOrPlaneswalker());
}
@@ -64,7 +64,7 @@ class RakdossReturnEffect extends OneShotEffect {
if (player == null) {
return false;
}
- Effect effect = new DiscardTargetEffect(ManacostVariableValue.instance);
+ Effect effect = new DiscardTargetEffect(ManacostVariableValue.REGULAR);
effect.setTargetPointer(new FixedTarget(player.getId(), game));
return effect.apply(game, source);
}
diff --git a/Mage.Sets/src/mage/cards/r/RavagingBlaze.java b/Mage.Sets/src/mage/cards/r/RavagingBlaze.java
index 852942465a..ecc1bd7950 100644
--- a/Mage.Sets/src/mage/cards/r/RavagingBlaze.java
+++ b/Mage.Sets/src/mage/cards/r/RavagingBlaze.java
@@ -22,10 +22,10 @@ public final class RavagingBlaze extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{R}{R}");
// Ravaging Blaze deals X damage to target creature.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
// Spell mastery — If there are two or more instant and/or sorcery cards in your graveyard, Ravaging Blaze also deals X damage to that creature's controller.
- this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DamageTargetControllerEffect(ManacostVariableValue.instance),
+ this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DamageTargetControllerEffect(ManacostVariableValue.REGULAR),
SpellMasteryCondition.instance, "
Spell mastery — If there are two or more instant and/or sorcery cards in your graveyard, Ravaging Blaze also deals X damage to that creature's controller."));
}
diff --git a/Mage.Sets/src/mage/cards/r/RedSunsZenith.java b/Mage.Sets/src/mage/cards/r/RedSunsZenith.java
index 48733ba1d9..4ddda3619c 100644
--- a/Mage.Sets/src/mage/cards/r/RedSunsZenith.java
+++ b/Mage.Sets/src/mage/cards/r/RedSunsZenith.java
@@ -26,7 +26,7 @@ public final class RedSunsZenith extends CardImpl {
// If a creature dealt damage this way would die this turn, exile it instead.
// Shuffle Red Sun's Zenith into its owner's library.
this.getSpellAbility().addTarget(new TargetAnyTarget());
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addEffect(new DealtDamageToCreatureBySourceDies(this, Duration.EndOfTurn));
this.getSpellAbility().addEffect(ShuffleSpellEffect.getInstance());
this.getSpellAbility().addWatcher(new DamagedByWatcher(false));
diff --git a/Mage.Sets/src/mage/cards/r/ReleaseTheGremlins.java b/Mage.Sets/src/mage/cards/r/ReleaseTheGremlins.java
index 8cf566f507..59a64bc73a 100644
--- a/Mage.Sets/src/mage/cards/r/ReleaseTheGremlins.java
+++ b/Mage.Sets/src/mage/cards/r/ReleaseTheGremlins.java
@@ -28,7 +28,7 @@ public final class ReleaseTheGremlins extends CardImpl {
this.getSpellAbility().addTarget(new TargetArtifactPermanent());
// Create X 2/2 red Gremlin creature tokens.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new GremlinToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new GremlinToken(), ManacostVariableValue.REGULAR));
this.getSpellAbility().setTargetAdjuster(ReleaseTheGremlinsAdjuster.instance);
}
diff --git a/Mage.Sets/src/mage/cards/r/RockSlide.java b/Mage.Sets/src/mage/cards/r/RockSlide.java
index 6a68059f75..10e2125a0b 100644
--- a/Mage.Sets/src/mage/cards/r/RockSlide.java
+++ b/Mage.Sets/src/mage/cards/r/RockSlide.java
@@ -36,7 +36,7 @@ public final class RockSlide extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{R}");
// Rock Slide deals X damage divided as you choose among any number of target attacking or blocking creatures without flying.
- DynamicValue xValue = ManacostVariableValue.instance;
+ DynamicValue xValue = ManacostVariableValue.REGULAR;
this.getSpellAbility().addEffect(new DamageMultiEffect(xValue));
this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(xValue, filter));
}
diff --git a/Mage.Sets/src/mage/cards/r/RollingEarthquake.java b/Mage.Sets/src/mage/cards/r/RollingEarthquake.java
index 9168aacf81..96faf7d321 100644
--- a/Mage.Sets/src/mage/cards/r/RollingEarthquake.java
+++ b/Mage.Sets/src/mage/cards/r/RollingEarthquake.java
@@ -29,7 +29,7 @@ public final class RollingEarthquake extends CardImpl {
// Rolling Earthquake deals X damage to each creature without horsemanship and each player.
- this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.instance, filter));
+ this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.REGULAR, filter));
}
private RollingEarthquake(final RollingEarthquake card) {
diff --git a/Mage.Sets/src/mage/cards/r/RollingThunder.java b/Mage.Sets/src/mage/cards/r/RollingThunder.java
index 7c9ff88338..dcbda74b27 100644
--- a/Mage.Sets/src/mage/cards/r/RollingThunder.java
+++ b/Mage.Sets/src/mage/cards/r/RollingThunder.java
@@ -20,7 +20,7 @@ public final class RollingThunder extends CardImpl {
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.
- DynamicValue xValue = ManacostVariableValue.instance;
+ DynamicValue xValue = ManacostVariableValue.REGULAR;
this.getSpellAbility().addEffect(new DamageMultiEffect(xValue));
this.getSpellAbility().addTarget(new TargetAnyTargetAmount(xValue));
}
diff --git a/Mage.Sets/src/mage/cards/s/SandsOfDelirium.java b/Mage.Sets/src/mage/cards/s/SandsOfDelirium.java
index 205b395962..5cf023e7cb 100644
--- a/Mage.Sets/src/mage/cards/s/SandsOfDelirium.java
+++ b/Mage.Sets/src/mage/cards/s/SandsOfDelirium.java
@@ -25,7 +25,7 @@ public final class SandsOfDelirium extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{3}");
// {X}, {tap}: Target player puts the top X cards of their library into their graveyard.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutLibraryIntoGraveTargetEffect(ManacostVariableValue.instance), new VariableManaCost());
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutLibraryIntoGraveTargetEffect(ManacostVariableValue.REGULAR), new VariableManaCost());
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetPlayer());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/s/SavageTwister.java b/Mage.Sets/src/mage/cards/s/SavageTwister.java
index 6156729324..c7c68e0683 100644
--- a/Mage.Sets/src/mage/cards/s/SavageTwister.java
+++ b/Mage.Sets/src/mage/cards/s/SavageTwister.java
@@ -20,7 +20,7 @@ public final class SavageTwister extends CardImpl {
// Savage Twister deals X damage to each creature.
- this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, new FilterCreaturePermanent()));
+ this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, new FilterCreaturePermanent()));
}
private SavageTwister(final SavageTwister card) {
diff --git a/Mage.Sets/src/mage/cards/s/SealedFate.java b/Mage.Sets/src/mage/cards/s/SealedFate.java
index c5faef0d42..ac53d3c82d 100644
--- a/Mage.Sets/src/mage/cards/s/SealedFate.java
+++ b/Mage.Sets/src/mage/cards/s/SealedFate.java
@@ -22,7 +22,7 @@ public final class SealedFate extends CardImpl {
// Look at the top X cards of target opponent's library. Exile one of those cards and put the rest back on top of that player's library in any order.
this.getSpellAbility().addTarget(new TargetOpponent());
- this.getSpellAbility().addEffect(new LookLibraryAndPickControllerEffect(ManacostVariableValue.instance,
+ this.getSpellAbility().addEffect(new LookLibraryAndPickControllerEffect(ManacostVariableValue.REGULAR,
false, StaticValue.get(1),
new FilterCard("a card to exile"), Zone.LIBRARY, true,
false, false, Zone.EXILED,
diff --git a/Mage.Sets/src/mage/cards/s/SecureTheWastes.java b/Mage.Sets/src/mage/cards/s/SecureTheWastes.java
index 177e941e88..d785c1f354 100644
--- a/Mage.Sets/src/mage/cards/s/SecureTheWastes.java
+++ b/Mage.Sets/src/mage/cards/s/SecureTheWastes.java
@@ -19,7 +19,7 @@ public final class SecureTheWastes extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{W}");
// create X 1/1 white Warrior creature tokens.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new WarriorToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new WarriorToken(), ManacostVariableValue.REGULAR));
}
private SecureTheWastes(final SecureTheWastes card) {
diff --git a/Mage.Sets/src/mage/cards/s/SequenceEngine.java b/Mage.Sets/src/mage/cards/s/SequenceEngine.java
index 675c0b248d..234200fbaa 100644
--- a/Mage.Sets/src/mage/cards/s/SequenceEngine.java
+++ b/Mage.Sets/src/mage/cards/s/SequenceEngine.java
@@ -36,7 +36,7 @@ public final class SequenceEngine extends CardImpl {
);
ability.addCost(new TapSourceCost());
ability.addEffect(QuandrixToken.getEffect(
- ManacostVariableValue.instance, "Put X +1/+1 counters on it"
+ ManacostVariableValue.REGULAR, "Put X +1/+1 counters on it"
));
ability.setTargetAdjuster(SequenceEngineAdjuster.instance);
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/s/ShatteredCrypt.java b/Mage.Sets/src/mage/cards/s/ShatteredCrypt.java
index 3b4b0c3db3..79b955aecc 100644
--- a/Mage.Sets/src/mage/cards/s/ShatteredCrypt.java
+++ b/Mage.Sets/src/mage/cards/s/ShatteredCrypt.java
@@ -29,7 +29,7 @@ public final class ShatteredCrypt extends CardImpl {
Effect effect = new ReturnFromGraveyardToHandTargetEffect();
effect.setText("Return X target creature cards from your graveyard to your hand");
this.getSpellAbility().addEffect(effect);
- this.getSpellAbility().addEffect(new LoseLifeSourceControllerEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new LoseLifeSourceControllerEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().setTargetAdjuster(ShatteredCryptAdjuster.instance);
}
diff --git a/Mage.Sets/src/mage/cards/s/ShatterskullSmashing.java b/Mage.Sets/src/mage/cards/s/ShatterskullSmashing.java
index e5dfa404cb..5bc05b8a63 100644
--- a/Mage.Sets/src/mage/cards/s/ShatterskullSmashing.java
+++ b/Mage.Sets/src/mage/cards/s/ShatterskullSmashing.java
@@ -11,7 +11,6 @@ import mage.abilities.dynamicvalue.common.ManacostVariableValue;
import mage.abilities.effects.common.DamageMultiEffect;
import mage.abilities.effects.common.TapSourceUnlessPaysEffect;
import mage.abilities.mana.RedManaAbility;
-import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.cards.ModalDoubleFacesCard;
import mage.constants.CardType;
@@ -28,7 +27,7 @@ import java.util.UUID;
*/
public final class ShatterskullSmashing extends ModalDoubleFacesCard {
- private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.instance, 2);
+ private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.REGULAR, 2);
public ShatterskullSmashing(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo,
@@ -42,7 +41,7 @@ public final class ShatterskullSmashing extends ModalDoubleFacesCard {
// Shatterskull Smashing deals X damage divided as you choose among up to two target creatures and/or planeswalkers. If X is 6 or more, Shatterskull Smashing deals twice X damage divided as you choose among them instead.
this.getLeftHalfCard().getSpellAbility().addEffect(new ConditionalOneShotEffect(
- new DamageMultiEffect(xValue), new DamageMultiEffect(ManacostVariableValue.instance),
+ new DamageMultiEffect(xValue), new DamageMultiEffect(ManacostVariableValue.REGULAR),
ShatterskullSmashingCondition.instance, "{this} deals X damage divided as you choose " +
"among up to two target creatures and/or planeswalkers. If X is 6 or more, " +
"{this} deals twice X damage divided as you choose among them instead."
diff --git a/Mage.Sets/src/mage/cards/s/SilklashSpider.java b/Mage.Sets/src/mage/cards/s/SilklashSpider.java
index 08ade0efb8..9aec75f8ad 100644
--- a/Mage.Sets/src/mage/cards/s/SilklashSpider.java
+++ b/Mage.Sets/src/mage/cards/s/SilklashSpider.java
@@ -40,7 +40,7 @@ public final class SilklashSpider extends CardImpl {
this.addAbility(ReachAbility.getInstance());
// {X}{G}{G}: Silklash Spider deals X damage to each creature with flying.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD,
- new DamageAllEffect(ManacostVariableValue.instance, filter),
+ new DamageAllEffect(ManacostVariableValue.REGULAR, filter),
new ManaCostsImpl("{X}{G}{G}")));
}
diff --git a/Mage.Sets/src/mage/cards/s/SkeletalScrying.java b/Mage.Sets/src/mage/cards/s/SkeletalScrying.java
index 37ac388198..3c935af953 100644
--- a/Mage.Sets/src/mage/cards/s/SkeletalScrying.java
+++ b/Mage.Sets/src/mage/cards/s/SkeletalScrying.java
@@ -39,10 +39,10 @@ public final class SkeletalScrying extends CardImpl {
// You draw X cards and you lose X life.
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(
- ManacostVariableValue.instance
+ ManacostVariableValue.REGULAR
).setText("you draw X cards"));
this.getSpellAbility().addEffect(new GainLifeEffect(
- ManacostVariableValue.instance
+ ManacostVariableValue.REGULAR
).concatBy("and"));
}
diff --git a/Mage.Sets/src/mage/cards/s/Skyscribing.java b/Mage.Sets/src/mage/cards/s/Skyscribing.java
index 557df37fbe..347be5f679 100644
--- a/Mage.Sets/src/mage/cards/s/Skyscribing.java
+++ b/Mage.Sets/src/mage/cards/s/Skyscribing.java
@@ -20,7 +20,7 @@ public final class Skyscribing extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{U}{U}");
// Each player draws X cards.
- this.getSpellAbility().addEffect(new DrawCardAllEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardAllEffect(ManacostVariableValue.REGULAR));
// Forecast - {2}{U}, Reveal Skyscribing from your hand: Each player draws a card.
this.addAbility(new ForecastAbility(new DrawCardAllEffect(1), new ManaCostsImpl("{2}{U}")));
}
diff --git a/Mage.Sets/src/mage/cards/s/SnakeBasket.java b/Mage.Sets/src/mage/cards/s/SnakeBasket.java
index 46531879c9..6e794b0bdb 100644
--- a/Mage.Sets/src/mage/cards/s/SnakeBasket.java
+++ b/Mage.Sets/src/mage/cards/s/SnakeBasket.java
@@ -25,7 +25,7 @@ public final class SnakeBasket extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{4}");
// {X}, Sacrifice Snake Basket: create X 1/1 green Snake creature tokens. Activate this ability only any time you could cast a sorcery.
- Effect effect = new CreateTokenEffect(new SnakeToken(), ManacostVariableValue.instance);
+ Effect effect = new CreateTokenEffect(new SnakeToken(), ManacostVariableValue.REGULAR);
Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{X}"));
ability.addCost(new SacrificeSourceCost());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/s/Soothsaying.java b/Mage.Sets/src/mage/cards/s/Soothsaying.java
index e1387e6679..99ac952642 100644
--- a/Mage.Sets/src/mage/cards/s/Soothsaying.java
+++ b/Mage.Sets/src/mage/cards/s/Soothsaying.java
@@ -27,7 +27,7 @@ public final class Soothsaying extends CardImpl {
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ShuffleLibrarySourceEffect(), new ManaCostsImpl<>("{3}{U}{U}")));
// {X}: Look at the top X cards of your library, then put them back in any order.
- Effect effect = new LookLibraryControllerEffect(ManacostVariableValue.instance);
+ Effect effect = new LookLibraryControllerEffect(ManacostVariableValue.REGULAR);
effect.setText("Look at the top X cards of your library, then put them back in any order");
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl<>("X")));
}
diff --git a/Mage.Sets/src/mage/cards/s/SoulStrings.java b/Mage.Sets/src/mage/cards/s/SoulStrings.java
index cbc51a7438..2dc59f32de 100644
--- a/Mage.Sets/src/mage/cards/s/SoulStrings.java
+++ b/Mage.Sets/src/mage/cards/s/SoulStrings.java
@@ -23,7 +23,7 @@ public final class SoulStrings extends CardImpl {
// Return two target creature cards from your graveyard to your hand unless any player pays {X}.
Effect effect = new DoUnlessAnyPlayerPaysEffect(
- new ReturnFromGraveyardToHandTargetEffect(), ManacostVariableValue.instance);
+ new ReturnFromGraveyardToHandTargetEffect(), ManacostVariableValue.REGULAR);
this.getSpellAbility().addEffect(effect);
this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(2, new FilterCreatureCard("creature cards from your graveyard")));
}
diff --git a/Mage.Sets/src/mage/cards/s/SphinxsRevelation.java b/Mage.Sets/src/mage/cards/s/SphinxsRevelation.java
index 9a982e8c06..2deef801c4 100644
--- a/Mage.Sets/src/mage/cards/s/SphinxsRevelation.java
+++ b/Mage.Sets/src/mage/cards/s/SphinxsRevelation.java
@@ -21,7 +21,7 @@ public final class SphinxsRevelation extends CardImpl {
// You gain X life and draw X cards.
- ManacostVariableValue manaX = ManacostVariableValue.instance;
+ ManacostVariableValue manaX = ManacostVariableValue.REGULAR;
this.getSpellAbility().addEffect(new GainLifeEffect(manaX));
this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(manaX));
}
diff --git a/Mage.Sets/src/mage/cards/s/SquallLine.java b/Mage.Sets/src/mage/cards/s/SquallLine.java
index 21dd0371b4..b6e5749c47 100644
--- a/Mage.Sets/src/mage/cards/s/SquallLine.java
+++ b/Mage.Sets/src/mage/cards/s/SquallLine.java
@@ -27,7 +27,7 @@ public final class SquallLine extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{G}{G}");
// Squall Line deals X damage to each creature with flying and each player.
- this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.instance, filter)); }
+ this.getSpellAbility().addEffect(new DamageEverythingEffect(ManacostVariableValue.REGULAR, filter)); }
private SquallLine(final SquallLine card) {
super(card);
diff --git a/Mage.Sets/src/mage/cards/s/StarnheimUnleashed.java b/Mage.Sets/src/mage/cards/s/StarnheimUnleashed.java
index 01b4e34aee..97030d2990 100644
--- a/Mage.Sets/src/mage/cards/s/StarnheimUnleashed.java
+++ b/Mage.Sets/src/mage/cards/s/StarnheimUnleashed.java
@@ -23,7 +23,7 @@ public final class StarnheimUnleashed extends CardImpl {
// Create a 4/4 white Angel Warrior creature token with flying and vigilance. If this spell was foretold, create X of those tokens instead.
this.getSpellAbility().addEffect(new ConditionalOneShotEffect(
- new CreateTokenEffect(new AngelWarriorVigilanceToken(), ManacostVariableValue.instance),
+ new CreateTokenEffect(new AngelWarriorVigilanceToken(), ManacostVariableValue.REGULAR),
new CreateTokenEffect(new AngelWarriorVigilanceToken()),
ForetoldCondition.instance,
"Create a 4/4 white Angel Warrior creature token with flying and vigilance. If this spell was foretold, create X of those tokens instead"
diff --git a/Mage.Sets/src/mage/cards/s/Starstorm.java b/Mage.Sets/src/mage/cards/s/Starstorm.java
index fe4a5c64d3..cd076d518c 100644
--- a/Mage.Sets/src/mage/cards/s/Starstorm.java
+++ b/Mage.Sets/src/mage/cards/s/Starstorm.java
@@ -22,7 +22,7 @@ public final class Starstorm extends CardImpl {
// Starstorm deals X damage to each creature.
- this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, new FilterCreaturePermanent()));
+ this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, new FilterCreaturePermanent()));
// Cycling {3}
this.addAbility(new CyclingAbility(new ManaCostsImpl("{3}")));
}
diff --git a/Mage.Sets/src/mage/cards/s/StolenByTheFae.java b/Mage.Sets/src/mage/cards/s/StolenByTheFae.java
index 9f3dc2733d..0c9814f37d 100644
--- a/Mage.Sets/src/mage/cards/s/StolenByTheFae.java
+++ b/Mage.Sets/src/mage/cards/s/StolenByTheFae.java
@@ -28,7 +28,7 @@ public final class StolenByTheFae extends CardImpl {
// Return target creature with converted mana cost X to its owner's hand. You create X 1/1 blue Faerie creature tokens with flying.
this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()
.setText("Return target creature with mana value X to its owner's hand"));
- this.getSpellAbility().addEffect(new CreateTokenEffect(new FaerieToken(), ManacostVariableValue.instance)
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new FaerieToken(), ManacostVariableValue.REGULAR)
.setText("You create X 1/1 blue Faerie creature tokens with flying"));
this.getSpellAbility().setTargetAdjuster(StolenByTheFaeAdjuster.instance);
}
diff --git a/Mage.Sets/src/mage/cards/s/StreamOfLife.java b/Mage.Sets/src/mage/cards/s/StreamOfLife.java
index 751ef56fa4..53445c0519 100644
--- a/Mage.Sets/src/mage/cards/s/StreamOfLife.java
+++ b/Mage.Sets/src/mage/cards/s/StreamOfLife.java
@@ -20,7 +20,7 @@ public final class StreamOfLife extends CardImpl {
// Target player gains X life.
- this.getSpellAbility().addEffect(new GainLifeTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new GainLifeTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetPlayer());
}
diff --git a/Mage.Sets/src/mage/cards/s/StreetSpasm.java b/Mage.Sets/src/mage/cards/s/StreetSpasm.java
index 480c0861e5..a14e0760a2 100644
--- a/Mage.Sets/src/mage/cards/s/StreetSpasm.java
+++ b/Mage.Sets/src/mage/cards/s/StreetSpasm.java
@@ -36,10 +36,10 @@ public final class StreetSpasm extends CardImpl {
// Street Spasm deals X damage to target creature without flying you don't control.
this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter));
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
// Overload {X}{X}{R}{R} (You may cast this spell for its overload cost. If you do, change its text by replacing all instances of "target" with "each.")
- this.addAbility(new OverloadAbility(this, new DamageAllEffect(ManacostVariableValue.instance, filter), new ManaCostsImpl("{X}{X}{R}{R}")));
+ this.addAbility(new OverloadAbility(this, new DamageAllEffect(ManacostVariableValue.REGULAR, filter), new ManaCostsImpl("{X}{X}{R}{R}")));
}
private StreetSpasm(final StreetSpasm card) {
diff --git a/Mage.Sets/src/mage/cards/s/StrokeOfGenius.java b/Mage.Sets/src/mage/cards/s/StrokeOfGenius.java
index 8effb65627..6f609a823f 100644
--- a/Mage.Sets/src/mage/cards/s/StrokeOfGenius.java
+++ b/Mage.Sets/src/mage/cards/s/StrokeOfGenius.java
@@ -21,7 +21,7 @@ public final class StrokeOfGenius extends CardImpl {
// Target player draws X cards.
- this.getSpellAbility().addEffect(new DrawCardTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DrawCardTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetPlayer());
}
diff --git a/Mage.Sets/src/mage/cards/s/StumpsquallHydra.java b/Mage.Sets/src/mage/cards/s/StumpsquallHydra.java
index 7bde96ae95..110ae1ffab 100644
--- a/Mage.Sets/src/mage/cards/s/StumpsquallHydra.java
+++ b/Mage.Sets/src/mage/cards/s/StumpsquallHydra.java
@@ -91,7 +91,7 @@ class StumpsquallHydraEffect extends OneShotEffect {
@Override
public boolean apply(Game game, Ability source) {
Player player = game.getPlayer(source.getControllerId());
- int xValue = ManacostVariableValue.instance.calculate(game, source, this);
+ int xValue = ManacostVariableValue.ETB.calculate(game, source, this);
if (player == null || xValue < 1) {
return false;
}
diff --git a/Mage.Sets/src/mage/cards/s/SupplyDemand.java b/Mage.Sets/src/mage/cards/s/SupplyDemand.java
index b41bcf35e3..b3faf81543 100644
--- a/Mage.Sets/src/mage/cards/s/SupplyDemand.java
+++ b/Mage.Sets/src/mage/cards/s/SupplyDemand.java
@@ -31,7 +31,7 @@ public final class SupplyDemand extends SplitCard {
// Supply
// create X 1/1 green Saproling creature tokens.
- getLeftHalfCard().getSpellAbility().addEffect(new CreateTokenEffect(new SaprolingToken(), ManacostVariableValue.instance));
+ getLeftHalfCard().getSpellAbility().addEffect(new CreateTokenEffect(new SaprolingToken(), ManacostVariableValue.REGULAR));
// Demand
// Search your library for a multicolored card, reveal it, and put it into your hand. Then shuffle your library.
diff --git a/Mage.Sets/src/mage/cards/s/SwallowingPlague.java b/Mage.Sets/src/mage/cards/s/SwallowingPlague.java
index 7392aca66b..32a6c926df 100644
--- a/Mage.Sets/src/mage/cards/s/SwallowingPlague.java
+++ b/Mage.Sets/src/mage/cards/s/SwallowingPlague.java
@@ -23,8 +23,8 @@ public final class SwallowingPlague extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{B}{B}");
this.subtype.add(SubType.ARCANE);
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
- this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
+ this.getSpellAbility().addEffect(new GainLifeEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
}
diff --git a/Mage.Sets/src/mage/cards/s/SwellOfCourage.java b/Mage.Sets/src/mage/cards/s/SwellOfCourage.java
index f30ffe85e4..3b1980287c 100644
--- a/Mage.Sets/src/mage/cards/s/SwellOfCourage.java
+++ b/Mage.Sets/src/mage/cards/s/SwellOfCourage.java
@@ -24,7 +24,7 @@ public final class SwellOfCourage extends CardImpl {
// Creatures you control get +2/+2 until end of turn.
this.getSpellAbility().addEffect(new BoostControlledEffect(2,2, Duration.EndOfTurn));
// Reinforce X-{X}{W}{W}
- this.addAbility(new ReinforceAbility(ManacostVariableValue.instance, new ManaCostsImpl("{X}{W}{W}")));
+ this.addAbility(new ReinforceAbility(ManacostVariableValue.REGULAR, new ManaCostsImpl("{X}{W}{W}")));
}
private SwellOfCourage(final SwellOfCourage card) {
diff --git a/Mage.Sets/src/mage/cards/s/Syncopate.java b/Mage.Sets/src/mage/cards/s/Syncopate.java
index b206e221c1..fd0b687d58 100644
--- a/Mage.Sets/src/mage/cards/s/Syncopate.java
+++ b/Mage.Sets/src/mage/cards/s/Syncopate.java
@@ -18,7 +18,7 @@ public final class Syncopate extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{U}");
// Counter target spell unless its controller pays {X}. If that spell is countered this way, exile it instead of putting it into its owner's graveyard.
- this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.instance, true));
+ this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR, true));
this.getSpellAbility().addTarget(new TargetSpell());
}
diff --git a/Mage.Sets/src/mage/cards/t/TalonOfPain.java b/Mage.Sets/src/mage/cards/t/TalonOfPain.java
index bc2017bc02..5c4459213d 100644
--- a/Mage.Sets/src/mage/cards/t/TalonOfPain.java
+++ b/Mage.Sets/src/mage/cards/t/TalonOfPain.java
@@ -42,7 +42,7 @@ public final class TalonOfPain extends CardImpl {
this.addAbility(new TalonOfPainTriggeredAbility());
// {X}, {T}, Remove X charge counters from Talon of Pain: Talon of Pain deals X damage to any target.
- Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}"));
+ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}"));
ability.addCost(new TapSourceCost());
ability.addCost(new TalonOfPainRemoveVariableCountersSourceCost(CounterType.CHARGE.createInstance()));
ability.addTarget(new TargetAnyTarget());
diff --git a/Mage.Sets/src/mage/cards/t/TectonicBreak.java b/Mage.Sets/src/mage/cards/t/TectonicBreak.java
index f4d81448be..b77a65f441 100644
--- a/Mage.Sets/src/mage/cards/t/TectonicBreak.java
+++ b/Mage.Sets/src/mage/cards/t/TectonicBreak.java
@@ -19,7 +19,7 @@ public final class TectonicBreak extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{R}{R}");
// Each player sacrifices X lands.
- this.getSpellAbility().addEffect(new SacrificeAllEffect(ManacostVariableValue.instance, new FilterControlledLandPermanent("lands")));
+ this.getSpellAbility().addEffect(new SacrificeAllEffect(ManacostVariableValue.REGULAR, new FilterControlledLandPermanent("lands")));
}
private TectonicBreak(final TectonicBreak card) {
diff --git a/Mage.Sets/src/mage/cards/t/Temper.java b/Mage.Sets/src/mage/cards/t/Temper.java
index d1a16b0948..3da8be7fe1 100644
--- a/Mage.Sets/src/mage/cards/t/Temper.java
+++ b/Mage.Sets/src/mage/cards/t/Temper.java
@@ -28,7 +28,7 @@ public final class Temper extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{1}{W}");
// Prevent the next X damage that would be dealt to target creature this turn. For each 1 damage prevented this way, put a +1/+1 counter on that creature.
- this.getSpellAbility().addEffect(new TemperPreventDamageTargetEffect(ManacostVariableValue.instance, Duration.EndOfTurn));
+ this.getSpellAbility().addEffect(new TemperPreventDamageTargetEffect(ManacostVariableValue.REGULAR, Duration.EndOfTurn));
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
}
diff --git a/Mage.Sets/src/mage/cards/t/TestamentOfFaith.java b/Mage.Sets/src/mage/cards/t/TestamentOfFaith.java
index f83ca07fd7..c0178b34c6 100644
--- a/Mage.Sets/src/mage/cards/t/TestamentOfFaith.java
+++ b/Mage.Sets/src/mage/cards/t/TestamentOfFaith.java
@@ -26,7 +26,7 @@ public final class TestamentOfFaith extends CardImpl {
// {X}: Testament of Faith becomes an X/X Wall creature with defender in addition to its other types until end of turn.
Ability ability = new SimpleActivatedAbility(new SetPowerToughnessSourceEffect(
- ManacostVariableValue.instance, Duration.EndOfTurn, SubLayer.SetPT_7b
+ ManacostVariableValue.REGULAR, Duration.EndOfTurn, SubLayer.SetPT_7b
).setText("{this} becomes an X/X"), new VariableManaCost());
ability.addEffect(new TestamentOfFaithEffect());
ability.addEffect(new GainAbilitySourceEffect(
diff --git a/Mage.Sets/src/mage/cards/t/ThassasIntervention.java b/Mage.Sets/src/mage/cards/t/ThassasIntervention.java
index 659b03fb77..1f9db130bc 100644
--- a/Mage.Sets/src/mage/cards/t/ThassasIntervention.java
+++ b/Mage.Sets/src/mage/cards/t/ThassasIntervention.java
@@ -21,7 +21,7 @@ import java.util.UUID;
*/
public final class ThassasIntervention extends CardImpl {
- private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.instance, 2);
+ private static final DynamicValue xValue = new MultipliedValue(ManacostVariableValue.REGULAR, 2);
public ThassasIntervention(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{U}{U}");
@@ -29,7 +29,7 @@ public final class ThassasIntervention extends CardImpl {
// Choose one-
// • Look at the top X cards of your library. Put up to two of them into your hand and the rest on the bottom of your library in a random order.
this.getSpellAbility().addEffect(new LookLibraryAndPickControllerEffect(
- ManacostVariableValue.instance, false, StaticValue.get(2),
+ ManacostVariableValue.REGULAR, false, StaticValue.get(2),
StaticFilters.FILTER_CARD, Zone.LIBRARY, false, false,
true, Zone.HAND, true, false, false
).setBackInRandomOrder(true).setText(
diff --git a/Mage.Sets/src/mage/cards/t/TheBattleOfEndor.java b/Mage.Sets/src/mage/cards/t/TheBattleOfEndor.java
index e92374d880..672fb6e33c 100644
--- a/Mage.Sets/src/mage/cards/t/TheBattleOfEndor.java
+++ b/Mage.Sets/src/mage/cards/t/TheBattleOfEndor.java
@@ -32,7 +32,7 @@ public final class TheBattleOfEndor extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.SORCERY},"{X}{X}{G}{G}{G}");
// Create X 1/1 green Ewok creature tokens.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new EwokToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new EwokToken(), ManacostVariableValue.REGULAR));
// Put X +1/+1 counters on each creature you control.
this.getSpellAbility().addEffect(new TheBattleOfEndorEffect());
diff --git a/Mage.Sets/src/mage/cards/t/TheBattleOfGeonosis.java b/Mage.Sets/src/mage/cards/t/TheBattleOfGeonosis.java
index 922da803eb..df6181cf99 100644
--- a/Mage.Sets/src/mage/cards/t/TheBattleOfGeonosis.java
+++ b/Mage.Sets/src/mage/cards/t/TheBattleOfGeonosis.java
@@ -27,15 +27,15 @@ public final class TheBattleOfGeonosis extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{R}{R}");
// The Battle of Geonosis deals X + 1 damage to each opponent and each creature your opponents control.
- Effect effect = new DamagePlayersEffect(Outcome.Damage, new IntPlusDynamicValue(1, ManacostVariableValue.instance), TargetController.OPPONENT);
+ Effect effect = new DamagePlayersEffect(Outcome.Damage, new IntPlusDynamicValue(1, ManacostVariableValue.REGULAR), TargetController.OPPONENT);
effect.setText("The Battle of Geonosis deals X plus 1 damage to each opponent");
this.getSpellAbility().addEffect(effect);
- effect = new DamageAllEffect(new IntPlusDynamicValue(1, ManacostVariableValue.instance), new FilterOpponentsCreaturePermanent());
+ effect = new DamageAllEffect(new IntPlusDynamicValue(1, ManacostVariableValue.REGULAR), new FilterOpponentsCreaturePermanent());
effect.setText("and each creature your opponents control");
this.getSpellAbility().addEffect(effect);
// Creatures you control get +X/+0 until end of turn.
- this.getSpellAbility().addEffect(new BoostControlledEffect(ManacostVariableValue.instance, StaticValue.get(0), Duration.EndOfTurn));
+ this.getSpellAbility().addEffect(new BoostControlledEffect(ManacostVariableValue.REGULAR, StaticValue.get(0), Duration.EndOfTurn));
}
diff --git a/Mage.Sets/src/mage/cards/t/TheBattleOfHoth.java b/Mage.Sets/src/mage/cards/t/TheBattleOfHoth.java
index e778a82476..356b801ed5 100644
--- a/Mage.Sets/src/mage/cards/t/TheBattleOfHoth.java
+++ b/Mage.Sets/src/mage/cards/t/TheBattleOfHoth.java
@@ -19,7 +19,7 @@ public final class TheBattleOfHoth extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{X}{W}{W}{W}");
// Create X 5/5 white artifact AT-AT creature tokens wiht "When this creature dies, create two 1/1 white Trooper creature tokens."
- this.getSpellAbility().addEffect(new CreateTokenEffect(new ATATToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new ATATToken(), ManacostVariableValue.REGULAR));
}
private TheBattleOfHoth(final TheBattleOfHoth card) {
diff --git a/Mage.Sets/src/mage/cards/t/TheBattleOfYavin.java b/Mage.Sets/src/mage/cards/t/TheBattleOfYavin.java
index 6bc768ffa7..9c03e4690a 100644
--- a/Mage.Sets/src/mage/cards/t/TheBattleOfYavin.java
+++ b/Mage.Sets/src/mage/cards/t/TheBattleOfYavin.java
@@ -65,7 +65,7 @@ class TheBattleOfYavinEffect extends OneShotEffect {
return false;
}
- int amount = (ManacostVariableValue.instance).calculate(game, source, this);
+ int amount = (ManacostVariableValue.REGULAR).calculate(game, source, this);
if (amount > 0) {
LinkedList sacrifices = new LinkedList<>();
diff --git a/Mage.Sets/src/mage/cards/t/ThoughtDissector.java b/Mage.Sets/src/mage/cards/t/ThoughtDissector.java
index 42abb13c30..0a64be464c 100644
--- a/Mage.Sets/src/mage/cards/t/ThoughtDissector.java
+++ b/Mage.Sets/src/mage/cards/t/ThoughtDissector.java
@@ -49,7 +49,7 @@ public final class ThoughtDissector extends CardImpl {
class ThoughtDissectorEffect extends OneShotEffect {
- private static final ManacostVariableValue amount = ManacostVariableValue.instance;
+ private static final ManacostVariableValue amount = ManacostVariableValue.REGULAR;
public ThoughtDissectorEffect() {
super(Outcome.Detriment);
diff --git a/Mage.Sets/src/mage/cards/t/TitansRevenge.java b/Mage.Sets/src/mage/cards/t/TitansRevenge.java
index 090bae82fd..5875610dde 100644
--- a/Mage.Sets/src/mage/cards/t/TitansRevenge.java
+++ b/Mage.Sets/src/mage/cards/t/TitansRevenge.java
@@ -21,7 +21,7 @@ public final class TitansRevenge extends CardImpl {
// Titan's Revenge deals X damage to any target. Clash with an opponent. If you win, return Titan's Revenge to its owner's hand.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
this.getSpellAbility().addEffect(ClashWinReturnToHandSpellEffect.getInstance());
}
diff --git a/Mage.Sets/src/mage/cards/t/TribalUnity.java b/Mage.Sets/src/mage/cards/t/TribalUnity.java
index 649a492e4d..13f1ee817e 100644
--- a/Mage.Sets/src/mage/cards/t/TribalUnity.java
+++ b/Mage.Sets/src/mage/cards/t/TribalUnity.java
@@ -29,7 +29,7 @@ public final class TribalUnity extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{X}{2}{G}");
// Creatures of the creature type of your choice get +X/+X until end of turn.
- this.getSpellAbility().addEffect(new TribalUnityEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new TribalUnityEffect(ManacostVariableValue.REGULAR));
}
private TribalUnity(final TribalUnity card) {
diff --git a/Mage.Sets/src/mage/cards/t/TropicalStorm.java b/Mage.Sets/src/mage/cards/t/TropicalStorm.java
index bdeab75691..3990c86d6c 100644
--- a/Mage.Sets/src/mage/cards/t/TropicalStorm.java
+++ b/Mage.Sets/src/mage/cards/t/TropicalStorm.java
@@ -31,7 +31,7 @@ public final class TropicalStorm extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{X}{G}");
// Tropical Storm deals X damage to each creature with flying and 1 additional damage to each blue creature.
- this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, filter));
+ this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, filter));
this.getSpellAbility().addEffect(new DamageAllEffect(1, filter2).setText("and 1 additional damage to each blue creature"));
}
diff --git a/Mage.Sets/src/mage/cards/u/UntamedMight.java b/Mage.Sets/src/mage/cards/u/UntamedMight.java
index e9f1913e29..302e603a70 100644
--- a/Mage.Sets/src/mage/cards/u/UntamedMight.java
+++ b/Mage.Sets/src/mage/cards/u/UntamedMight.java
@@ -20,7 +20,7 @@ public final class UntamedMight extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{G}");
this.getSpellAbility().addTarget(new TargetCreaturePermanent());
- this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.instance, ManacostVariableValue.instance, Duration.EndOfTurn));
+ this.getSpellAbility().addEffect(new BoostTargetEffect(ManacostVariableValue.REGULAR, ManacostVariableValue.REGULAR, Duration.EndOfTurn));
}
private UntamedMight(final UntamedMight card) {
diff --git a/Mage.Sets/src/mage/cards/v/VengefulArchon.java b/Mage.Sets/src/mage/cards/v/VengefulArchon.java
index cb3ba5ed7b..2d6a43f5fe 100644
--- a/Mage.Sets/src/mage/cards/v/VengefulArchon.java
+++ b/Mage.Sets/src/mage/cards/v/VengefulArchon.java
@@ -56,7 +56,7 @@ public final class VengefulArchon extends CardImpl {
class VengefulArchonEffect extends PreventDamageToControllerEffect {
public VengefulArchonEffect() {
- super(Duration.EndOfTurn, false, true, ManacostVariableValue.instance);
+ super(Duration.EndOfTurn, false, true, ManacostVariableValue.REGULAR);
staticText = "Prevent the next X damage that would be dealt to you this turn. If damage is prevented this way, {this} deals that much damage to target player or planeswalker";
}
diff --git a/Mage.Sets/src/mage/cards/v/VentifactBottle.java b/Mage.Sets/src/mage/cards/v/VentifactBottle.java
index 94c97a0cf2..1e48fcbda3 100644
--- a/Mage.Sets/src/mage/cards/v/VentifactBottle.java
+++ b/Mage.Sets/src/mage/cards/v/VentifactBottle.java
@@ -36,7 +36,7 @@ public final class VentifactBottle extends CardImpl {
// {X}{1}, {tap}: Put X charge counters on Ventifact Bottle. Activate this ability only any time you could cast a sorcery.
Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD,
- new AddCountersSourceEffect(CounterType.CHARGE.createInstance(), ManacostVariableValue.instance, true),
+ new AddCountersSourceEffect(CounterType.CHARGE.createInstance(), ManacostVariableValue.REGULAR, true),
new ManaCostsImpl("{1}{X}"));
ability.addCost(new TapSourceCost());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/v/VolcanicGeyser.java b/Mage.Sets/src/mage/cards/v/VolcanicGeyser.java
index 4f5d8aca1f..3f79f985e4 100644
--- a/Mage.Sets/src/mage/cards/v/VolcanicGeyser.java
+++ b/Mage.Sets/src/mage/cards/v/VolcanicGeyser.java
@@ -20,7 +20,7 @@ public final class VolcanicGeyser extends CardImpl {
// Volcanic Geyser deals X damage to any target.
- this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new DamageTargetEffect(ManacostVariableValue.REGULAR));
this.getSpellAbility().addTarget(new TargetAnyTarget());
}
diff --git a/Mage.Sets/src/mage/cards/w/WakerOfTheWilds.java b/Mage.Sets/src/mage/cards/w/WakerOfTheWilds.java
index e8a8c863bd..2841af08c0 100644
--- a/Mage.Sets/src/mage/cards/w/WakerOfTheWilds.java
+++ b/Mage.Sets/src/mage/cards/w/WakerOfTheWilds.java
@@ -40,7 +40,7 @@ public final class WakerOfTheWilds extends CardImpl {
Zone.BATTLEFIELD,
new AddCountersTargetEffect(
CounterType.P1P1.createInstance(0),
- ManacostVariableValue.instance
+ ManacostVariableValue.REGULAR
).setText("Put X +1/+1 counters on target land you control."),
new ManaCostsImpl("{X}{G}{G}")
);
diff --git a/Mage.Sets/src/mage/cards/w/WarCadence.java b/Mage.Sets/src/mage/cards/w/WarCadence.java
index 6593ee48b8..ba1df721d9 100644
--- a/Mage.Sets/src/mage/cards/w/WarCadence.java
+++ b/Mage.Sets/src/mage/cards/w/WarCadence.java
@@ -44,7 +44,7 @@ public final class WarCadence extends CardImpl {
class WarCadenceReplacementEffect extends ReplacementEffectImpl {
- DynamicValue xCosts = ManacostVariableValue.instance;
+ DynamicValue xCosts = ManacostVariableValue.REGULAR;
WarCadenceReplacementEffect() {
super(Duration.EndOfTurn, Outcome.Neutral);
diff --git a/Mage.Sets/src/mage/cards/w/WarTax.java b/Mage.Sets/src/mage/cards/w/WarTax.java
index a387da8f41..f99701148c 100644
--- a/Mage.Sets/src/mage/cards/w/WarTax.java
+++ b/Mage.Sets/src/mage/cards/w/WarTax.java
@@ -45,7 +45,7 @@ public final class WarTax extends CardImpl {
class WarTaxCantAttackUnlessPaysEffect extends PayCostToAttackBlockEffectImpl {
- DynamicValue xCosts = ManacostVariableValue.instance;
+ DynamicValue xCosts = ManacostVariableValue.REGULAR;
WarTaxCantAttackUnlessPaysEffect() {
super(Duration.EndOfTurn, Outcome.Neutral, RestrictType.ATTACK);
diff --git a/Mage.Sets/src/mage/cards/w/Whetwheel.java b/Mage.Sets/src/mage/cards/w/Whetwheel.java
index fb7a4e9b7a..d6a5f80369 100644
--- a/Mage.Sets/src/mage/cards/w/Whetwheel.java
+++ b/Mage.Sets/src/mage/cards/w/Whetwheel.java
@@ -26,7 +26,7 @@ public final class Whetwheel extends CardImpl {
// {X}{X}, {tap}: Target player puts the top X cards of their library into their graveyard.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutLibraryIntoGraveTargetEffect(
- ManacostVariableValue.instance), new ManaCostsImpl("{X}{X}"));
+ ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}{X}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetPlayer());
this.addAbility(ability);
diff --git a/Mage.Sets/src/mage/cards/w/WhiteSunsZenith.java b/Mage.Sets/src/mage/cards/w/WhiteSunsZenith.java
index 772562ec28..9619e086d9 100644
--- a/Mage.Sets/src/mage/cards/w/WhiteSunsZenith.java
+++ b/Mage.Sets/src/mage/cards/w/WhiteSunsZenith.java
@@ -20,7 +20,7 @@ public final class WhiteSunsZenith extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{W}{W}{W}");
// create X 2/2 white Cat creature tokens. Shuffle White Sun's Zenith into its owner's library.
- this.getSpellAbility().addEffect(new CreateTokenEffect(new CatToken(), ManacostVariableValue.instance));
+ this.getSpellAbility().addEffect(new CreateTokenEffect(new CatToken(), ManacostVariableValue.REGULAR));
this.getSpellAbility().addEffect(ShuffleSpellEffect.getInstance());
}
diff --git a/Mage.Sets/src/mage/cards/w/Windstorm.java b/Mage.Sets/src/mage/cards/w/Windstorm.java
index bafc1ca04c..cbd3e67894 100644
--- a/Mage.Sets/src/mage/cards/w/Windstorm.java
+++ b/Mage.Sets/src/mage/cards/w/Windstorm.java
@@ -27,7 +27,7 @@ public final class Windstorm extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{X}{G}");
- this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.instance, filter));
+ this.getSpellAbility().addEffect(new DamageAllEffect(ManacostVariableValue.REGULAR, filter));
}
private Windstorm(final Windstorm card) {
diff --git a/Mage.Sets/src/mage/cards/w/WrensRunHydra.java b/Mage.Sets/src/mage/cards/w/WrensRunHydra.java
index 2f915f4644..ff33269cd8 100644
--- a/Mage.Sets/src/mage/cards/w/WrensRunHydra.java
+++ b/Mage.Sets/src/mage/cards/w/WrensRunHydra.java
@@ -34,7 +34,7 @@ public final class WrensRunHydra extends CardImpl {
this.addAbility(new EntersBattlefieldAbility(new EntersBattlefieldWithXCountersEffect(CounterType.P1P1.createInstance())));
// Reinforce X—{X}{G}{G}
- this.addAbility(new ReinforceAbility(ManacostVariableValue.instance, new ManaCostsImpl<>("{X}{G}{G}")));
+ this.addAbility(new ReinforceAbility(ManacostVariableValue.REGULAR, new ManaCostsImpl<>("{X}{G}{G}")));
}
private WrensRunHydra(final WrensRunHydra card) {
diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/mana/ManaPoolTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/mana/ManaPoolTest.java
index 32a3ed8a6c..ea63b4b2b9 100644
--- a/Mage.Tests/src/test/java/org/mage/test/cards/mana/ManaPoolTest.java
+++ b/Mage.Tests/src/test/java/org/mage/test/cards/mana/ManaPoolTest.java
@@ -229,7 +229,7 @@ public class ManaPoolTest extends CardTestPlayerBase {
public void test_MultipleMana_OneXAbility() {
addCard(Zone.BATTLEFIELD, playerA, "Mountain", 4);
//
- Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}"));
+ Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}"));
ability.addTarget(new TargetAnyTarget());
addCustomCardWithAbility("damage X", playerA, ability);
@@ -261,7 +261,7 @@ public class ManaPoolTest extends CardTestPlayerBase {
new AddConditionalManaEffect(Mana.RedMana(10), new SimpleActivatedAbilityManaBuilder()),
new ManaCostsImpl("")));
//
- Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}"));
+ Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}"));
ability.addTarget(new TargetAnyTarget());
addCustomCardWithAbility("damage X", playerA, ability);
@@ -289,12 +289,12 @@ public class ManaPoolTest extends CardTestPlayerBase {
addCard(Zone.HAND, playerA, "Lightning Bolt"); // {R}
addCard(Zone.BATTLEFIELD, playerA, "Mountain", 1 + 3 + 1);
//
- Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl(""));
+ Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl(""));
ability.addTarget(new TargetAnyTarget());
addCustomCardWithAbility("damage X", playerA, ability);
//
// {X}: Counter target spell
- ability = new SimpleActivatedAbility(Zone.ALL, new CounterUnlessPaysEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}"));
+ ability = new SimpleActivatedAbility(Zone.ALL, new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}"));
ability.addTarget(new TargetSpell());
addCustomCardWithAbility("counter until pay X", playerB, ability);
addCard(Zone.BATTLEFIELD, playerB, "Island", 3);
@@ -338,12 +338,12 @@ public class ManaPoolTest extends CardTestPlayerBase {
new AddConditionalManaEffect(Mana.RedMana(10), new SimpleActivatedAbilityManaBuilder()),
new ManaCostsImpl("")));
//
- Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.instance), new ManaCostsImpl(""));
+ Ability ability = new SimpleActivatedAbility(Zone.ALL, new DamageTargetEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl(""));
ability.addTarget(new TargetAnyTarget());
addCustomCardWithAbility("damage X", playerA, ability);
//
// {X}: Counter target spell
- ability = new SimpleActivatedAbility(Zone.ALL, new CounterUnlessPaysEffect(ManacostVariableValue.instance), new ManaCostsImpl("{X}"));
+ ability = new SimpleActivatedAbility(Zone.ALL, new CounterUnlessPaysEffect(ManacostVariableValue.REGULAR), new ManaCostsImpl("{X}"));
ability.addTarget(new TargetSpell());
addCustomCardWithAbility("counter until pay X", playerB, ability);
addCard(Zone.BATTLEFIELD, playerB, "Island", 3);
diff --git a/Mage/src/main/java/mage/abilities/condition/common/AdamantCondition.java b/Mage/src/main/java/mage/abilities/condition/common/AdamantCondition.java
index b09deedcb5..8dd3842fef 100644
--- a/Mage/src/main/java/mage/abilities/condition/common/AdamantCondition.java
+++ b/Mage/src/main/java/mage/abilities/condition/common/AdamantCondition.java
@@ -38,11 +38,11 @@ public enum AdamantCondition implements Condition {
}
return source.getManaCostsToPay().getUsedManaToPay().getColor(coloredManaSymbol) > 2;
}
- ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class, source.getSourceId());
+ ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class);
if (watcher == null) {
return false;
}
- Mana payment = watcher.getAndResetLastPayment();
+ Mana payment = watcher.getAndResetLastPayment(source.getSourceId());
if (payment == null) {
return false;
}
diff --git a/Mage/src/main/java/mage/abilities/condition/common/ManaWasSpentCondition.java b/Mage/src/main/java/mage/abilities/condition/common/ManaWasSpentCondition.java
index fcf1e06da5..73455edf31 100644
--- a/Mage/src/main/java/mage/abilities/condition/common/ManaWasSpentCondition.java
+++ b/Mage/src/main/java/mage/abilities/condition/common/ManaWasSpentCondition.java
@@ -28,11 +28,11 @@ public class ManaWasSpentCondition implements Condition {
@Override
public boolean apply(Game game, Ability source) {
if (source.getAbilityType() == AbilityType.SPELL) {
- return (source.getManaCostsToPay().getUsedManaToPay().getColor(coloredManaSymbol) > 0);
+ return source.getManaCostsToPay().getUsedManaToPay().getColor(coloredManaSymbol) > 0;
}
- ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class, source.getSourceId());
+ ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class);
if (watcher != null) {
- Mana payment = watcher.getAndResetLastPayment();
+ Mana payment = watcher.getAndResetLastPayment(source.getSourceId());
if (payment != null) {
return payment.getColor(coloredManaSymbol) > 0;
}
diff --git a/Mage/src/main/java/mage/abilities/dynamicvalue/common/ManacostVariableValue.java b/Mage/src/main/java/mage/abilities/dynamicvalue/common/ManacostVariableValue.java
index fa7d812835..9f77849d4d 100644
--- a/Mage/src/main/java/mage/abilities/dynamicvalue/common/ManacostVariableValue.java
+++ b/Mage/src/main/java/mage/abilities/dynamicvalue/common/ManacostVariableValue.java
@@ -3,25 +3,24 @@ package mage.abilities.dynamicvalue.common;
import mage.abilities.Ability;
import mage.abilities.dynamicvalue.DynamicValue;
import mage.abilities.effects.Effect;
-import mage.constants.AbilityType;
import mage.game.Game;
import mage.watchers.common.ManaSpentToCastWatcher;
public enum ManacostVariableValue implements DynamicValue {
- instance;
+ REGULAR, ETB;
@Override
public int calculate(Game game, Ability sourceAbility, Effect effect) {
- if (sourceAbility.getAbilityType() == AbilityType.SPELL) {
+ if (this == REGULAR) {
return sourceAbility.getManaCostsToPay().getX();
}
- ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class, sourceAbility.getSourceId());
- return watcher != null ? watcher.getAndResetLastXValue() : sourceAbility.getManaCostsToPay().getX();
+ ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class);
+ return watcher != null ? watcher.getAndResetLastXValue(sourceAbility.getSourceId()) : sourceAbility.getManaCostsToPay().getX();
}
@Override
public ManacostVariableValue copy() {
- return ManacostVariableValue.instance;
+ return this;
}
@Override
diff --git a/Mage/src/main/java/mage/abilities/dynamicvalue/common/SnowManaSpentValue.java b/Mage/src/main/java/mage/abilities/dynamicvalue/common/SnowManaSpentValue.java
index 01237aab2a..5421bf2caf 100644
--- a/Mage/src/main/java/mage/abilities/dynamicvalue/common/SnowManaSpentValue.java
+++ b/Mage/src/main/java/mage/abilities/dynamicvalue/common/SnowManaSpentValue.java
@@ -19,13 +19,11 @@ public enum SnowManaSpentValue implements DynamicValue {
if (sourceAbility.getAbilityType() == AbilityType.SPELL) {
return sourceAbility.getManaCostsToPay().getUsedManaToPay().getSnow();
}
- ManaSpentToCastWatcher watcher = game.getState().getWatcher(
- ManaSpentToCastWatcher.class, sourceAbility.getSourceId()
- );
+ ManaSpentToCastWatcher watcher = game.getState().getWatcher(ManaSpentToCastWatcher.class);
if (watcher == null) {
return 0;
}
- Mana payment = watcher.getAndResetLastPayment();
+ Mana payment = watcher.getAndResetLastPayment(sourceAbility.getSourceId());
if (payment == null) {
return 0;
}
diff --git a/Mage/src/main/java/mage/watchers/common/ManaSpentToCastWatcher.java b/Mage/src/main/java/mage/watchers/common/ManaSpentToCastWatcher.java
index 99d132f723..67c13a3567 100644
--- a/Mage/src/main/java/mage/watchers/common/ManaSpentToCastWatcher.java
+++ b/Mage/src/main/java/mage/watchers/common/ManaSpentToCastWatcher.java
@@ -9,6 +9,10 @@ import mage.game.events.ZoneChangeEvent;
import mage.game.stack.Spell;
import mage.watchers.Watcher;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.UUID;
+
/**
* Watcher saves the mana that was spent to cast a spell
* automatically added in each game
@@ -17,48 +21,44 @@ import mage.watchers.Watcher;
*/
public class ManaSpentToCastWatcher extends Watcher {
- private Mana payment = null;
- private Integer xValue = 0;
+ private final Map manaMap = new HashMap<>();
+ private final Map xValueMap = new HashMap<>();
public ManaSpentToCastWatcher() {
- super(WatcherScope.CARD);
+ super(WatcherScope.GAME);
}
@Override
public void watch(GameEvent event, Game game) {
// There was a check for the from zone being the hand, but that should not matter
- if (event.getType() == GameEvent.EventType.SPELL_CAST) {
- Spell spell = (Spell) game.getObject(event.getTargetId());
- if (spell != null && this.getSourceId().equals(spell.getSourceId())) {
- payment = spell.getSpellAbility().getManaCostsToPay().getUsedManaToPay();
- xValue = spell.getSpellAbility().getManaCostsToPay().getX();
- }
- }
- if (event.getType() == GameEvent.EventType.ZONE_CHANGE
- && this.getSourceId().equals(event.getSourceId())) {
- if (((ZoneChangeEvent) event).getFromZone() == Zone.BATTLEFIELD) {
- payment = null;
- xValue = 0;
- }
+ switch (event.getType()) {
+ case SPELL_CAST:
+ Spell spell = (Spell) game.getObject(event.getTargetId());
+ if (spell != null) {
+ manaMap.put(spell.getSourceId(), spell.getSpellAbility().getManaCostsToPay().getUsedManaToPay());
+ xValueMap.put(spell.getSourceId(), spell.getSpellAbility().getManaCostsToPay().getX());
+ }
+ return;
+ case ZONE_CHANGE:
+ if (((ZoneChangeEvent) event).getFromZone() == Zone.BATTLEFIELD) {
+ manaMap.remove(event.getSourceId());
+ xValueMap.remove(event.getSourceId());
+ }
}
}
- public Mana getAndResetLastPayment() {
- Mana returnPayment = null;
- if (payment != null) {
- returnPayment = payment.copy();
- }
- return returnPayment;
+ public Mana getAndResetLastPayment(UUID sourceId) {
+ return manaMap.getOrDefault(sourceId, null);
}
- public int getAndResetLastXValue() {
- return xValue;
+ public int getAndResetLastXValue(UUID sourceId) {
+ return xValueMap.getOrDefault(sourceId, 0);
}
@Override
public void reset() {
super.reset();
- payment = null;
- xValue = 0;
+ manaMap.clear();
+ xValueMap.clear();
}
}