use Mana.ColorlessMana; SimpleManaAbility

removing explicit `new BasicManaEffect()` calls, where SimpleManaAbility will do it implicitly
This commit is contained in:
Neil Gentleman 2016-07-17 20:09:25 -07:00
parent 6ac8c8e251
commit 564e2cd58b
79 changed files with 95 additions and 205 deletions

View file

@ -33,7 +33,6 @@ import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
@ -53,7 +52,7 @@ public class BasalThrull extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// {T}, Sacrifice Basal Thrull: Add {B}{B} to your mana pool. // {T}, Sacrifice Basal Thrull: Add {B}{B} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 0, 0, 0, 2, 0, 0, 0)), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlackMana(2), new TapSourceCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -53,7 +53,7 @@ public class BasaltMonolith extends CardImpl {
// Basalt Monolith doesn't untap during your untap step. // Basalt Monolith doesn't untap during your untap step.
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepSourceEffect())); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepSourceEffect()));
// {tap}: Add {C}{C}{C} to your mana pool. // {tap}: Add {C}{C}{C} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 0, 0, 0, 0, 0, 3), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(3), new TapSourceCost()));
// {3}: Untap Basalt Monolith. // {3}: Untap Basalt Monolith.
this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapSourceEffect(), new GenericManaCost(3))); this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapSourceEffect(), new GenericManaCost(3)));
} }

View file

@ -33,7 +33,6 @@ import mage.constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.Mana; import mage.Mana;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
@ -53,7 +52,7 @@ public class BloodVassal extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// Sacrifice Blood Vassal: Add {B}{B} to your mana pool. // Sacrifice Blood Vassal: Add {B}{B} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.BlackMana(2)), new SacrificeSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlackMana(2), new SacrificeSourceCost()));
} }
public BloodVassal(final BloodVassal card) { public BloodVassal(final BloodVassal card) {

View file

@ -34,7 +34,6 @@ import mage.abilities.Ability;
import mage.abilities.costs.common.DiscardCardCost; import mage.abilities.costs.common.DiscardCardCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
@ -55,7 +54,7 @@ public class BogWitch extends CardImpl {
this.toughness = new MageInt(1); this.toughness = new MageInt(1);
// {B}, {tap}, Discard a card: Add {B}{B}{B} to your mana pool. // {B}, {tap}, Discard a card: Add {B}{B}{B} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 0, 0, 0, 3, 0, 0, 0)), new ManaCostsImpl("{B}")); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlackMana(3), new ManaCostsImpl("{B}"));
ability.addCost(new TapSourceCost()); ability.addCost(new TapSourceCost());
ability.addCost(new DiscardCardCost()); ability.addCost(new DiscardCardCost());
this.addAbility(ability); this.addAbility(ability);

View file

@ -67,7 +67,7 @@ public class BoseijuWhoSheltersAll extends CardImpl {
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
// {tap}, Pay 2 life: Add {C} to your mana pool. If that mana is spent on an instant or sorcery spell, that spell can't be countered by spells or abilities. // {tap}, Pay 2 life: Add {C} to your mana pool. If that mana is spent on an instant or sorcery spell, that spell can't be countered by spells or abilities.
Mana mana = new Mana(0, 0, 0, 0, 0, 0, 0, 1); Mana mana = Mana.ColorlessMana(1);
mana.setFlag(true); // used to indicate this mana ability mana.setFlag(true); // used to indicate this mana ability
SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, mana, new TapSourceCost()); SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, mana, new TapSourceCost());
ability.addCost(new PayLifeCost(2)); ability.addCost(new PayLifeCost(2));

View file

@ -49,8 +49,8 @@ public class CabalRitual extends CardImpl {
// Add {B}{B}{B} to your mana pool. // Add {B}{B}{B} to your mana pool.
// Threshold Add {B}{B}{B}{B}{B} to your mana pool instead if seven or more cards are in your graveyard. // Threshold Add {B}{B}{B}{B}{B} to your mana pool instead if seven or more cards are in your graveyard.
this.getSpellAbility().addEffect(new ConditionalManaEffect( this.getSpellAbility().addEffect(new ConditionalManaEffect(
new BasicManaEffect(new Mana(0, 0, 0, 0, 5, 0, 0, 0)), new BasicManaEffect(Mana.BlackMana(5)),
new BasicManaEffect(new Mana(0, 0, 0, 0, 3, 0, 0, 0)), new BasicManaEffect(Mana.BlackMana(3)),
new CardsInControllerGraveCondition(7), new CardsInControllerGraveCondition(7),
"Add {B}{B}{B} to your mana pool.<br/><br/><i>Threshold</i> - Add {B}{B}{B}{B}{B} to your mana pool instead if seven or more cards are in your graveyard")); "Add {B}{B}{B} to your mana pool.<br/><br/><i>Threshold</i> - Add {B}{B}{B}{B}{B} to your mana pool instead if seven or more cards are in your graveyard"));
} }

View file

@ -47,7 +47,7 @@ public class Cathodion extends CardImpl {
this.subtype.add("Construct"); this.subtype.add("Construct");
this.power = new MageInt(3); this.power = new MageInt(3);
this.toughness = new MageInt(3); this.toughness = new MageInt(3);
this.addAbility(new DiesTriggeredAbility(new BasicManaEffect(new Mana(0, 0, 0, 0, 0, 0, 0, 3)), false)); this.addAbility(new DiesTriggeredAbility(new BasicManaEffect(Mana.ColorlessMana(3)), false));
} }
public Cathodion(final Cathodion card) { public Cathodion(final Cathodion card) {

View file

@ -61,7 +61,7 @@ public class CircleOfElders extends CardImpl {
// <i>Formidable</i> - {T}: Add {C}{C}{C} to your mana pool. Activate this only if creatures you control have total power 8 or greater. // <i>Formidable</i> - {T}: Add {C}{C}{C} to your mana pool. Activate this only if creatures you control have total power 8 or greater.
Ability ability = new ActivateIfConditionManaAbility( Ability ability = new ActivateIfConditionManaAbility(
Zone.BATTLEFIELD, Zone.BATTLEFIELD,
new BasicManaEffect(new Mana(0, 0, 0, 0, 0, 0, 0, 3)), new BasicManaEffect(Mana.ColorlessMana(3)),
new TapSourceCost(), new TapSourceCost(),
FormidableCondition.getInstance()); FormidableCondition.getInstance());
ability.setAbilityWord(AbilityWord.FORMIDABLE); ability.setAbilityWord(AbilityWord.FORMIDABLE);

View file

@ -53,7 +53,7 @@ public class CoalStoker extends CardImpl {
// When Coal Stoker enters the battlefield, if you cast it from your hand, add {R}{R}{R} to your mana pool. // When Coal Stoker enters the battlefield, if you cast it from your hand, add {R}{R}{R} to your mana pool.
this.addAbility(new ConditionalTriggeredAbility( this.addAbility(new ConditionalTriggeredAbility(
new EntersBattlefieldTriggeredAbility(new BasicManaEffect(new Mana(3, 0, 0, 0, 0, 0, 0, 0)), false), new EntersBattlefieldTriggeredAbility(new BasicManaEffect(Mana.RedMana(3)), false),
new CastFromHandSourceCondition(), new CastFromHandSourceCondition(),
"When {this} enters the battlefield, if you cast it from your hand, add {R}{R}{R} to your mana pool."), "When {this} enters the battlefield, if you cast it from your hand, add {R}{R}{R} to your mana pool."),
new CastFromHandWatcher()); new CastFromHandWatcher());

View file

@ -51,7 +51,7 @@ public class CullingTheWeak extends CardImpl {
this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(new FilterControlledCreaturePermanent("a creature")))); this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(new FilterControlledCreaturePermanent("a creature"))));
// Add {B}{B}{B}{B} to your mana pool. // Add {B}{B}{B}{B} to your mana pool.
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(0, 0, 0, 0, 4, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.BlackMana(4)));
} }
public CullingTheWeak(final CullingTheWeak card) { public CullingTheWeak(final CullingTheWeak card) {

View file

@ -43,7 +43,7 @@ public class DarkRitual extends CardImpl {
public DarkRitual(UUID ownerId, CardSetInfo setInfo) { public DarkRitual(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{B}"); super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{B}");
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(0, 0, 0, 0, 3, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.BlackMana(3)));
} }
public DarkRitual(final DarkRitual card) { public DarkRitual(final DarkRitual card) {

View file

@ -55,7 +55,7 @@ public class Deconstruct extends CardImpl {
this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addEffect(new DestroyTargetEffect());
this.getSpellAbility().addTarget(new TargetPermanent(filter)); this.getSpellAbility().addTarget(new TargetPermanent(filter));
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(0, 3, 0, 0, 0, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.GreenMana(3)));
} }
public Deconstruct(final Deconstruct card) { public Deconstruct(final Deconstruct card) {

View file

@ -47,7 +47,7 @@ public class DesperateRitual extends CardImpl {
// Add {R}{R}{R} to your mana pool. // Add {R}{R}{R} to your mana pool.
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(3, 0, 0, 0, 0, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.RedMana(3)));
// Splice onto Arcane {1}{R} // Splice onto Arcane {1}{R}
this.addAbility(new SpliceOntoArcaneAbility("{1}{R}")); this.addAbility(new SpliceOntoArcaneAbility("{1}{R}"));
} }

View file

@ -33,9 +33,8 @@ import mage.abilities.common.SimpleActivatedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.DrawCardSourceControllerEffect;
import mage.abilities.mana.BasicManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
import mage.constants.CardType; import mage.constants.CardType;
@ -50,7 +49,7 @@ public class DreamstoneHedron extends CardImpl {
public DreamstoneHedron(UUID ownerId, CardSetInfo setInfo) { public DreamstoneHedron(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{6}"); super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{6}");
this.addAbility(new DreamstoneHedronFirstManaAbility()); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(3), new TapSourceCost()));
SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD,
new DrawCardSourceControllerEffect(3), new DrawCardSourceControllerEffect(3),
new GenericManaCost(3)); new GenericManaCost(3));
@ -68,20 +67,4 @@ public class DreamstoneHedron extends CardImpl {
return new DreamstoneHedron(this); return new DreamstoneHedron(this);
} }
class DreamstoneHedronFirstManaAbility extends BasicManaAbility {
public DreamstoneHedronFirstManaAbility() {
super(new BasicManaEffect(new Mana(0, 0, 0, 0, 0, 0, 0, 3)));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 3));
}
public DreamstoneHedronFirstManaAbility(final DreamstoneHedronFirstManaAbility ability) {
super(ability);
}
@Override
public DreamstoneHedronFirstManaAbility copy() {
return new DreamstoneHedronFirstManaAbility(this);
}
}
} }

View file

@ -51,7 +51,7 @@ public class DroidFoundry extends CardImpl {
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
// When Droid Foundry enters the battlefield , add {U} to your mana pool. // When Droid Foundry enters the battlefield , add {U} to your mana pool.
this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(new Mana(0, 0, 1, 0, 0, 0, 0, 0)))); this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(Mana.BlueMana(1))));
// {T}: Add {W} or {B} to you mana pool. // {T}: Add {W} or {B} to you mana pool.
this.addAbility(new WhiteManaAbility()); this.addAbility(new WhiteManaAbility());

View file

@ -33,7 +33,6 @@ import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.RedManaAbility; import mage.abilities.mana.RedManaAbility;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -55,7 +54,7 @@ public class DwarvenRuins extends CardImpl {
// {tap}: Add {R} to your mana pool. // {tap}: Add {R} to your mana pool.
this.addAbility(new RedManaAbility()); this.addAbility(new RedManaAbility());
// {tap}, Sacrifice Dwarven Ruins: Add {R}{R} to your mana pool. // {tap}, Sacrifice Dwarven Ruins: Add {R}{R} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.RedMana(2)), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.RedMana(2), new TapSourceCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -33,7 +33,6 @@ import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.BlackManaAbility; import mage.abilities.mana.BlackManaAbility;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -55,7 +54,7 @@ public class EbonStronghold extends CardImpl {
// {tap}: Add {B} to your mana pool. // {tap}: Add {B} to your mana pool.
this.addAbility(new BlackManaAbility()); this.addAbility(new BlackManaAbility());
// {tap}, Sacrifice Ebon Stronghold: Add {B}{B} to your mana pool. // {tap}, Sacrifice Ebon Stronghold: Add {B}{B} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.BlackMana(2)), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlackMana(2), new TapSourceCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -33,7 +33,6 @@ import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.costs.Cost; import mage.abilities.costs.Cost;
import mage.abilities.costs.CostImpl; import mage.abilities.costs.CostImpl;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.Card; import mage.cards.Card;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -58,7 +57,7 @@ public class ElvishSpiritGuide extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// Exile Elvish Spirit Guide from your hand: Add {G} to your mana pool. // Exile Elvish Spirit Guide from your hand: Add {G} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.HAND, new BasicManaEffect(Mana.GreenMana(1)), new ExileSourceFromHandCost())); this.addAbility(new SimpleManaAbility(Zone.HAND, Mana.GreenMana(1), new ExileSourceFromHandCost()));
} }
public ElvishSpiritGuide(final ElvishSpiritGuide card) { public ElvishSpiritGuide(final ElvishSpiritGuide card) {

View file

@ -51,7 +51,7 @@ public class EwokVillage extends CardImpl {
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
// When Ewok Village enters the battlefield , add {G} to your mana pool. // When Ewok Village enters the battlefield , add {G} to your mana pool.
this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(new Mana(0, 1, 0, 0, 0, 0, 0, 0)))); this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(Mana.GreenMana(1))));
// {T}: Add {R} or {W} to you mana pool. // {T}: Add {R} or {W} to you mana pool.
this.addAbility(new RedManaAbility()); this.addAbility(new RedManaAbility());

View file

@ -29,14 +29,13 @@ package mage.cards.f;
import java.util.UUID; import java.util.UUID;
import mage.MageInt; import mage.MageInt;
import static mage.Mana.WhiteMana; import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.ActivationInfo; import mage.abilities.ActivationInfo;
import mage.abilities.DelayedTriggeredAbility; import mage.abilities.DelayedTriggeredAbility;
import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility;
import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.OneShotEffect;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.SacrificeSourceEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -60,9 +59,7 @@ public class FarrelitePriest extends CardImpl {
this.toughness = new MageInt(3); this.toughness = new MageInt(3);
// {1}: Add {W} to your mana pool. If this ability has been activated four or more times this turn, sacrifice Farrelite Priest at the beginning of the next end step. // {1}: Add {W} to your mana pool. If this ability has been activated four or more times this turn, sacrifice Farrelite Priest at the beginning of the next end step.
SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.WhiteMana(1), new ManaCostsImpl("{1}"));
new BasicManaEffect(WhiteMana(1)),
new ManaCostsImpl("{1}"));
ability.addEffect(new FarrelitePriestEffect()); ability.addEffect(new FarrelitePriestEffect());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -107,7 +107,7 @@ public class FrontierSiege extends CardImpl {
class FrontierSiegeKhansTriggeredAbility extends TriggeredAbilityImpl { class FrontierSiegeKhansTriggeredAbility extends TriggeredAbilityImpl {
public FrontierSiegeKhansTriggeredAbility() { public FrontierSiegeKhansTriggeredAbility() {
super(Zone.BATTLEFIELD, new AddManaToManaPoolSourceControllerEffect(new Mana(0, 2, 0, 0, 0, 0, 0, 0)), false); super(Zone.BATTLEFIELD, new AddManaToManaPoolSourceControllerEffect(Mana.GreenMana(2)), false);
} }

View file

@ -53,7 +53,7 @@ public class FyndhornElder extends CardImpl {
this.toughness = new MageInt(1); this.toughness = new MageInt(1);
// {tap}: Add {G}{G} to your mana pool. // {tap}: Add {G}{G} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 2, 0, 0, 0, 0, 0, 0), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(2), new TapSourceCost()));
} }
public FyndhornElder(final FyndhornElder card) { public FyndhornElder(final FyndhornElder card) {

View file

@ -35,7 +35,6 @@ import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.RedManaAbility; import mage.abilities.mana.RedManaAbility;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -56,7 +55,7 @@ public class GeothermalCrevice extends CardImpl {
// {tap}: Add {R} to your mana pool. // {tap}: Add {R} to your mana pool.
this.addAbility(new RedManaAbility()); this.addAbility(new RedManaAbility());
// {tap}, Sacrifice Geothermal Crevice: Add {B}{G} to your mana pool. // {tap}, Sacrifice Geothermal Crevice: Add {B}{G} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 1, 0, 0, 1, 0, 0, 0)), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 1, 0, 0, 1, 0, 0, 0), new TapSourceCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -145,7 +145,7 @@ class GrandArchitectManaAbility extends ManaAbility {
GrandArchitectManaAbility() { GrandArchitectManaAbility() {
super(Zone.BATTLEFIELD, new BasicManaEffect(new GrandArchitectConditionalMana()), new TapTargetCost(new TargetControlledCreaturePermanent(1, 1, filter, true))); super(Zone.BATTLEFIELD, new BasicManaEffect(new GrandArchitectConditionalMana()), new TapTargetCost(new TargetControlledCreaturePermanent(1, 1, filter, true)));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 2)); this.netMana.add(Mana.ColorlessMana(2));
} }
GrandArchitectManaAbility(GrandArchitectManaAbility ability) { GrandArchitectManaAbility(GrandArchitectManaAbility ability) {

View file

@ -33,7 +33,6 @@ import mage.constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.Mana; import mage.Mana;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
@ -53,7 +52,7 @@ public class GreenweaverDruid extends CardImpl {
this.toughness = new MageInt(1); this.toughness = new MageInt(1);
// {T}: Add {G}{G} to your mana pool. // {T}: Add {G}{G} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.GreenMana(2)), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(2), new TapSourceCost()));
} }
public GreenweaverDruid(final GreenweaverDruid card) { public GreenweaverDruid(final GreenweaverDruid card) {

View file

@ -64,7 +64,7 @@ public class GroveOfTheGuardian extends CardImpl {
super(ownerId, setInfo, new CardType[]{CardType.LAND}, ""); super(ownerId, setInfo, new CardType[]{CardType.LAND}, "");
// {T}: Add {C} to your mana pool. // {T}: Add {C} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 0, 0, 0, 0, 0, 1), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(1), new TapSourceCost()));
// {3}{G}{W}, {T}, Tap two untapped creatures you control, Sacrifice Grove of the Guardian: Create an 8/8 green and white Elemental creature token with vigilance. // {3}{G}{W}, {T}, Tap two untapped creatures you control, Sacrifice Grove of the Guardian: Create an 8/8 green and white Elemental creature token with vigilance.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new ElementalToken(), 1), new ManaCostsImpl("{3}{G}{W}")); Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new ElementalToken(), 1), new ManaCostsImpl("{3}{G}{W}"));

View file

@ -33,7 +33,6 @@ import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.GreenManaAbility; import mage.abilities.mana.GreenManaAbility;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -55,7 +54,7 @@ public class HavenwoodBattleground extends CardImpl {
// {tap}: Add {G} to your mana pool. // {tap}: Add {G} to your mana pool.
this.addAbility(new GreenManaAbility()); this.addAbility(new GreenManaAbility());
// {tap}, Sacrifice Havenwood Battleground: Add {G}{G} to your mana pool. // {tap}, Sacrifice Havenwood Battleground: Add {G}{G} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.GreenMana(2)), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(2), new TapSourceCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -63,7 +63,7 @@ public class HeritageDruid extends CardImpl {
this.toughness = new MageInt(1); this.toughness = new MageInt(1);
// Tap three untapped Elves you control: Add {G}{G}{G} to your mana pool. // Tap three untapped Elves you control: Add {G}{G}{G} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 3, 0, 0, 0, 0, 0, 0), new TapTargetCost(new TargetControlledCreaturePermanent(3, 3, filter, true)))); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(3), new TapTargetCost(new TargetControlledCreaturePermanent(3, 3, filter, true))));
} }
public HeritageDruid(final HeritageDruid card) { public HeritageDruid(final HeritageDruid card) {

View file

@ -51,7 +51,7 @@ public class HuttPalace extends CardImpl {
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
// When Hutt Palace enters the battlefield , add {R} to your mana pool. // When Hutt Palace enters the battlefield , add {R} to your mana pool.
this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(new Mana(1, 0, 0, 0, 0, 0, 0, 0)))); this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(Mana.RedMana(1))));
// {T}: Add {B} or {G} to you mana pool. // {T}: Add {B} or {G} to you mana pool.
this.addAbility(new BlackManaAbility()); this.addAbility(new BlackManaAbility());

View file

@ -36,7 +36,6 @@ import mage.abilities.DelayedTriggeredAbility;
import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility;
import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.OneShotEffect;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.SacrificeSourceEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -59,9 +58,7 @@ public class InitiatesOfTheEbonHand extends CardImpl {
this.toughness = new MageInt(1); this.toughness = new MageInt(1);
// {1}: Add {B} to your mana pool. If this ability has been activated four or more times this turn, sacrifice Initiates of the Ebon Hand at the beginning of the next end step. // {1}: Add {B} to your mana pool. If this ability has been activated four or more times this turn, sacrifice Initiates of the Ebon Hand at the beginning of the next end step.
SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, BlackMana(1), new ManaCostsImpl("{1}"));
new BasicManaEffect(BlackMana(1)),
new ManaCostsImpl("{1}"));
ability.addEffect(new InitiatesOfTheEbonHandEffect()); ability.addEffect(new InitiatesOfTheEbonHandEffect());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -51,7 +51,7 @@ public class JediTemple extends CardImpl {
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
// When Jedi Temple enters the battlefield , add {W} to your mana pool. // When Jedi Temple enters the battlefield , add {W} to your mana pool.
this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(new Mana(0, 0, 0, 1, 0, 0, 0, 0)))); this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(Mana.WhiteMana(1))));
// {T}: Add {G} or {U} to you mana pool. // {T}: Add {G} or {U} to you mana pool.
this.addAbility(new GreenManaAbility()); this.addAbility(new GreenManaAbility());

View file

@ -40,7 +40,6 @@ import mage.abilities.Ability;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
import mage.abilities.keyword.LevelUpAbility; import mage.abilities.keyword.LevelUpAbility;
import mage.abilities.keyword.LevelerCardBuilder; import mage.abilities.keyword.LevelerCardBuilder;
@ -86,9 +85,7 @@ public class JoragaTreespeaker extends LevelerCard {
// Elves you control have "{T}: Add {G}{G} to your mana pool." // Elves you control have "{T}: Add {G}{G} to your mana pool."
Abilities<Ability> abilities2 = new AbilitiesImpl<Ability>(); Abilities<Ability> abilities2 = new AbilitiesImpl<Ability>();
abilities2.add(new SimpleStaticAbility(Zone.BATTLEFIELD, abilities2.add(new SimpleStaticAbility(Zone.BATTLEFIELD,
new GainAbilityControlledEffect(new SimpleManaAbility(Zone.BATTLEFIELD, new GainAbilityControlledEffect(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(2), new TapSourceCost()),
new BasicManaEffect(Mana.GreenMana(2)),
new TapSourceCost()),
Duration.WhileOnBattlefield, filter))); Duration.WhileOnBattlefield, filter)));
this.addAbilities(LevelerCardBuilder.construct( this.addAbilities(LevelerCardBuilder.construct(

View file

@ -32,12 +32,13 @@ import java.util.UUID;
import mage.MageInt; import mage.MageInt;
import mage.Mana; import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.BasicManaEffect; import mage.abilities.mana.SimpleManaAbility;
import mage.abilities.mana.BasicManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
import mage.constants.CardType; import mage.constants.CardType;
import mage.constants.Zone;
/** /**
* *
@ -55,7 +56,7 @@ public class KnotvineMystic extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// {1}, {T}: Add {R}{G}{W} to your mana pool. // {1}, {T}: Add {R}{G}{W} to your mana pool.
Ability ability = new KnotvineMysticManaAbility(); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(1, 1, 0, 1, 0, 0, 0, 0), new TapSourceCost());
ability.addManaCost(new GenericManaCost(1)); ability.addManaCost(new GenericManaCost(1));
this.addAbility(ability); this.addAbility(ability);
} }
@ -70,20 +71,3 @@ public class KnotvineMystic extends CardImpl {
} }
} }
class KnotvineMysticManaAbility extends BasicManaAbility {
public KnotvineMysticManaAbility() {
super(new BasicManaEffect(new Mana(1, 1, 0, 1, 0, 0, 0, 0)));
this.netMana.add(new Mana(1, 1, 0, 1, 0, 0, 0, 0));
}
public KnotvineMysticManaAbility(final KnotvineMysticManaAbility ability) {
super(ability);
}
@Override
public KnotvineMysticManaAbility copy() {
return new KnotvineMysticManaAbility(this);
}
}

View file

@ -65,7 +65,7 @@ public class LakeOfTheDead extends CardImpl {
this.addAbility(new BlackManaAbility()); this.addAbility(new BlackManaAbility());
// {tap}, Sacrifice a Swamp: Add {B}{B}{B}{B} to your mana pool. // {tap}, Sacrifice a Swamp: Add {B}{B}{B}{B} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 0, 0, 4, 0, 0, 0), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlackMana(4), new TapSourceCost());
ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter))); ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter)));
this.addAbility(ability); this.addAbility(ability);

View file

@ -49,7 +49,7 @@ public class LiturgyOfBlood extends CardImpl {
// Destroy target creature. Add {B}{B}{B} to your mana pool. // Destroy target creature. Add {B}{B}{B} to your mana pool.
this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addEffect(new DestroyTargetEffect());
this.getSpellAbility().addTarget(new TargetCreaturePermanent()); this.getSpellAbility().addTarget(new TargetCreaturePermanent());
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(0, 0, 0, 0, 3, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.BlackMana(3)));
} }
public LiturgyOfBlood(final LiturgyOfBlood card) { public LiturgyOfBlood(final LiturgyOfBlood card) {

View file

@ -92,7 +92,7 @@ class ManaDrainCounterEffect extends OneShotEffect {
game.getStack().counter(getTargetPointer().getFirst(game, source), source.getSourceId(), game); game.getStack().counter(getTargetPointer().getFirst(game, source), source.getSourceId(), game);
// mana gets added also if counter is not successful // mana gets added also if counter is not successful
int cmc = spell.getConvertedManaCost(); int cmc = spell.getConvertedManaCost();
Effect effect = new AddManaToManaPoolTargetControllerEffect(new Mana(0, 0, 0, 0, 0, 0, 0, cmc), "your"); Effect effect = new AddManaToManaPoolTargetControllerEffect(Mana.ColorlessMana(cmc), "your");
effect.setTargetPointer(new FixedTarget(source.getControllerId())); effect.setTargetPointer(new FixedTarget(source.getControllerId()));
AtTheBeginOfMainPhaseDelayedTriggeredAbility delayedAbility AtTheBeginOfMainPhaseDelayedTriggeredAbility delayedAbility
= new AtTheBeginOfMainPhaseDelayedTriggeredAbility(effect, false, TargetController.YOU, PhaseSelection.NEXT_MAIN); = new AtTheBeginOfMainPhaseDelayedTriggeredAbility(effect, false, TargetController.YOU, PhaseSelection.NEXT_MAIN);

View file

@ -96,7 +96,7 @@ class ManaEchoesEffect extends OneShotEffect {
} }
} }
if (foundCreatures > 0) { if (foundCreatures > 0) {
controller.getManaPool().addMana(new Mana(0, 0, 0, 0, 0, 0, 0, foundCreatures), game, source); controller.getManaPool().addMana(Mana.ColorlessMana(foundCreatures), game, source);
} }
return true; return true;
} }

View file

@ -111,7 +111,7 @@ class MarkOfSakikoTriggeredAbility extends TriggeredAbilityImpl {
if (((DamagedEvent) event).isCombatDamage()) { if (((DamagedEvent) event).isCombatDamage()) {
if (event.getSourceId().equals(getSourceId())) { if (event.getSourceId().equals(getSourceId())) {
this.getEffects().clear(); this.getEffects().clear();
Effect effect = new AddManaToManaPoolTargetControllerEffect(new Mana(0,event.getAmount(),0,0,0,0,0, 0), "that player", true); Effect effect = new AddManaToManaPoolTargetControllerEffect(Mana.GreenMana(event.getAmount()), "that player", true);
effect.setTargetPointer(new FixedTarget(getControllerId())); effect.setTargetPointer(new FixedTarget(getControllerId()));
effect.setText("add that much {G} to your mana pool. Until end of turn, this mana doesn't empty from your mana pool as steps and phases end"); effect.setText("add that much {G} to your mana pool. Until end of turn, this mana doesn't empty from your mana pool as steps and phases end");
this.addEffect(effect); this.addEffect(effect);

View file

@ -38,7 +38,6 @@ import mage.abilities.common.BeginningOfUpkeepTriggeredAbility;
import mage.abilities.condition.common.TwoOrMoreSpellsWereCastLastTurnCondition; import mage.abilities.condition.common.TwoOrMoreSpellsWereCastLastTurnCondition;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.decorator.ConditionalTriggeredAbility;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.effects.common.TransformSourceEffect; import mage.abilities.effects.common.TransformSourceEffect;
import mage.abilities.keyword.TransformAbility; import mage.abilities.keyword.TransformAbility;
import mage.abilities.keyword.VigilanceAbility; import mage.abilities.keyword.VigilanceAbility;
@ -66,7 +65,7 @@ public class MoonscarredWerewolf extends CardImpl {
this.addAbility(VigilanceAbility.getInstance()); this.addAbility(VigilanceAbility.getInstance());
// {tap}: Add {G}{G} to your mana pool. // {tap}: Add {G}{G} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.GreenMana(2)), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(2), new TapSourceCost()));
// At the beginning of each upkeep, if a player cast two or more spells last turn, transform Moonscarred Werewolf. // At the beginning of each upkeep, if a player cast two or more spells last turn, transform Moonscarred Werewolf.
TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(new TransformSourceEffect(false), TargetController.ANY, false); TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(new TransformSourceEffect(false), TargetController.ANY, false);
this.addAbility(new ConditionalTriggeredAbility(ability, this.addAbility(new ConditionalTriggeredAbility(ability,

View file

@ -46,7 +46,7 @@ public class MyrMoonvessel extends CardImpl {
this.subtype.add("Myr"); this.subtype.add("Myr");
this.power = new MageInt(1); this.power = new MageInt(1);
this.toughness = new MageInt(1); this.toughness = new MageInt(1);
this.addAbility(new DiesTriggeredAbility(new BasicManaEffect(new Mana(0, 0, 0, 0, 0, 0, 0, 1)))); this.addAbility(new DiesTriggeredAbility(new BasicManaEffect(Mana.ColorlessMana(1))));
} }
public MyrMoonvessel(final MyrMoonvessel card) { public MyrMoonvessel(final MyrMoonvessel card) {

View file

@ -86,7 +86,7 @@ class MyrReservoirManaAbility extends BasicManaAbility {
MyrReservoirManaAbility() { MyrReservoirManaAbility() {
super(new BasicManaEffect(new MyrConditionalMana())); super(new BasicManaEffect(new MyrConditionalMana()));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 2)); this.netMana.add(Mana.ColorlessMana(2));
} }
MyrReservoirManaAbility(MyrReservoirManaAbility ability) { MyrReservoirManaAbility(MyrReservoirManaAbility ability) {

View file

@ -33,7 +33,6 @@ import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.costs.common.DiscardCardCost; import mage.abilities.costs.common.DiscardCardCost;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
@ -55,7 +54,7 @@ public class OvereagerApprentice extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// Discard a card, Sacrifice Overeager Apprentice: Add {B}{B}{B} to your mana pool. // Discard a card, Sacrifice Overeager Apprentice: Add {B}{B}{B} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 0, 0, 0, 3, 0, 0, 0)), new DiscardCardCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlackMana(3), new DiscardCardCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -82,7 +82,7 @@ class OvergrowthTriggeredAbility extends TriggeredManaAbility {
public OvergrowthTriggeredAbility() { public OvergrowthTriggeredAbility() {
super(Zone.BATTLEFIELD, new AddManaToManaPoolTargetControllerEffect(new Mana(0,2,0,0,0,0,0, 0), "his or her")); super(Zone.BATTLEFIELD, new AddManaToManaPoolTargetControllerEffect(Mana.GreenMana(2), "his or her"));
} }
public OvergrowthTriggeredAbility(final OvergrowthTriggeredAbility ability) { public OvergrowthTriggeredAbility(final OvergrowthTriggeredAbility ability) {

View file

@ -30,11 +30,12 @@ package mage.cards.p;
import java.util.UUID; import java.util.UUID;
import mage.MageInt; import mage.MageInt;
import mage.Mana; import mage.Mana;
import mage.abilities.effects.common.BasicManaEffect; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.mana.BasicManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
import mage.constants.CardType; import mage.constants.CardType;
import mage.constants.Zone;
/** /**
* *
@ -47,7 +48,7 @@ public class PalladiumMyr extends CardImpl {
this.subtype.add("Myr"); this.subtype.add("Myr");
this.power = new MageInt(2); this.power = new MageInt(2);
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
this.addAbility(new PalladiumMyrAbility()); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(2), new TapSourceCost()));
} }
public PalladiumMyr(final PalladiumMyr card) { public PalladiumMyr(final PalladiumMyr card) {
@ -59,20 +60,3 @@ public class PalladiumMyr extends CardImpl {
return new PalladiumMyr(this); return new PalladiumMyr(this);
} }
} }
class PalladiumMyrAbility extends BasicManaAbility {
public PalladiumMyrAbility() {
super(new BasicManaEffect(Mana.ColorlessMana(2)));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 2));
}
public PalladiumMyrAbility(final PalladiumMyrAbility ability) {
super(ability);
}
@Override
public PalladiumMyrAbility copy() {
return new PalladiumMyrAbility(this);
}
}

View file

@ -53,7 +53,7 @@ public class RadhaHeirToKeld extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// Whenever Radha, Heir to Keld attacks, you may add {R}{R} to your mana pool. // Whenever Radha, Heir to Keld attacks, you may add {R}{R} to your mana pool.
Ability ability = new AttacksTriggeredAbility(new BasicManaEffect(new Mana(2,0,0,0,0,0,0, 0)), true); Ability ability = new AttacksTriggeredAbility(new BasicManaEffect(Mana.RedMana(2)), true);
this.addAbility(ability); this.addAbility(ability);
// {tap}: Add {G} to your mana pool. // {tap}: Add {G} to your mana pool.

View file

@ -198,7 +198,7 @@ class ReflectingPoolEffect extends ManaEffect {
netManas.add(new Mana(ColoredManaSymbol.W)); netManas.add(new Mana(ColoredManaSymbol.W));
} }
if (types.getColorless() > 0) { if (types.getColorless() > 0) {
netManas.add(new Mana(0, 0, 0, 0, 0, 0, 0, 1)); netManas.add(Mana.ColorlessMana(1));
} }
return netManas; return netManas;
} }

View file

@ -50,7 +50,7 @@ public class RoguesPassage extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.LAND},""); super(ownerId,setInfo,new CardType[]{CardType.LAND},"");
// {T}: Add {C} to your mana pool. // {T}: Add {C} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 0, 0, 0, 0, 0, 1), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(1), new TapSourceCost()));
// {4}, {T}: Target creature can't be blocked this turn. // {4}, {T}: Target creature can't be blocked this turn.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantBeBlockedTargetEffect(), new ManaCostsImpl("{4}")); Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantBeBlockedTargetEffect(), new ManaCostsImpl("{4}"));

View file

@ -75,7 +75,7 @@ class RosheenMeandererManaAbility extends BasicManaAbility {
RosheenMeandererManaAbility() { RosheenMeandererManaAbility() {
super(new BasicManaEffect(new RosheenMeandererConditionalMana())); super(new BasicManaEffect(new RosheenMeandererConditionalMana()));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 4)); this.netMana.add(Mana.ColorlessMana(4));
} }
RosheenMeandererManaAbility(RosheenMeandererManaAbility ability) { RosheenMeandererManaAbility(RosheenMeandererManaAbility ability) {

View file

@ -33,7 +33,6 @@ import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.abilities.mana.WhiteManaAbility; import mage.abilities.mana.WhiteManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -55,7 +54,7 @@ public class RuinsOfTrokair extends CardImpl {
// {tap}: Add {W} to your mana pool. // {tap}: Add {W} to your mana pool.
this.addAbility(new WhiteManaAbility()); this.addAbility(new WhiteManaAbility());
// {tap}, Sacrifice Ruins of Trokair: Add {W}{W} to your mana pool. // {tap}, Sacrifice Ruins of Trokair: Add {W}{W} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.WhiteMana(2)), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.WhiteMana(2), new TapSourceCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -32,7 +32,6 @@ import mage.MageInt;
import mage.Mana; import mage.Mana;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.effects.common.continuous.BoostControlledEffect; import mage.abilities.effects.common.continuous.BoostControlledEffect;
import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
@ -71,7 +70,7 @@ public class SachiDaughterOfSeshiro extends CardImpl {
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostControlledEffect(0, 1, Duration.WhileOnBattlefield, snakeFilter, true))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostControlledEffect(0, 1, Duration.WhileOnBattlefield, snakeFilter, true)));
// Shamans you control have "{T}: Add {G}{G} to your mana pool." // Shamans you control have "{T}: Add {G}{G} to your mana pool."
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityControlledEffect( this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityControlledEffect(
new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.GreenMana(2)), new TapSourceCost()), Duration.WhileOnBattlefield, shamanFilter, false))); new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(2), new TapSourceCost()), Duration.WhileOnBattlefield, shamanFilter, false)));
} }
public SachiDaughterOfSeshiro(final SachiDaughterOfSeshiro card) { public SachiDaughterOfSeshiro(final SachiDaughterOfSeshiro card) {

View file

@ -100,7 +100,7 @@ class SakikoMotherOfSummerTriggeredAbility extends TriggeredAbilityImpl {
Permanent creature = game.getPermanent(event.getSourceId()); Permanent creature = game.getPermanent(event.getSourceId());
if (creature != null && creature.getControllerId().equals(controllerId)) { if (creature != null && creature.getControllerId().equals(controllerId)) {
this.getEffects().clear(); this.getEffects().clear();
Effect effect = new AddManaToManaPoolTargetControllerEffect(new Mana(0,event.getAmount(),0,0,0,0,0, 0), "that player", true); Effect effect = new AddManaToManaPoolTargetControllerEffect(Mana.GreenMana(event.getAmount()), "that player", true);
effect.setTargetPointer(new FixedTarget(creature.getControllerId())); effect.setTargetPointer(new FixedTarget(creature.getControllerId()));
effect.setText("add that much {G} to your mana pool. Until end of turn, this mana doesn't empty from your mana pool as steps and phases end"); effect.setText("add that much {G} to your mana pool. Until end of turn, this mana doesn't empty from your mana pool as steps and phases end");
this.addEffect(effect); this.addEffect(effect);

View file

@ -33,7 +33,6 @@ import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.ColorlessManaAbility; import mage.abilities.mana.ColorlessManaAbility;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -58,7 +57,7 @@ public class SeaScryer extends CardImpl {
// {tap}: Add {C} to your mana pool. // {tap}: Add {C} to your mana pool.
this.addAbility(new ColorlessManaAbility()); this.addAbility(new ColorlessManaAbility());
// {1}, {tap}: Add {U} to your mana pool. // {1}, {tap}: Add {U} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.BlueMana(1)), new GenericManaCost(1)); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlueMana(1), new GenericManaCost(1));
ability.addCost(new TapSourceCost()); ability.addCost(new TapSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -43,7 +43,7 @@ public class SeethingSong extends CardImpl {
public SeethingSong(UUID ownerId, CardSetInfo setInfo) { public SeethingSong(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{R}"); super(ownerId,setInfo,new CardType[]{CardType.INSTANT},"{2}{R}");
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(5, 0, 0, 0, 0, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.RedMana(5)));
} }
public SeethingSong(final SeethingSong card) { public SeethingSong(final SeethingSong card) {

View file

@ -49,7 +49,7 @@ public class SeismicSpike extends CardImpl {
// Destroy target land. Add {R}{R} to your mana pool. // Destroy target land. Add {R}{R} to your mana pool.
this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addEffect(new DestroyTargetEffect());
this.getSpellAbility().addTarget(new TargetLandPermanent()); this.getSpellAbility().addTarget(new TargetLandPermanent());
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(2, 0, 0, 0, 0, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.RedMana(2)));
} }
public SeismicSpike(final SeismicSpike card) { public SeismicSpike(final SeismicSpike card) {

View file

@ -31,7 +31,6 @@ import java.util.UUID;
import mage.MageInt; import mage.MageInt;
import mage.Mana; import mage.Mana;
import mage.abilities.costs.common.TapTargetCost; import mage.abilities.costs.common.TapTargetCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
@ -66,9 +65,8 @@ public class SetonKrosanProtector extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// Tap an untapped Druid you control: Add {G} to your mana pool. // Tap an untapped Druid you control: Add {G} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.GreenMana(1),
new BasicManaEffect(Mana.GreenMana(1)), new TapTargetCost(new TargetControlledCreaturePermanent(1, 1, filter, true))));
new TapTargetCost(new TargetControlledCreaturePermanent(1, 1, filter, true))));
} }
public SetonKrosanProtector(final SetonKrosanProtector card) { public SetonKrosanProtector(final SetonKrosanProtector card) {

View file

@ -55,7 +55,7 @@ public class ShizukoCallerOfAutumn extends CardImpl {
this.toughness = new MageInt(3); this.toughness = new MageInt(3);
// At the beginning of each player's upkeep, that player adds {G}{G}{G} to his or her mana pool. Until end of turn, this mana doesn't empty from that player's mana pool as steps and phases end. // At the beginning of each player's upkeep, that player adds {G}{G}{G} to his or her mana pool. Until end of turn, this mana doesn't empty from that player's mana pool as steps and phases end.
Effect effect = new AddManaToManaPoolTargetControllerEffect(new Mana(0,3,0,0,0,0,0, 0), "that player", true); Effect effect = new AddManaToManaPoolTargetControllerEffect(Mana.GreenMana(3), "that player", true);
effect.setText("that player adds {G}{G}{G} to his or her mana pool. Until end of turn, this mana doesn't empty from that player's mana pool as steps and phases end"); effect.setText("that player adds {G}{G}{G} to his or her mana pool. Until end of turn, this mana doesn't empty from that player's mana pool as steps and phases end");
this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.ANY, false)); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.ANY, false));

View file

@ -35,7 +35,6 @@ import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.costs.Cost; import mage.abilities.costs.Cost;
import mage.abilities.costs.CostImpl; import mage.abilities.costs.CostImpl;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.Card; import mage.cards.Card;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -59,7 +58,7 @@ public class SimianSpiritGuide extends CardImpl {
this.toughness = new MageInt(2); this.toughness = new MageInt(2);
// Exile Simian Spirit Guide from your hand: Add {R} to your mana pool. // Exile Simian Spirit Guide from your hand: Add {R} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.HAND, new BasicManaEffect(Mana.RedMana(1)), new ExileSourceFromHandCost())); this.addAbility(new SimpleManaAbility(Zone.HAND, Mana.RedMana(1), new ExileSourceFromHandCost()));
} }
public SimianSpiritGuide(final SimianSpiritGuide card) { public SimianSpiritGuide(final SimianSpiritGuide card) {

View file

@ -46,7 +46,7 @@ public class SisaysRing extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{4}"); super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{4}");
// {tap}: Add {C}{C} to your mana pool. // {tap}: Add {C}{C} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 0, 0, 0, 0, 0, 2), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(2), new TapSourceCost()));
} }
public SisaysRing(final SisaysRing card) { public SisaysRing(final SisaysRing card) {

View file

@ -51,7 +51,7 @@ public class SithCitadel extends CardImpl {
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
// When Sith Citadel enters the battlefield , add {B} to your mana pool. // When Sith Citadel enters the battlefield , add {B} to your mana pool.
this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(new Mana(0, 0, 0, 0, 1, 0, 0, 0)))); this.addAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(Mana.BlackMana(1))));
// {T}: Add {U} or {R} to you mana pool. // {T}: Add {U} or {R} to you mana pool.
this.addAbility(new BlueManaAbility()); this.addAbility(new BlueManaAbility());

View file

@ -29,11 +29,12 @@ package mage.cards.s;
import java.util.UUID; import java.util.UUID;
import mage.Mana; import mage.Mana;
import mage.abilities.effects.common.BasicManaEffect; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.mana.BasicManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
import mage.constants.CardType; import mage.constants.CardType;
import mage.constants.Zone;
/** /**
* *
@ -43,7 +44,7 @@ public class SolRing extends CardImpl {
public SolRing(UUID ownerId, CardSetInfo setInfo) { public SolRing(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{1}"); super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{1}");
this.addAbility(new SolRingAbility()); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(2), new TapSourceCost()));
} }
public SolRing(final SolRing card) { public SolRing(final SolRing card) {
@ -55,20 +56,3 @@ public class SolRing extends CardImpl {
return new SolRing(this); return new SolRing(this);
} }
} }
class SolRingAbility extends BasicManaAbility {
public SolRingAbility() {
super(new BasicManaEffect(Mana.ColorlessMana(2)));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 2));
}
public SolRingAbility(final SolRingAbility ability) {
super(ability);
}
@Override
public SolRingAbility copy() {
return new SolRingAbility(this);
}
}

View file

@ -121,7 +121,7 @@ class SoulbrightFlamekinEffect extends OneShotEffect {
} }
info.activations++; info.activations++;
if (info.activations == 3) { if (info.activations == 3) {
controller.getManaPool().addMana(new Mana(8,0,0,0,0,0,0, 0), game, source); controller.getManaPool().addMana(Mana.RedMana(8), game, source);
} }
return true; return true;
} }

View file

@ -184,7 +184,7 @@ class SquanderedResourcesEffect extends ManaEffect {
netManas.add(new Mana(ColoredManaSymbol.W)); netManas.add(new Mana(ColoredManaSymbol.W));
} }
if (types.getGeneric() > 0) { if (types.getGeneric() > 0) {
netManas.add(new Mana(0, 0, 0, 0, 0, 0, 0, 1)); netManas.add(Mana.ColorlessMana(1));
} }
return netManas; return netManas;
} }

View file

@ -202,7 +202,7 @@ class StarCompassManaEffect extends ManaEffect {
netManas.add(new Mana(ColoredManaSymbol.W)); netManas.add(new Mana(ColoredManaSymbol.W));
} }
if (types.getGeneric() > 0) { if (types.getGeneric() > 0) {
netManas.add(new Mana(0, 0, 0, 0, 0, 0, 0, 1)); netManas.add(Mana.ColorlessMana(1));
} }
return netManas; return netManas;
} }

View file

@ -50,7 +50,7 @@ public class SuChi extends CardImpl {
this.toughness = new MageInt(4); this.toughness = new MageInt(4);
// When Su-Chi dies, add {C}{C}{C}{C} to your mana pool. // When Su-Chi dies, add {C}{C}{C}{C} to your mana pool.
this.addAbility(new DiesTriggeredAbility(new BasicManaEffect(new Mana(0, 0, 0, 0, 0, 0, 0, 4)), false)); this.addAbility(new DiesTriggeredAbility(new BasicManaEffect(Mana.ColorlessMana(4)), false));
} }
public SuChi(final SuChi card) { public SuChi(final SuChi card) {

View file

@ -33,7 +33,6 @@ import mage.abilities.Ability;
import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.mana.BlueManaAbility; import mage.abilities.mana.BlueManaAbility;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -55,7 +54,7 @@ public class SvyeluniteTemple extends CardImpl {
// {tap}: Add {U} to your mana pool. // {tap}: Add {U} to your mana pool.
this.addAbility(new BlueManaAbility()); this.addAbility(new BlueManaAbility());
// {tap}, Sacrifice Svyelunite Temple: Add {U}{U} to your mana pool. // {tap}, Sacrifice Svyelunite Temple: Add {U}{U} to your mana pool.
Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.BlueMana(2)), new TapSourceCost()); Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlueMana(2), new TapSourceCost());
ability.addCost(new SacrificeSourceCost()); ability.addCost(new SacrificeSourceCost());
this.addAbility(ability); this.addAbility(ability);
} }

View file

@ -53,7 +53,7 @@ public class TeferisIsle extends CardImpl {
// Teferi's Isle enters the battlefield tapped. // Teferi's Isle enters the battlefield tapped.
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
// {tap}: Add {U}{U} to your mana pool. // {tap}: Add {U}{U} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 2, 0, 0, 0, 0, 0), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.BlueMana(2), new TapSourceCost()));
} }

View file

@ -34,7 +34,6 @@ import mage.abilities.Ability;
import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleActivatedAbility;
import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.SacrificeSourceCost;
import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.common.BasicManaEffect;
import mage.abilities.effects.common.DamageTargetEffect; import mage.abilities.effects.common.DamageTargetEffect;
import mage.abilities.keyword.DefenderAbility; import mage.abilities.keyword.DefenderAbility;
import mage.abilities.mana.SimpleManaAbility; import mage.abilities.mana.SimpleManaAbility;
@ -70,7 +69,7 @@ public class TinderWall extends CardImpl {
// Defender // Defender
this.addAbility(DefenderAbility.getInstance()); this.addAbility(DefenderAbility.getInstance());
// Sacrifice Tinder Wall: Add {R}{R} to your mana pool. // Sacrifice Tinder Wall: Add {R}{R} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.RedMana(2)), new SacrificeSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.RedMana(2), new SacrificeSourceCost()));
// {R}, Sacrifice Tinder Wall: Tinder Wall deals 2 damage to target creature it's blocking. // {R}, Sacrifice Tinder Wall: Tinder Wall deals 2 damage to target creature it's blocking.
FilterAttackingCreature filter = new FilterAttackingCreature("creature it's blocking"); FilterAttackingCreature filter = new FilterAttackingCreature("creature it's blocking");
filter.add(new BlockedByIdPredicate(this.getId())); filter.add(new BlockedByIdPredicate(this.getId()));

View file

@ -55,7 +55,7 @@ public class TurnToDust extends CardImpl {
this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addEffect(new DestroyTargetEffect());
this.getSpellAbility().addTarget(new TargetPermanent(filter)); this.getSpellAbility().addTarget(new TargetPermanent(filter));
this.getSpellAbility().addEffect(new BasicManaEffect(new Mana(0, 1, 0, 0, 0, 0, 0, 0))); this.getSpellAbility().addEffect(new BasicManaEffect(Mana.GreenMana(1)));
} }
public TurnToDust(final TurnToDust card) { public TurnToDust(final TurnToDust card) {

View file

@ -46,7 +46,7 @@ public class UrGolemsEye extends CardImpl {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{4}"); super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{4}");
// {tap}: Add {C}{C} to your mana pool. // {tap}: Add {C}{C} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 0, 0, 0, 0, 0, 2), new TapSourceCost())); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(2), new TapSourceCost()));
} }
public UrGolemsEye(final UrGolemsEye card) { public UrGolemsEye(final UrGolemsEye card) {

View file

@ -74,7 +74,7 @@ public class Valleymaker extends CardImpl {
this.addAbility(ability); this.addAbility(ability);
// {tap}, Sacrifice a Forest: Choose a player. That player adds {G}{G}{G} to his or her mana pool. // {tap}, Sacrifice a Forest: Choose a player. That player adds {G}{G}{G} to his or her mana pool.
Ability ability2 = new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaToManaPoolTargetControllerEffect(new Mana(0,3,0,0,0,0,0, 0), "chosen player"), new TapSourceCost()); Ability ability2 = new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaToManaPoolTargetControllerEffect(Mana.GreenMana(3), "chosen player"), new TapSourceCost());
ability2.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter2))); ability2.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter2)));
ability2.addTarget(new TargetPlayer(1, 1, true)); ability2.addTarget(new TargetPlayer(1, 1, true));
this.addAbility(ability2); this.addAbility(ability2);

View file

@ -112,7 +112,7 @@ class WasteNotCreatureTriggeredAbility extends TriggeredAbilityImpl {
class WasteNotLandTriggeredAbility extends TriggeredAbilityImpl { class WasteNotLandTriggeredAbility extends TriggeredAbilityImpl {
WasteNotLandTriggeredAbility() { WasteNotLandTriggeredAbility() {
super(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 0, 0, 0, 2, 0, 0, 0)), false); super(Zone.BATTLEFIELD, new BasicManaEffect(Mana.BlackMana(2)), false);
} }
WasteNotLandTriggeredAbility(final WasteNotLandTriggeredAbility ability) { WasteNotLandTriggeredAbility(final WasteNotLandTriggeredAbility ability) {

View file

@ -64,7 +64,7 @@ public class WitchEngine extends CardImpl {
this.addAbility(new SwampwalkAbility()); this.addAbility(new SwampwalkAbility());
// {tap}: Add {B}{B}{B}{B} to your mana pool. Target opponent gains control of Witch Engine. // {tap}: Add {B}{B}{B}{B} to your mana pool. Target opponent gains control of Witch Engine.
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 0, 0, 0, 4, 0, 0, 0)), new TapSourceCost()); Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BasicManaEffect(Mana.BlackMana(4)), new TapSourceCost());
ability.addEffect(new WitchEngineEffect()); ability.addEffect(new WitchEngineEffect());
ability.addTarget(new TargetOpponent()); ability.addTarget(new TargetOpponent());
this.addAbility(ability); this.addAbility(ability);

View file

@ -56,8 +56,7 @@ public class Workhorse extends CardImpl {
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(4)), "with four +1/+1 counters on it")); this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(4)), "with four +1/+1 counters on it"));
// Remove a +1/+1 counter from Workhorse: Add {C} to your mana pool. // Remove a +1/+1 counter from Workhorse: Add {C} to your mana pool.
this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(1),
new Mana(new Mana(0, 0, 0, 0, 0, 0, 0, 1)),
new RemoveCountersSourceCost(CounterType.P1P1.createInstance()))); new RemoveCountersSourceCost(CounterType.P1P1.createInstance())));
} }

View file

@ -30,11 +30,12 @@ package mage.cards.w;
import java.util.UUID; import java.util.UUID;
import mage.Mana; import mage.Mana;
import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.EntersBattlefieldTappedAbility;
import mage.abilities.effects.common.BasicManaEffect; import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.mana.BasicManaAbility; import mage.abilities.mana.SimpleManaAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.cards.CardSetInfo; import mage.cards.CardSetInfo;
import mage.constants.CardType; import mage.constants.CardType;
import mage.constants.Zone;
/** /**
* *
@ -45,7 +46,7 @@ public class WornPowerstone extends CardImpl {
public WornPowerstone(UUID ownerId, CardSetInfo setInfo) { public WornPowerstone(UUID ownerId, CardSetInfo setInfo) {
super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{3}"); super(ownerId,setInfo,new CardType[]{CardType.ARTIFACT},"{3}");
this.addAbility(new EntersBattlefieldTappedAbility()); this.addAbility(new EntersBattlefieldTappedAbility());
this.addAbility(new WornPowerstoneAbility()); this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(2), new TapSourceCost()));
} }
public WornPowerstone(final WornPowerstone card) { public WornPowerstone(final WornPowerstone card) {
@ -57,20 +58,3 @@ public class WornPowerstone extends CardImpl {
return new WornPowerstone(this); return new WornPowerstone(this);
} }
} }
class WornPowerstoneAbility extends BasicManaAbility {
public WornPowerstoneAbility() {
super(new BasicManaEffect(Mana.ColorlessMana(2)));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 2));
}
public WornPowerstoneAbility(final WornPowerstoneAbility ability) {
super(ability);
}
@Override
public WornPowerstoneAbility copy() {
return new WornPowerstoneAbility(this);
}
}

View file

@ -56,6 +56,6 @@ public class AddConditionalColorlessManaEffect extends ManaEffect {
} }
public Mana getMana() { public Mana getMana() {
return new Mana(0, 0, 0, 0, 0, 0, 0, amount); return Mana.ColorlessMana(amount);
} }
} }

View file

@ -188,7 +188,7 @@ class AnyColorLandsProduceManaEffect extends ManaEffect {
netManas.add(new Mana(ColoredManaSymbol.W)); netManas.add(new Mana(ColoredManaSymbol.W));
} }
if (types.getColorless() > 0) { if (types.getColorless() > 0) {
netManas.add(new Mana(0, 0, 0, 0, 0, 0, 0, 1)); netManas.add(Mana.ColorlessMana(1));
} }
return netManas; return netManas;
} }

View file

@ -38,7 +38,7 @@ public class ColorlessManaAbility extends BasicManaAbility {
public ColorlessManaAbility() { public ColorlessManaAbility() {
super(new BasicManaEffect(Mana.ColorlessMana(1))); super(new BasicManaEffect(Mana.ColorlessMana(1)));
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, 1)); this.netMana.add(Mana.ColorlessMana(1));
} }
public ColorlessManaAbility(ColorlessManaAbility ability) { public ColorlessManaAbility(ColorlessManaAbility ability) {

View file

@ -24,7 +24,7 @@ public class ConditionalColorlessManaAbility extends ManaAbility {
public ConditionalColorlessManaAbility(Cost cost, int amount, ConditionalManaBuilder manaBuilder) { public ConditionalColorlessManaAbility(Cost cost, int amount, ConditionalManaBuilder manaBuilder) {
super(Zone.BATTLEFIELD, new AddConditionalColorlessManaEffect(amount, manaBuilder), cost); super(Zone.BATTLEFIELD, new AddConditionalColorlessManaEffect(amount, manaBuilder), cost);
this.netMana.add(new Mana(0, 0, 0, 0, 0, 0, 0, amount)); this.netMana.add(Mana.ColorlessMana(amount));
} }
public ConditionalColorlessManaAbility(final ConditionalColorlessManaAbility ability) { public ConditionalColorlessManaAbility(final ConditionalColorlessManaAbility ability) {

View file

@ -317,7 +317,7 @@ public class ManaOptions extends ArrayList<Mana> {
} }
} }
} else { } else {
payCombinations.add(new Mana(0, 0, 0, 0, 0, 0, 0, number)); payCombinations.add(Mana.ColorlessMana(number));
} }
return payCombinations; return payCombinations;
} }