From 781738ecec18397937dc3ce6010b6340d3859405 Mon Sep 17 00:00:00 2001 From: North Date: Sun, 21 Aug 2011 16:18:31 +0300 Subject: [PATCH] Refactoring (appended Condition to the name of every ConditionImpl). Fixed EquippedCondition and EnchantedCondition. --- .../mage/sets/alarareborn/GloryOfWarfare.java | 8 +-- .../championsofkamigawa/AkkiLavarunner.java | 4 +- .../championsofkamigawa/BudokaGardener.java | 4 +- .../NezumiGraverobber.java | 4 +- .../mage/sets/conflux/TukatongueThallid.java | 15 +---- .../sets/darksteel/AuriokGlaivemaster.java | 11 ++-- .../mage/sets/dissension/FlaringFlameKin.java | 4 +- .../sets/dissension/FreewindEquenaut.java | 4 +- .../mage/sets/dissension/RakdosPitDragon.java | 11 ++-- .../mage/sets/guildpact/SkyriderTrainee.java | 4 +- .../sets/magic2010/DragonskullSummit.java | 6 +- .../mage/sets/magic2010/DrownedCatacomb.java | 6 +- .../mage/sets/magic2010/GlacialFortress.java | 6 +- .../mage/sets/magic2010/RootboundCrag.java | 6 +- .../mage/sets/magic2010/SunpetalGrove.java | 6 +- .../mage/sets/magic2012/CallToTheGrave.java | 4 +- .../src/mage/sets/magic2012/GriffinRider.java | 4 +- .../mage/sets/magic2012/PrimordialHydra.java | 4 +- .../src/mage/sets/magic2012/ThranGolem.java | 4 +- .../sets/mirrodinbesieged/ArdentRecruit.java | 4 +- .../sets/mirrodinbesieged/ConcussiveBolt.java | 4 +- .../sets/mirrodinbesieged/MirranMettle.java | 4 +- .../mirrodinbesieged/RazorfieldRhino.java | 4 +- .../mirrodinbesieged/SpiralingDuelist.java | 4 +- .../src/mage/sets/newphyrexia/Dispatch.java | 4 +- .../newphyrexia/JorKadeenThePrevailer.java | 4 +- .../sets/newphyrexia/PuresteelPaladin.java | 4 +- .../src/mage/sets/ravnika/GateHound.java | 4 +- .../scarsofmirrodin/AuriokEdgewright.java | 4 +- .../sets/scarsofmirrodin/AuriokSunchaser.java | 6 +- .../scarsofmirrodin/BlackcleaveCliffs.java | 6 +- .../scarsofmirrodin/BladeTribeBerserkers.java | 4 +- .../scarsofmirrodin/BleakCovenVampires.java | 4 +- .../sets/scarsofmirrodin/CarapaceForger.java | 4 +- .../sets/scarsofmirrodin/ChromeSteed.java | 4 +- .../sets/scarsofmirrodin/CopperlineGorge.java | 6 +- .../sets/scarsofmirrodin/DarkslickShores.java | 6 +- .../sets/scarsofmirrodin/DispenseJustice.java | 4 +- .../sets/scarsofmirrodin/EtchedChampion.java | 4 +- .../sets/scarsofmirrodin/EzurisBrigade.java | 6 +- .../sets/scarsofmirrodin/GalvanicBlast.java | 4 +- .../sets/scarsofmirrodin/GhalmasWarden.java | 4 +- .../scarsofmirrodin/IndomitableArchangel.java | 4 +- .../sets/scarsofmirrodin/LumengridDrake.java | 4 +- .../sets/scarsofmirrodin/MoltenPsyche.java | 4 +- .../scarsofmirrodin/RazorvergeThicket.java | 6 +- .../sets/scarsofmirrodin/RustedRelic.java | 4 +- .../scarsofmirrodin/ScrapdiverSerpent.java | 2 +- .../scarsofmirrodin/ScreechingSilcaw.java | 4 +- .../sets/scarsofmirrodin/SeachromeCoast.java | 6 +- .../sets/scarsofmirrodin/SnapsailGlider.java | 4 +- .../sets/scarsofmirrodin/StoicRebuttal.java | 4 +- .../sets/scarsofmirrodin/SunspearShikari.java | 4 +- .../sets/worldwake/KitesailApprentice.java | 4 +- .../src/mage/sets/worldwake/LoamLion.java | 4 +- .../sets/worldwake/RuthlessCullblade.java | 4 +- .../mage/sets/worldwake/SejiriMerfolk.java | 4 +- .../src/mage/sets/zendikar/Bloodghast.java | 6 +- .../mage/sets/zendikar/GuulDrazVampire.java | 4 +- .../mage/sets/zendikar/VampireLacerator.java | 8 +-- .../common/CreateTokenActivatedAbility.java | 56 ------------------- ...t.java => ControlsPermanentCondition.java} | 8 +-- ...Enchanted.java => EnchantedCondition.java} | 5 +- .../{Equipped.java => EquippedCondition.java} | 5 +- .../{Flipped.java => FlippedCondition.java} | 4 +- ...eCounter.java => HasCounterCondition.java} | 6 +- .../{Hellbent.java => HellbentCondition.java} | 4 +- ...talcraft.java => MetalcraftCondition.java} | 4 +- .../{MyTurn.java => MyTurnCondition.java} | 4 +- ...Creature.java => NoCreatureCondition.java} | 5 +- ...NotMyTurn.java => NotMyTurnCondition.java} | 4 +- ...sLife.java => TenOrLessLifeCondition.java} | 4 +- .../{Unless.java => UnlessCondition.java} | 4 +- .../BoostSourceWhileControlsEffect.java | 4 +- .../abilities/keyword/ReboundAbility.java | 4 +- Mage/src/mage/players/Library.java | 7 +-- 76 files changed, 177 insertions(+), 248 deletions(-) delete mode 100644 Mage/src/mage/abilities/common/CreateTokenActivatedAbility.java rename Mage/src/mage/abilities/condition/common/{ControlsPermanent.java => ControlsPermanentCondition.java} (90%) rename Mage/src/mage/abilities/condition/common/{Enchanted.java => EnchantedCondition.java} (94%) rename Mage/src/mage/abilities/condition/common/{Equipped.java => EquippedCondition.java} (92%) rename Mage/src/mage/abilities/condition/common/{Flipped.java => FlippedCondition.java} (92%) rename Mage/src/mage/abilities/condition/common/{HaveCounter.java => HasCounterCondition.java} (92%) rename Mage/src/mage/abilities/condition/common/{Hellbent.java => HellbentCondition.java} (92%) rename Mage/src/mage/abilities/condition/common/{Metalcraft.java => MetalcraftCondition.java} (80%) rename Mage/src/mage/abilities/condition/common/{MyTurn.java => MyTurnCondition.java} (92%) rename Mage/src/mage/abilities/condition/common/{NoCreature.java => NoCreatureCondition.java} (90%) rename Mage/src/mage/abilities/condition/common/{NotMyTurn.java => NotMyTurnCondition.java} (91%) rename Mage/src/mage/abilities/condition/common/{TenOrLessLife.java => TenOrLessLifeCondition.java} (95%) rename Mage/src/mage/abilities/condition/common/{Unless.java => UnlessCondition.java} (95%) diff --git a/Mage.Sets/src/mage/sets/alarareborn/GloryOfWarfare.java b/Mage.Sets/src/mage/sets/alarareborn/GloryOfWarfare.java index 2345775b56..411cd6ba89 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/GloryOfWarfare.java +++ b/Mage.Sets/src/mage/sets/alarareborn/GloryOfWarfare.java @@ -35,8 +35,8 @@ import mage.Constants.Duration; import mage.Constants.Rarity; import mage.Constants.Zone; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.MyTurn; -import mage.abilities.condition.common.NotMyTurn; +import mage.abilities.condition.common.MyTurnCondition; +import mage.abilities.condition.common.NotMyTurnCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.BoostControlledEffect; import mage.cards.CardImpl; @@ -52,8 +52,8 @@ public class GloryOfWarfare extends CardImpl { this.expansionSetCode = "ARB"; this.color.setRed(true); this.color.setWhite(true); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(new BoostControlledEffect(2, 0, Duration.EndOfTurn), MyTurn.getInstance(), "As long as it's your turn, creatures you control get +2/+0"))); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(new BoostControlledEffect(0, 2, Duration.EndOfTurn), NotMyTurn.getInstance(), "As long as it's not your turn, creatures you control get +0/+2"))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(new BoostControlledEffect(2, 0, Duration.EndOfTurn), MyTurnCondition.getInstance(), "As long as it's your turn, creatures you control get +2/+0"))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(new BoostControlledEffect(0, 2, Duration.EndOfTurn), NotMyTurnCondition.getInstance(), "As long as it's not your turn, creatures you control get +0/+2"))); } public GloryOfWarfare (final GloryOfWarfare card) { diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java b/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java index 6bb8aedbaa..8d9e49c561 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java @@ -6,7 +6,7 @@ import mage.ObjectColor; import mage.abilities.Ability; import mage.abilities.TriggeredAbilityImpl; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Flipped; +import mage.abilities.condition.common.FlippedCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ReplacementEffectImpl; import mage.abilities.effects.common.CopyTokenEffect; @@ -40,7 +40,7 @@ public class AkkiLavarunner extends CardImpl { this.toughness = new MageInt(1); this.addAbility(HasteAbility.getInstance()); this.addAbility(new AkkiLavarunnerAbility()); - this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new CopyTokenEffect(new TokTokVolcanoBorn()), Flipped.getInstance(), ""))); + this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new CopyTokenEffect(new TokTokVolcanoBorn()), FlippedCondition.getInstance(), ""))); } public AkkiLavarunner(final AkkiLavarunner card) { diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/BudokaGardener.java b/Mage.Sets/src/mage/sets/championsofkamigawa/BudokaGardener.java index 9e9768bbce..768f32181b 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/BudokaGardener.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/BudokaGardener.java @@ -36,7 +36,7 @@ import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Flipped; +import mage.abilities.condition.common.FlippedCondition; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.decorator.ConditionalContinousEffect; @@ -70,7 +70,7 @@ public class BudokaGardener extends CardImpl { Ability ability = new SimpleActivatedAbility(Constants.Zone.BATTLEFIELD, new BudokaGardenerEffect(), new TapSourceCost()); ability.addTarget(new TargetCardInHand(new FilterLandCard())); this.addAbility(ability); - this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new CopyTokenEffect(new DokaiWeaverofLife()), Flipped.getInstance(), ""))); + this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new CopyTokenEffect(new DokaiWeaverofLife()), FlippedCondition.getInstance(), ""))); } public BudokaGardener(final BudokaGardener card) { diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/NezumiGraverobber.java b/Mage.Sets/src/mage/sets/championsofkamigawa/NezumiGraverobber.java index ae0e63720f..584be30af1 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/NezumiGraverobber.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/NezumiGraverobber.java @@ -36,7 +36,7 @@ import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Flipped; +import mage.abilities.condition.common.FlippedCondition; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.decorator.ConditionalContinousEffect; @@ -70,7 +70,7 @@ public class NezumiGraverobber extends CardImpl { ability.addTarget(new TargetCardInOpponentsGraveyard(new FilterCard())); ability.addEffect(new NezumiGraverobberFlipEffect()); this.addAbility(ability); - this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new CopyTokenEffect(new NighteyesTheDesecratorToken()), Flipped.getInstance(), ""))); + this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new CopyTokenEffect(new NighteyesTheDesecratorToken()), FlippedCondition.getInstance(), ""))); } public NezumiGraverobber(final NezumiGraverobber card) { diff --git a/Mage.Sets/src/mage/sets/conflux/TukatongueThallid.java b/Mage.Sets/src/mage/sets/conflux/TukatongueThallid.java index eb18fbfa2f..2e618f5ed6 100644 --- a/Mage.Sets/src/mage/sets/conflux/TukatongueThallid.java +++ b/Mage.Sets/src/mage/sets/conflux/TukatongueThallid.java @@ -35,7 +35,7 @@ import mage.MageInt; import mage.abilities.common.DiesTriggeredAbility; import mage.abilities.effects.common.CreateTokenEffect; import mage.cards.CardImpl; -import mage.game.permanent.token.Token; +import mage.game.permanent.token.SaprolingToken; /** * @@ -49,7 +49,7 @@ public class TukatongueThallid extends CardImpl { this.color.setGreen(true); this.subtype.add("Fungus"); this.power = new MageInt(1); - this.toughness = new MageInt(1); + this.toughness = new MageInt(1); this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new SaprolingToken()), false)); } @@ -62,15 +62,4 @@ public class TukatongueThallid extends CardImpl { public TukatongueThallid copy() { return new TukatongueThallid(this); } - - private class SaprolingToken extends Token { - public SaprolingToken() { - super("Saproling", "1/1 green Saproling creature tokens"); - cardType.add(CardType.CREATURE); - subtype.add("Saproling"); - color.setGreen(true); - power = new MageInt(1); - toughness = new MageInt(1); - } - } } diff --git a/Mage.Sets/src/mage/sets/darksteel/AuriokGlaivemaster.java b/Mage.Sets/src/mage/sets/darksteel/AuriokGlaivemaster.java index b0ff0862c9..35c885af31 100644 --- a/Mage.Sets/src/mage/sets/darksteel/AuriokGlaivemaster.java +++ b/Mage.Sets/src/mage/sets/darksteel/AuriokGlaivemaster.java @@ -32,14 +32,14 @@ import java.util.UUID; import mage.Constants; import mage.Constants.CardType; import mage.Constants.Rarity; +import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.condition.common.Equipped; +import mage.abilities.condition.common.EquippedCondition; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; import mage.abilities.keyword.FirstStrikeAbility; -import mage.abilities.keyword.LifelinkAbility; import mage.cards.CardImpl; /** @@ -47,7 +47,7 @@ import mage.cards.CardImpl; * @author Loki */ public class AuriokGlaivemaster extends CardImpl { - private final static String cardRule = "As long as {this} is equipped, it gets +1/+1 and has first strike"; + private static final String cardRule = "As long as {this} is equipped, it gets +1/+1 and has first strike"; public AuriokGlaivemaster(UUID ownerId) { super(ownerId, 1, "Auriok Glaivemaster", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{W}"); @@ -59,7 +59,10 @@ public class AuriokGlaivemaster extends CardImpl { this.power = new MageInt(1); this.toughness = new MageInt(1); - Ability ability = new ConditionalStaticAbility(Constants.Zone.BATTLEFIELD, new BoostSourceEffect(1, 1, Constants.Duration.WhileOnBattlefield), Equipped.getInstance(), cardRule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, + new BoostSourceEffect(1, 1, Constants.Duration.WhileOnBattlefield), + EquippedCondition.getInstance(), + cardRule); ability.addEffect(new GainAbilitySourceEffect(FirstStrikeAbility.getInstance())); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/dissension/FlaringFlameKin.java b/Mage.Sets/src/mage/sets/dissension/FlaringFlameKin.java index 2808db955c..6ca0f5ff38 100644 --- a/Mage.Sets/src/mage/sets/dissension/FlaringFlameKin.java +++ b/Mage.Sets/src/mage/sets/dissension/FlaringFlameKin.java @@ -35,7 +35,7 @@ import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; -import mage.abilities.condition.common.Enchanted; +import mage.abilities.condition.common.EnchantedCondition; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -61,7 +61,7 @@ public class FlaringFlameKin extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(2); - Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield), Enchanted.getInstance(), rule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield), EnchantedCondition.getInstance(), rule); ability.addEffect(new GainAbilitySourceEffect(TrampleAbility.getInstance())); SimpleActivatedAbility grantedAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), diff --git a/Mage.Sets/src/mage/sets/dissension/FreewindEquenaut.java b/Mage.Sets/src/mage/sets/dissension/FreewindEquenaut.java index 0e1b26ffae..4ea8e2e682 100644 --- a/Mage.Sets/src/mage/sets/dissension/FreewindEquenaut.java +++ b/Mage.Sets/src/mage/sets/dissension/FreewindEquenaut.java @@ -35,7 +35,7 @@ import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Enchanted; +import mage.abilities.condition.common.EnchantedCondition; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.DamageTargetEffect; @@ -78,7 +78,7 @@ public class FreewindEquenaut extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new GainAbilitySourceEffect(ability, Duration.WhileOnBattlefield), - Enchanted.getInstance(), + EnchantedCondition.getInstance(), "As long as {this} is enchanted, it has \"{tap}: {this} deals 2 damage to target attacking or blocking creature\""))); } diff --git a/Mage.Sets/src/mage/sets/dissension/RakdosPitDragon.java b/Mage.Sets/src/mage/sets/dissension/RakdosPitDragon.java index 9f38b9a62f..5eed6d542b 100644 --- a/Mage.Sets/src/mage/sets/dissension/RakdosPitDragon.java +++ b/Mage.Sets/src/mage/sets/dissension/RakdosPitDragon.java @@ -30,13 +30,14 @@ package mage.sets.dissension; import java.util.UUID; -import mage.Constants; import mage.Constants.CardType; +import mage.Constants.Duration; import mage.Constants.Rarity; +import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Hellbent; +import mage.abilities.condition.common.HellbentCondition; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -58,9 +59,9 @@ public class RakdosPitDragon extends CardImpl { this.color.setRed(true); this.power = new MageInt(3); this.toughness = new MageInt(3); - this.addAbility(new SimpleActivatedAbility(Constants.Zone.BATTLEFIELD, new GainAbilitySourceEffect(FlyingAbility.getInstance(), Constants.Duration.EndOfTurn), new ManaCostsImpl("{R}{R}"))); - this.addAbility(new SimpleActivatedAbility(Constants.Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Constants.Duration.EndOfTurn), new ManaCostsImpl("{R}"))); - this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new GainAbilitySourceEffect(DoubleStrikeAbility.getInstance(), Constants.Duration.WhileOnBattlefield), Hellbent.getInstance(), "Hellbent - Rakdos Pit Dragon has double strike as long as you have no cards in hand"))); + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{R}{R}"))); + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{R}"))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(new GainAbilitySourceEffect(DoubleStrikeAbility.getInstance(), Duration.WhileOnBattlefield), HellbentCondition.getInstance(), "Hellbent - Rakdos Pit Dragon has double strike as long as you have no cards in hand"))); } public RakdosPitDragon (final RakdosPitDragon card) { diff --git a/Mage.Sets/src/mage/sets/guildpact/SkyriderTrainee.java b/Mage.Sets/src/mage/sets/guildpact/SkyriderTrainee.java index 262d368011..89fb63008d 100644 --- a/Mage.Sets/src/mage/sets/guildpact/SkyriderTrainee.java +++ b/Mage.Sets/src/mage/sets/guildpact/SkyriderTrainee.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Enchanted; +import mage.abilities.condition.common.EnchantedCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; import mage.abilities.keyword.FlyingAbility; @@ -59,7 +59,7 @@ public class SkyriderTrainee extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.WhileOnBattlefield), - Enchanted.getInstance(), + EnchantedCondition.getInstance(), "{this} has flying as long as it's enchanted"))); } diff --git a/Mage.Sets/src/mage/sets/magic2010/DragonskullSummit.java b/Mage.Sets/src/mage/sets/magic2010/DragonskullSummit.java index c72941864b..36466afb46 100644 --- a/Mage.Sets/src/mage/sets/magic2010/DragonskullSummit.java +++ b/Mage.Sets/src/mage/sets/magic2010/DragonskullSummit.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.BlackManaAbility; @@ -62,7 +62,7 @@ public class DragonskullSummit extends CardImpl { super(ownerId, 223, "Dragonskull Summit", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "M10"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.MORE_THAN, 0)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.MORE_THAN, 0)); String abilityText = "tap it unless you control a " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new BlackManaAbility()); diff --git a/Mage.Sets/src/mage/sets/magic2010/DrownedCatacomb.java b/Mage.Sets/src/mage/sets/magic2010/DrownedCatacomb.java index b416ea184c..c680b37b98 100644 --- a/Mage.Sets/src/mage/sets/magic2010/DrownedCatacomb.java +++ b/Mage.Sets/src/mage/sets/magic2010/DrownedCatacomb.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.BlackManaAbility; @@ -62,7 +62,7 @@ public class DrownedCatacomb extends CardImpl { super(ownerId, 224, "Drowned Catacomb", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "M10"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.MORE_THAN, 0)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.MORE_THAN, 0)); String abilityText = "tap it unless you control a " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new BlackManaAbility()); diff --git a/Mage.Sets/src/mage/sets/magic2010/GlacialFortress.java b/Mage.Sets/src/mage/sets/magic2010/GlacialFortress.java index 84c73536fe..56732dbe50 100644 --- a/Mage.Sets/src/mage/sets/magic2010/GlacialFortress.java +++ b/Mage.Sets/src/mage/sets/magic2010/GlacialFortress.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.BlueManaAbility; @@ -62,7 +62,7 @@ public class GlacialFortress extends CardImpl { super(ownerId, 226, "Glacial Fortress", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "M10"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.MORE_THAN, 0)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.MORE_THAN, 0)); String abilityText = "tap it unless you control a " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new BlueManaAbility()); diff --git a/Mage.Sets/src/mage/sets/magic2010/RootboundCrag.java b/Mage.Sets/src/mage/sets/magic2010/RootboundCrag.java index 9e96248cc2..8196a95ffc 100644 --- a/Mage.Sets/src/mage/sets/magic2010/RootboundCrag.java +++ b/Mage.Sets/src/mage/sets/magic2010/RootboundCrag.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.GreenManaAbility; @@ -62,7 +62,7 @@ public class RootboundCrag extends CardImpl { super(ownerId, 227, "Rootbound Crag", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "M10"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.MORE_THAN, 0)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.MORE_THAN, 0)); String abilityText = "tap it unless you control a " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new RedManaAbility()); diff --git a/Mage.Sets/src/mage/sets/magic2010/SunpetalGrove.java b/Mage.Sets/src/mage/sets/magic2010/SunpetalGrove.java index 4b25590a91..ad60b4cc4d 100644 --- a/Mage.Sets/src/mage/sets/magic2010/SunpetalGrove.java +++ b/Mage.Sets/src/mage/sets/magic2010/SunpetalGrove.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.GreenManaAbility; @@ -62,7 +62,7 @@ public class SunpetalGrove extends CardImpl { super(ownerId, 228, "Sunpetal Grove", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "M10"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.MORE_THAN, 0)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.MORE_THAN, 0)); String abilityText = "tap it unless you control a " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new GreenManaAbility()); diff --git a/Mage.Sets/src/mage/sets/magic2012/CallToTheGrave.java b/Mage.Sets/src/mage/sets/magic2012/CallToTheGrave.java index b90fb949f6..3f992a4865 100644 --- a/Mage.Sets/src/mage/sets/magic2012/CallToTheGrave.java +++ b/Mage.Sets/src/mage/sets/magic2012/CallToTheGrave.java @@ -37,7 +37,7 @@ import mage.abilities.TriggeredAbility; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; import mage.abilities.common.OnEventTriggeredAbility; import mage.abilities.common.delayed.AtEndOfTurnDelayedTriggeredAbility; -import mage.abilities.condition.common.NoCreature; +import mage.abilities.condition.common.NoCreatureCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.SacrificeEffect; import mage.abilities.effects.common.SacrificeSourceEffect; @@ -71,7 +71,7 @@ public class CallToTheGrave extends CardImpl { this.addAbility(ability); // At the beginning of the end step, if no creatures are on the battlefield, sacrifice Call to the Grave. TriggeredAbility triggered = new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", false, new SacrificeSourceEffect()); - this.addAbility(new ConditionalTriggeredAbility(triggered, new NoCreature(), ruleText)); + this.addAbility(new ConditionalTriggeredAbility(triggered, new NoCreatureCondition(), ruleText)); } public CallToTheGrave(final CallToTheGrave card) { diff --git a/Mage.Sets/src/mage/sets/magic2012/GriffinRider.java b/Mage.Sets/src/mage/sets/magic2012/GriffinRider.java index 8ff59a3837..afa2990fb9 100644 --- a/Mage.Sets/src/mage/sets/magic2012/GriffinRider.java +++ b/Mage.Sets/src/mage/sets/magic2012/GriffinRider.java @@ -35,7 +35,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.condition.common.ControlsPermanent; +import mage.abilities.condition.common.ControlsPermanentCondition; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -70,7 +70,7 @@ public class GriffinRider extends CardImpl { this.toughness = new MageInt(1); // As long as you control a Griffin creature, Griffin Rider gets +3/+3 and has flying. - Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(3, 3, Duration.WhileOnBattlefield), new ControlsPermanent(filterGriffinCard), rule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(3, 3, Duration.WhileOnBattlefield), new ControlsPermanentCondition(filterGriffinCard), rule); ability.addEffect(new GainAbilitySourceEffect(FlyingAbility.getInstance())); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/magic2012/PrimordialHydra.java b/Mage.Sets/src/mage/sets/magic2012/PrimordialHydra.java index 095193f6ac..6045b8e1c5 100644 --- a/Mage.Sets/src/mage/sets/magic2012/PrimordialHydra.java +++ b/Mage.Sets/src/mage/sets/magic2012/PrimordialHydra.java @@ -39,7 +39,7 @@ import mage.abilities.Ability; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.HaveCounter; +import mage.abilities.condition.common.HasCounterCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.dynamicvalue.common.CountersCount; @@ -72,7 +72,7 @@ public class PrimordialHydra extends CardImpl { this.addAbility(new BeginningOfUpkeepTriggeredAbility(new PrimordialHydraDoubleEffect(), Constants.TargetController.YOU, false)); this.addAbility(new ConditionalStaticAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(TrampleAbility.getInstance(), Constants.Duration.WhileOnBattlefield), - new HaveCounter(CounterType.P1P1, 10), staticText)); + new HasCounterCondition(CounterType.P1P1, 10), staticText)); } public PrimordialHydra(final PrimordialHydra card) { diff --git a/Mage.Sets/src/mage/sets/magic2012/ThranGolem.java b/Mage.Sets/src/mage/sets/magic2012/ThranGolem.java index 70945b4211..be14829b41 100644 --- a/Mage.Sets/src/mage/sets/magic2012/ThranGolem.java +++ b/Mage.Sets/src/mage/sets/magic2012/ThranGolem.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.condition.common.Enchanted; +import mage.abilities.condition.common.EnchantedCondition; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -59,7 +59,7 @@ public class ThranGolem extends CardImpl { this.power = new MageInt(3); this.toughness = new MageInt(3); - Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield), Enchanted.getInstance(), rule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield), EnchantedCondition.getInstance(), rule); ability.addEffect(new GainAbilitySourceEffect(FlyingAbility.getInstance())); ability.addEffect(new GainAbilitySourceEffect(FirstStrikeAbility.getInstance())); ability.addEffect(new GainAbilitySourceEffect(TrampleAbility.getInstance())); diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/ArdentRecruit.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/ArdentRecruit.java index d4dbba3450..fa11e8a9ce 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/ArdentRecruit.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/ArdentRecruit.java @@ -36,7 +36,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -58,7 +58,7 @@ public class ArdentRecruit extends CardImpl { this.power = new MageInt(1); this.toughness = new MageInt(1); ContinuousEffect boostSource = new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield); - ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, Metalcraft.getInstance(), myText); + ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, MetalcraftCondition.getInstance(), myText); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/ConcussiveBolt.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/ConcussiveBolt.java index 77ab851129..d10489a5a0 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/ConcussiveBolt.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/ConcussiveBolt.java @@ -37,7 +37,7 @@ import mage.Constants.Rarity; import mage.Constants.SubLayer; import mage.abilities.Ability; import mage.abilities.common.CantBlockAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffectImpl; import mage.abilities.effects.common.DamageTargetEffect; @@ -62,7 +62,7 @@ public class ConcussiveBolt extends CardImpl { this.getSpellAbility().addTarget(new TargetPlayer()); this.getSpellAbility().addEffect(new DamageTargetEffect(4)); - this.getSpellAbility().addEffect(new ConditionalContinousEffect(new ConcussiveBoltEffect(), Metalcraft.getInstance(), "Metalcraft - If you control three or more artifacts, creatures that player controls can't block this turn")); + this.getSpellAbility().addEffect(new ConditionalContinousEffect(new ConcussiveBoltEffect(), MetalcraftCondition.getInstance(), "Metalcraft - If you control three or more artifacts, creatures that player controls can't block this turn")); } public ConcussiveBolt(final ConcussiveBolt card) { diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/MirranMettle.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/MirranMettle.java index ae6bfe5914..e26441eb8d 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/MirranMettle.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/MirranMettle.java @@ -31,7 +31,7 @@ import java.util.UUID; import mage.Constants.CardType; import mage.Constants.Duration; import mage.Constants.Rarity; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.BoostTargetEffect; import mage.cards.CardImpl; @@ -53,7 +53,7 @@ public class MirranMettle extends CardImpl { this.getSpellAbility().addTarget(new TargetCreaturePermanent()); this.getSpellAbility().addEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn)); - this.getSpellAbility().addEffect(new ConditionalContinousEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn), Metalcraft.getInstance(), effectText)); + this.getSpellAbility().addEffect(new ConditionalContinousEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn), MetalcraftCondition.getInstance(), effectText)); } public MirranMettle(final MirranMettle card) { diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/RazorfieldRhino.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/RazorfieldRhino.java index 764d5bfd12..ef65bc38b0 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/RazorfieldRhino.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/RazorfieldRhino.java @@ -35,7 +35,7 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -54,7 +54,7 @@ public class RazorfieldRhino extends CardImpl { this.power = new MageInt(4); this.toughness = new MageInt(4); ContinuousEffect effect1 = new BoostSourceEffect(2, 2, Constants.Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(effect1, Metalcraft.getInstance(), "Metalcraft - Razorfield Rhino gets +2/+2 as long as you control three or more artifacts"))); + this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(effect1, MetalcraftCondition.getInstance(), "Metalcraft - Razorfield Rhino gets +2/+2 as long as you control three or more artifacts"))); } public RazorfieldRhino (final RazorfieldRhino card) { diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/SpiralingDuelist.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/SpiralingDuelist.java index c200eba02c..d70d056958 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/SpiralingDuelist.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/SpiralingDuelist.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -59,7 +59,7 @@ public class SpiralingDuelist extends CardImpl { this.toughness = new MageInt(1); ContinuousEffect effect = new GainAbilitySourceEffect(DoubleStrikeAbility.getInstance(), Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, Metalcraft.getInstance(), effectText))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, MetalcraftCondition.getInstance(), effectText))); } public SpiralingDuelist(final SpiralingDuelist card) { diff --git a/Mage.Sets/src/mage/sets/newphyrexia/Dispatch.java b/Mage.Sets/src/mage/sets/newphyrexia/Dispatch.java index f973ec29f9..9812d04954 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/Dispatch.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/Dispatch.java @@ -31,7 +31,7 @@ package mage.sets.newphyrexia; import java.util.UUID; import mage.Constants.CardType; import mage.Constants.Rarity; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.ExileTargetEffect; import mage.abilities.effects.common.TapTargetEffect; @@ -49,7 +49,7 @@ public class Dispatch extends CardImpl { this.expansionSetCode = "NPH"; this.color.setWhite(true); this.getSpellAbility().addEffect(new TapTargetEffect()); - this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new ExileTargetEffect(), Metalcraft.getInstance(), "Metalcraft - If you control three or more artifacts, exile that creature")); + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new ExileTargetEffect(), MetalcraftCondition.getInstance(), "Metalcraft - If you control three or more artifacts, exile that creature")); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); } diff --git a/Mage.Sets/src/mage/sets/newphyrexia/JorKadeenThePrevailer.java b/Mage.Sets/src/mage/sets/newphyrexia/JorKadeenThePrevailer.java index edc51393f6..78cf8967bc 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/JorKadeenThePrevailer.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/JorKadeenThePrevailer.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.BoostControlledEffect; import mage.abilities.keyword.FirstStrikeAbility; @@ -63,7 +63,7 @@ public class JorKadeenThePrevailer extends CardImpl { this.addAbility(FirstStrikeAbility.getInstance()); ConditionalContinousEffect effect = new ConditionalContinousEffect(new BoostControlledEffect(3, 0, Duration.WhileOnBattlefield, FilterCreaturePermanent.getDefault(), true), - Metalcraft.getInstance(), effectText); + MetalcraftCondition.getInstance(), effectText); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/sets/newphyrexia/PuresteelPaladin.java b/Mage.Sets/src/mage/sets/newphyrexia/PuresteelPaladin.java index 8067553e40..25ec28d257 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/PuresteelPaladin.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/PuresteelPaladin.java @@ -36,7 +36,7 @@ import mage.Constants.Rarity; import mage.MageInt; import mage.abilities.TriggeredAbilityImpl; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.DrawCardControllerEffect; @@ -75,7 +75,7 @@ public class PuresteelPaladin extends CardImpl { new GainAbilityControlledEffect( new EquipAbility(Constants.Outcome.AddAbility, new GenericManaCost(0)), Constants.Duration.WhileOnBattlefield, filter), - Metalcraft.getInstance(), + MetalcraftCondition.getInstance(), "Metalcraft - Equipment you control have equip {0} as long as you control three or more artifacts"))); } diff --git a/Mage.Sets/src/mage/sets/ravnika/GateHound.java b/Mage.Sets/src/mage/sets/ravnika/GateHound.java index 5480829e25..158ae24575 100644 --- a/Mage.Sets/src/mage/sets/ravnika/GateHound.java +++ b/Mage.Sets/src/mage/sets/ravnika/GateHound.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Enchanted; +import mage.abilities.condition.common.EnchantedCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.GainAbilityControlledEffect; import mage.abilities.keyword.VigilanceAbility; @@ -59,7 +59,7 @@ public class GateHound extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new GainAbilityControlledEffect(VigilanceAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent()), - Enchanted.getInstance(), + EnchantedCondition.getInstance(), "Creatures you control have vigilance as long as {this} is enchanted"))); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokEdgewright.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokEdgewright.java index d5a6cde126..88237af9eb 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokEdgewright.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokEdgewright.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -60,7 +60,7 @@ public class AuriokEdgewright extends CardImpl { this.toughness = new MageInt(2); ContinuousEffect effect = new GainAbilitySourceEffect(DoubleStrikeAbility.getInstance(), Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, Metalcraft.getInstance(), effectText))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, MetalcraftCondition.getInstance(), effectText))); } public AuriokEdgewright(final AuriokEdgewright card) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokSunchaser.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokSunchaser.java index 65cfae61b4..f9eb3df5e6 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokSunchaser.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/AuriokSunchaser.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -62,9 +62,9 @@ public class AuriokSunchaser extends CardImpl { this.toughness = new MageInt(1); ContinuousEffect effect1 = new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect1, Metalcraft.getInstance(), effect1Text))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect1, MetalcraftCondition.getInstance(), effect1Text))); ContinuousEffect effect2 = new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect2, Metalcraft.getInstance(), effect2Text))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect2, MetalcraftCondition.getInstance(), effect2Text))); } public AuriokSunchaser(final AuriokSunchaser card) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/BlackcleaveCliffs.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/BlackcleaveCliffs.java index b14f6c6bb8..d4b5e80065 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/BlackcleaveCliffs.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/BlackcleaveCliffs.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.BlackManaAbility; @@ -60,7 +60,7 @@ public class BlackcleaveCliffs extends CardImpl { super(ownerId, 224, "Blackcleave Cliffs", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "SOM"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.FEWER_THAN, 4)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.FEWER_THAN, 4)); String abilityText = "tap it unless you control fewer than 3 " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new BlackManaAbility()); diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/BladeTribeBerserkers.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/BladeTribeBerserkers.java index e570fb3d59..3a4f2d10d9 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/BladeTribeBerserkers.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/BladeTribeBerserkers.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.MageInt; import mage.abilities.TriggeredAbility; import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -64,7 +64,7 @@ public class BladeTribeBerserkers extends CardImpl { TriggeredAbility ability = new EntersBattlefieldTriggeredAbility(new BoostSourceEffect(3, 3, Duration.EndOfTurn), false); ability.addEffect(new GainAbilitySourceEffect(HasteAbility.getInstance(), Duration.EndOfTurn)); - this.addAbility(new ConditionalTriggeredAbility(ability, Metalcraft.getInstance(), effectText)); + this.addAbility(new ConditionalTriggeredAbility(ability, MetalcraftCondition.getInstance(), effectText)); } public BladeTribeBerserkers(final BladeTribeBerserkers card) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/BleakCovenVampires.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/BleakCovenVampires.java index 79059cf821..6976d29f28 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/BleakCovenVampires.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/BleakCovenVampires.java @@ -35,7 +35,7 @@ import mage.MageInt; import mage.abilities.TriggeredAbility; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.GainLifeEffect; import mage.abilities.effects.common.LoseLifeTargetEffect; @@ -67,7 +67,7 @@ public class BleakCovenVampires extends CardImpl { target.setRequired(true); ability.addTarget(target); - this.addAbility(new ConditionalTriggeredAbility(ability, Metalcraft.getInstance(), effectText)); + this.addAbility(new ConditionalTriggeredAbility(ability, MetalcraftCondition.getInstance(), effectText)); } public BleakCovenVampires(final BleakCovenVampires card) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/CarapaceForger.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/CarapaceForger.java index e98c6c66a4..9e19711abd 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/CarapaceForger.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/CarapaceForger.java @@ -35,7 +35,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -57,7 +57,7 @@ public class CarapaceForger extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(2); ContinuousEffect boostSource = new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield); - ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, Metalcraft.getInstance(), text); + ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, MetalcraftCondition.getInstance(), text); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/ChromeSteed.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/ChromeSteed.java index 8b46b29f58..1555d28347 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/ChromeSteed.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/ChromeSteed.java @@ -35,7 +35,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -55,7 +55,7 @@ public class ChromeSteed extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(2); ContinuousEffect boostSource = new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield); - ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, Metalcraft.getInstance(), text); + ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, MetalcraftCondition.getInstance(), text); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/CopperlineGorge.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/CopperlineGorge.java index f7ea3ff49c..1821abfc8c 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/CopperlineGorge.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/CopperlineGorge.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.GreenManaAbility; @@ -60,7 +60,7 @@ public class CopperlineGorge extends CardImpl { super(ownerId, 225, "Copperline Gorge", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "SOM"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.FEWER_THAN, 4)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.FEWER_THAN, 4)); String abilityText = "tap it unless you control fewer than 3 " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new RedManaAbility()); diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/DarkslickShores.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/DarkslickShores.java index 591b730aef..634655a47b 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/DarkslickShores.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/DarkslickShores.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.BlackManaAbility; @@ -60,7 +60,7 @@ public class DarkslickShores extends CardImpl { super(ownerId, 226, "Darkslick Shores", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "SOM"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.FEWER_THAN, 4)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.FEWER_THAN, 4)); String abilityText = "tap it unless you control fewer than 3 " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new BlueManaAbility()); diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/DispenseJustice.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/DispenseJustice.java index 56e4471b5e..00daa3b702 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/DispenseJustice.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/DispenseJustice.java @@ -33,7 +33,7 @@ import mage.Constants.CardType; import mage.Constants.Outcome; import mage.Constants.Rarity; import mage.abilities.Ability; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.SacrificeEffect; import mage.cards.CardImpl; @@ -92,7 +92,7 @@ class DispenseJusticeEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - if ( Metalcraft.getInstance().apply(game, source) ) { + if ( MetalcraftCondition.getInstance().apply(game, source) ) { return new SacrificeEffect(filter, 2, effectText).apply(game, source); } else { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/EtchedChampion.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/EtchedChampion.java index f4bf6b831a..90b6311551 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/EtchedChampion.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/EtchedChampion.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -71,7 +71,7 @@ public class EtchedChampion extends CardImpl { this.toughness = new MageInt(2); ContinuousEffect effect = new GainAbilitySourceEffect(new ProtectionAbility(filter), Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, Metalcraft.getInstance(), ruleText))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, MetalcraftCondition.getInstance(), ruleText))); } public EtchedChampion(final EtchedChampion card) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/EzurisBrigade.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/EzurisBrigade.java index 6286f21756..6f22e1f65c 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/EzurisBrigade.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/EzurisBrigade.java @@ -36,7 +36,7 @@ import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -60,9 +60,9 @@ public class EzurisBrigade extends CardImpl { this.power = new MageInt(4); this.toughness = new MageInt(4); ContinuousEffect boostSource = new BoostSourceEffect(4, 4, Duration.WhileOnBattlefield); - ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, Metalcraft.getInstance(), text); + ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, MetalcraftCondition.getInstance(), text); Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect); - ability.addEffect(new ConditionalContinousEffect(new GainAbilitySourceEffect(TrampleAbility.getInstance(), Duration.WhileOnBattlefield), Metalcraft.getInstance(), "")); + ability.addEffect(new ConditionalContinousEffect(new GainAbilitySourceEffect(TrampleAbility.getInstance(), Duration.WhileOnBattlefield), MetalcraftCondition.getInstance(), "")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/GalvanicBlast.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/GalvanicBlast.java index dc8792633c..cd00da3e2e 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/GalvanicBlast.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/GalvanicBlast.java @@ -30,7 +30,7 @@ package mage.sets.scarsofmirrodin; import java.util.UUID; import mage.Constants.CardType; import mage.Constants.Rarity; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; @@ -52,7 +52,7 @@ public class GalvanicBlast extends CardImpl { this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); this.getSpellAbility().addEffect(new DamageTargetEffect(2)); - this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DamageTargetEffect(2), Metalcraft.getInstance(), effectText)); + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DamageTargetEffect(2), MetalcraftCondition.getInstance(), effectText)); } public GalvanicBlast(final GalvanicBlast card) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/GhalmasWarden.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/GhalmasWarden.java index 3c539e24f4..131466c038 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/GhalmasWarden.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/GhalmasWarden.java @@ -35,7 +35,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; @@ -58,7 +58,7 @@ public class GhalmasWarden extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(4); ContinuousEffect boostSource = new BoostSourceEffect(2, 2, Duration.WhileOnBattlefield); - ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, Metalcraft.getInstance(), text); + ConditionalContinousEffect effect = new ConditionalContinousEffect(boostSource, MetalcraftCondition.getInstance(), text); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/IndomitableArchangel.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/IndomitableArchangel.java index 53ba20d4fe..767f3867d4 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/IndomitableArchangel.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/IndomitableArchangel.java @@ -36,7 +36,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.GainAbilityControlledEffect; @@ -67,7 +67,7 @@ public class IndomitableArchangel extends CardImpl { this.toughness = new MageInt(4); this.addAbility(FlyingAbility.getInstance()); ContinuousEffect gainAbilityEffect = new GainAbilityControlledEffect(ShroudAbility.getInstance(), Duration.WhileOnBattlefield, filter); - ConditionalContinousEffect effect = new ConditionalContinousEffect(gainAbilityEffect, Metalcraft.getInstance(), text); + ConditionalContinousEffect effect = new ConditionalContinousEffect(gainAbilityEffect, MetalcraftCondition.getInstance(), text); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/LumengridDrake.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/LumengridDrake.java index 7045be190c..2b9b42c1c8 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/LumengridDrake.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/LumengridDrake.java @@ -32,7 +32,7 @@ import mage.Constants.Rarity; import mage.MageInt; import mage.abilities.TriggeredAbility; import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.ReturnToHandTargetEffect; import mage.cards.CardImpl; @@ -57,7 +57,7 @@ public class LumengridDrake extends CardImpl { this.toughness = new MageInt(2); TriggeredAbility conditional = new ConditionalTriggeredAbility( - new EntersBattlefieldTriggeredAbility(new ReturnToHandTargetEffect()), Metalcraft.getInstance(), text); + new EntersBattlefieldTriggeredAbility(new ReturnToHandTargetEffect()), MetalcraftCondition.getInstance(), text); conditional.addTarget(new TargetCreaturePermanent()); this.addAbility(conditional); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/MoltenPsyche.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/MoltenPsyche.java index cfea79050d..dbf09d0baf 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/MoltenPsyche.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/MoltenPsyche.java @@ -34,7 +34,7 @@ import mage.Constants.CardType; import mage.Constants.Outcome; import mage.Constants.Rarity; import mage.abilities.Ability; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.effects.OneShotEffect; import mage.cards.CardImpl; import mage.game.Game; @@ -90,7 +90,7 @@ class MoltenPsycheEffect extends OneShotEffect { player.getLibrary().shuffle(); player.getHand().clear(); player.drawCards(count, game); - if (Metalcraft.getInstance().apply(game, source) && !playerId.equals(source.getControllerId())) { + if (MetalcraftCondition.getInstance().apply(game, source) && !playerId.equals(source.getControllerId())) { MoltenPsycheWatcher watcher = (MoltenPsycheWatcher) game.getState().getWatchers().get(source.getControllerId(), "CardsDrawnMoltenPsyche"); player.damage(watcher.getDraws(playerId), source.getId(), game, false, true); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/RazorvergeThicket.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/RazorvergeThicket.java index ff9a8a79cf..7e31d4e081 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/RazorvergeThicket.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/RazorvergeThicket.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.GreenManaAbility; @@ -60,7 +60,7 @@ public class RazorvergeThicket extends CardImpl { super(ownerId, 228, "Razorverge Thicket", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "SOM"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.FEWER_THAN, 4)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.FEWER_THAN, 4)); String abilityText = "tap it unless you control fewer than 3 " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new GreenManaAbility()); diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/RustedRelic.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/RustedRelic.java index d9c169bebf..d8d44a3faf 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/RustedRelic.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/RustedRelic.java @@ -37,7 +37,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.BecomesCreatureSourceEffect; import mage.cards.CardImpl; @@ -56,7 +56,7 @@ public class RustedRelic extends CardImpl { new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new BecomesCreatureSourceEffect(new RustedRelicToken(), "artifact", Duration.Custom), - Metalcraft.getInstance(), + MetalcraftCondition.getInstance(), "Metalcraft - Rusted Relic is a 5/5 Golem artifact creature as long as you control three or more artifacts"))); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/ScrapdiverSerpent.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/ScrapdiverSerpent.java index f0633c6265..9f20130edc 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/ScrapdiverSerpent.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/ScrapdiverSerpent.java @@ -37,7 +37,7 @@ import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; +import mage.abilities.condition.common.ControlsPermanentCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.Effect; diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/ScreechingSilcaw.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/ScreechingSilcaw.java index 06995a7ad9..2466bded57 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/ScreechingSilcaw.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/ScreechingSilcaw.java @@ -32,7 +32,7 @@ import mage.Constants.Rarity; import mage.MageInt; import mage.abilities.TriggeredAbility; import mage.abilities.common.DealsCombatDamageToAPlayerTriggeredAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.PutLibraryIntoGraveTargetEffect; import mage.abilities.keyword.FlyingAbility; @@ -61,7 +61,7 @@ public class ScreechingSilcaw extends CardImpl { TriggeredAbility conditional = new ConditionalTriggeredAbility( new DealsCombatDamageToAPlayerTriggeredAbility(new PutLibraryIntoGraveTargetEffect(4), false, true), - Metalcraft.getInstance(), text); + MetalcraftCondition.getInstance(), text); this.addAbility(conditional); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/SeachromeCoast.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/SeachromeCoast.java index 316c2ffd0e..44185605ed 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/SeachromeCoast.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/SeachromeCoast.java @@ -33,8 +33,8 @@ import mage.Constants.CardType; import mage.Constants.Rarity; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.ControlsPermanent; -import mage.abilities.condition.common.Unless; +import mage.abilities.condition.common.ControlsPermanentCondition; +import mage.abilities.condition.common.UnlessCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.TapSourceEffect; import mage.abilities.mana.BlueManaAbility; @@ -60,7 +60,7 @@ public class SeachromeCoast extends CardImpl { super(ownerId, 229, "Seachrome Coast", Rarity.RARE, new CardType[]{CardType.LAND}, null); this.expansionSetCode = "SOM"; - Condition controls = new Unless(new ControlsPermanent(filter, ControlsPermanent.CountType.FEWER_THAN, 4)); + Condition controls = new UnlessCondition(new ControlsPermanentCondition(filter, ControlsPermanentCondition.CountType.FEWER_THAN, 4)); String abilityText = "tap it unless you control fewer than 3 " + filter.getMessage(); this.addAbility(new EntersBattlefieldAbility(new ConditionalOneShotEffect(new TapSourceEffect(), controls, abilityText), abilityText)); this.addAbility(new WhiteManaAbility()); diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/SnapsailGlider.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/SnapsailGlider.java index 1b36cea34e..b51d6e0c4e 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/SnapsailGlider.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/SnapsailGlider.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -58,7 +58,7 @@ public class SnapsailGlider extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(2); ContinuousEffect effect = new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, Metalcraft.getInstance(), text))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, MetalcraftCondition.getInstance(), text))); } public SnapsailGlider (final SnapsailGlider card) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/StoicRebuttal.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/StoicRebuttal.java index c3efaadfae..e80380cfc3 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/StoicRebuttal.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/StoicRebuttal.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Mana; import mage.abilities.Ability; import mage.abilities.SpellAbility; -import mage.abilities.condition.common.Metalcraft; +import mage.abilities.condition.common.MetalcraftCondition; import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.ManaCost; import mage.abilities.costs.mana.ManaCosts; @@ -71,7 +71,7 @@ public class StoicRebuttal extends CardImpl { @Override public void adjustCosts(Ability ability, Game game) { - if (Metalcraft.getInstance().apply(game, ability)) { + if (MetalcraftCondition.getInstance().apply(game, ability)) { /*ManaCosts previousCost = ability.getManaCostsToPay(); ManaCosts adjustedCost = new ManaCostsImpl(); boolean reduced = false; diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/SunspearShikari.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/SunspearShikari.java index bd28c80293..4492e07ac4 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/SunspearShikari.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/SunspearShikari.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.condition.common.Equipped; +import mage.abilities.condition.common.EquippedCondition; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; import mage.abilities.keyword.FirstStrikeAbility; @@ -59,7 +59,7 @@ public class SunspearShikari extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(2); - Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance()), Equipped.getInstance(), rule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FirstStrikeAbility.getInstance()), EquippedCondition.getInstance(), rule); ability.addEffect(new GainAbilitySourceEffect(LifelinkAbility.getInstance())); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/worldwake/KitesailApprentice.java b/Mage.Sets/src/mage/sets/worldwake/KitesailApprentice.java index 3dca3dc508..11e584388b 100644 --- a/Mage.Sets/src/mage/sets/worldwake/KitesailApprentice.java +++ b/Mage.Sets/src/mage/sets/worldwake/KitesailApprentice.java @@ -35,7 +35,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.condition.common.Equipped; +import mage.abilities.condition.common.EquippedCondition; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -60,7 +60,7 @@ public class KitesailApprentice extends CardImpl { this.power = new MageInt(1); this.toughness = new MageInt(1); - Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), Equipped.getInstance(), rule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), EquippedCondition.getInstance(), rule); ability.addEffect(new GainAbilitySourceEffect(FlyingAbility.getInstance())); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/worldwake/LoamLion.java b/Mage.Sets/src/mage/sets/worldwake/LoamLion.java index ad422a05e8..af6a1890fd 100644 --- a/Mage.Sets/src/mage/sets/worldwake/LoamLion.java +++ b/Mage.Sets/src/mage/sets/worldwake/LoamLion.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.ControlsPermanent; +import mage.abilities.condition.common.ControlsPermanentCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.cards.CardImpl; @@ -64,7 +64,7 @@ public class LoamLion extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(new BoostSourceEffect(1, 2, Duration.WhileOnBattlefield), - new ControlsPermanent(filter), rule))); + new ControlsPermanentCondition(filter), rule))); } public LoamLion(final LoamLion card) { diff --git a/Mage.Sets/src/mage/sets/worldwake/RuthlessCullblade.java b/Mage.Sets/src/mage/sets/worldwake/RuthlessCullblade.java index 945284ec6a..371592afc2 100644 --- a/Mage.Sets/src/mage/sets/worldwake/RuthlessCullblade.java +++ b/Mage.Sets/src/mage/sets/worldwake/RuthlessCullblade.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.TenOrLessLife; +import mage.abilities.condition.common.TenOrLessLifeCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.cards.CardImpl; @@ -57,7 +57,7 @@ public class RuthlessCullblade extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(new BoostSourceEffect(2, 1, Duration.Custom), - new TenOrLessLife(TenOrLessLife.CheckType.AN_OPPONENT), + new TenOrLessLifeCondition(TenOrLessLifeCondition.CheckType.AN_OPPONENT), "Ruthless Cullblade gets +2/+1 as long as an opponent has 10 or less life."))); } diff --git a/Mage.Sets/src/mage/sets/worldwake/SejiriMerfolk.java b/Mage.Sets/src/mage/sets/worldwake/SejiriMerfolk.java index 84300ccef7..62953fdedc 100644 --- a/Mage.Sets/src/mage/sets/worldwake/SejiriMerfolk.java +++ b/Mage.Sets/src/mage/sets/worldwake/SejiriMerfolk.java @@ -35,7 +35,7 @@ import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.ControlsPermanent; +import mage.abilities.condition.common.ControlsPermanentCondition; import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.Effect; @@ -68,7 +68,7 @@ public class SejiriMerfolk extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(1); - Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(LifelinkAbility.getInstance()), new ControlsPermanent(filter), rule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(LifelinkAbility.getInstance()), new ControlsPermanentCondition(filter), rule); ability.addEffect(new GainAbilitySourceEffect(FirstStrikeAbility.getInstance())); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/zendikar/Bloodghast.java b/Mage.Sets/src/mage/sets/zendikar/Bloodghast.java index 8fff5bd219..2fcbbe5357 100644 --- a/Mage.Sets/src/mage/sets/zendikar/Bloodghast.java +++ b/Mage.Sets/src/mage/sets/zendikar/Bloodghast.java @@ -30,7 +30,7 @@ package mage.sets.zendikar; import mage.abilities.common.CantBlockAbility; import mage.Constants.Duration; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.TenOrLessLife; +import mage.abilities.condition.common.TenOrLessLifeCondition; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; import mage.abilities.keyword.HasteAbility; @@ -44,7 +44,7 @@ import mage.abilities.decorator.ConditionalContinousEffect; import mage.abilities.effects.common.ReturnSourceFromGraveyardToBattlefieldEffect; import mage.cards.CardImpl; -import static mage.abilities.condition.common.TenOrLessLife.CheckType.*; +import static mage.abilities.condition.common.TenOrLessLifeCondition.CheckType.*; /** * @@ -65,7 +65,7 @@ public class Bloodghast extends CardImpl { this.addAbility(CantBlockAbility.getInstance()); this.addAbility(new LandfallAbility(Zone.GRAVEYARD, new ReturnSourceFromGraveyardToBattlefieldEffect(), true)); ContinuousEffect effect = new GainAbilitySourceEffect(HasteAbility.getInstance(), Duration.WhileOnBattlefield); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, new TenOrLessLife(AN_OPPONENT), "Bloodghast has haste as long as an opponent has 10 or less life."))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect(effect, new TenOrLessLifeCondition(AN_OPPONENT), "Bloodghast has haste as long as an opponent has 10 or less life."))); } public Bloodghast(final Bloodghast card) { diff --git a/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java b/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java index 9ff3f90571..62f2ba9569 100644 --- a/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java +++ b/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java @@ -34,7 +34,7 @@ import mage.Constants.Rarity; import mage.Constants.Zone; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.condition.common.TenOrLessLife; +import mage.abilities.condition.common.TenOrLessLifeCondition; import mage.abilities.decorator.ConditionalStaticAbility; import mage.abilities.effects.common.continious.BoostSourceEffect; import mage.abilities.effects.common.continious.GainAbilitySourceEffect; @@ -59,7 +59,7 @@ public class GuulDrazVampire extends CardImpl { this.power = new MageInt(1); this.toughness = new MageInt(1); - Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 1, Duration.WhileOnBattlefield), new TenOrLessLife(TenOrLessLife.CheckType.AN_OPPONENT), rule); + Ability ability = new ConditionalStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 1, Duration.WhileOnBattlefield), new TenOrLessLifeCondition(TenOrLessLifeCondition.CheckType.AN_OPPONENT), rule); ability.addEffect(new GainAbilitySourceEffect(IntimidateAbility.getInstance())); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/zendikar/VampireLacerator.java b/Mage.Sets/src/mage/sets/zendikar/VampireLacerator.java index 603085ffa0..fde4c670dc 100644 --- a/Mage.Sets/src/mage/sets/zendikar/VampireLacerator.java +++ b/Mage.Sets/src/mage/sets/zendikar/VampireLacerator.java @@ -33,13 +33,13 @@ import java.util.UUID; import mage.Constants.CardType; import mage.Constants.Rarity; import mage.MageInt; -import mage.abilities.condition.common.Unless; -import mage.abilities.condition.common.TenOrLessLife; +import mage.abilities.condition.common.UnlessCondition; +import mage.abilities.condition.common.TenOrLessLifeCondition; import mage.abilities.decorator.ConditionalOneShotEffect; import mage.abilities.effects.common.LoseLifeSourceEffect; import mage.cards.CardImpl; -import static mage.abilities.condition.common.TenOrLessLife.CheckType.*; +import static mage.abilities.condition.common.TenOrLessLifeCondition.CheckType.*; /** * @@ -59,7 +59,7 @@ public class VampireLacerator extends CardImpl { this.addAbility(new BeginningOfUpkeepTriggeredAbility( new ConditionalOneShotEffect( new LoseLifeSourceEffect(1), - new Unless( new TenOrLessLife(AN_OPPONENT) ), + new UnlessCondition( new TenOrLessLifeCondition(AN_OPPONENT) ), "you lose 1 life unless an opponent has 10 or less life"), Constants.TargetController.YOU, false)); } diff --git a/Mage/src/mage/abilities/common/CreateTokenActivatedAbility.java b/Mage/src/mage/abilities/common/CreateTokenActivatedAbility.java deleted file mode 100644 index 829ae53c27..0000000000 --- a/Mage/src/mage/abilities/common/CreateTokenActivatedAbility.java +++ /dev/null @@ -1,56 +0,0 @@ -/* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - -package mage.abilities.common; - -import mage.Constants.Zone; -import mage.abilities.ActivatedAbilityImpl; -import mage.abilities.costs.Cost; -import mage.abilities.effects.common.CreateTokenEffect; -import mage.game.permanent.token.Token; - -/** - * - * @author BetaSteward_at_googlemail.com - */ -public class CreateTokenActivatedAbility extends ActivatedAbilityImpl { - - public CreateTokenActivatedAbility(Zone zone, Token token, Cost cost) { - super(zone, new CreateTokenEffect(token), cost); - } - - public CreateTokenActivatedAbility(CreateTokenActivatedAbility ability) { - super(ability); - } - - @Override - public CreateTokenActivatedAbility copy() { - return new CreateTokenActivatedAbility(this); - } - -} diff --git a/Mage/src/mage/abilities/condition/common/ControlsPermanent.java b/Mage/src/mage/abilities/condition/common/ControlsPermanentCondition.java similarity index 90% rename from Mage/src/mage/abilities/condition/common/ControlsPermanent.java rename to Mage/src/mage/abilities/condition/common/ControlsPermanentCondition.java index 77964ae179..0d1a3edb90 100644 --- a/Mage/src/mage/abilities/condition/common/ControlsPermanent.java +++ b/Mage/src/mage/abilities/condition/common/ControlsPermanentCondition.java @@ -42,7 +42,7 @@ import mage.game.Game; * @author nantuko * @author maurer.it_at_gmail.com */ -public class ControlsPermanent implements Condition { +public class ControlsPermanentCondition implements Condition { public static enum CountType { MORE_THAN, FEWER_THAN, EQUAL_TO }; private FilterPermanent filter; @@ -57,7 +57,7 @@ public class ControlsPermanent implements Condition { * * @param filter */ - public ControlsPermanent(FilterPermanent filter) { + public ControlsPermanentCondition(FilterPermanent filter) { this(filter, CountType.MORE_THAN, 0); } @@ -68,7 +68,7 @@ public class ControlsPermanent implements Condition { * * @param filter */ - public ControlsPermanent ( FilterPermanent filter, CountType type, int count ) { + public ControlsPermanentCondition ( FilterPermanent filter, CountType type, int count ) { this.filter = filter; this.type = type; this.count = count; @@ -83,7 +83,7 @@ public class ControlsPermanent implements Condition { * @param filter * @param conditionToDecorate */ - public ControlsPermanent ( FilterPermanent filter, CountType type, int count, Condition conditionToDecorate ) { + public ControlsPermanentCondition ( FilterPermanent filter, CountType type, int count, Condition conditionToDecorate ) { this(filter, type, count); this.condition = conditionToDecorate; } diff --git a/Mage/src/mage/abilities/condition/common/Enchanted.java b/Mage/src/mage/abilities/condition/common/EnchantedCondition.java similarity index 94% rename from Mage/src/mage/abilities/condition/common/Enchanted.java rename to Mage/src/mage/abilities/condition/common/EnchantedCondition.java index a30ef97e00..f97d4f633a 100644 --- a/Mage/src/mage/abilities/condition/common/Enchanted.java +++ b/Mage/src/mage/abilities/condition/common/EnchantedCondition.java @@ -38,9 +38,9 @@ import mage.game.permanent.Permanent; * * @author North */ -public class Enchanted implements Condition { +public class EnchantedCondition implements Condition { - private static Enchanted fInstance = new Enchanted(); + private static EnchantedCondition fInstance = new EnchantedCondition(); public static Condition getInstance() { return fInstance; @@ -55,7 +55,6 @@ public class Enchanted implements Condition { if (attached.getCardType().contains(CardType.ENCHANTMENT)) { return true; } - return false; } } return false; diff --git a/Mage/src/mage/abilities/condition/common/Equipped.java b/Mage/src/mage/abilities/condition/common/EquippedCondition.java similarity index 92% rename from Mage/src/mage/abilities/condition/common/Equipped.java rename to Mage/src/mage/abilities/condition/common/EquippedCondition.java index f9662a7b55..90a28810f1 100644 --- a/Mage/src/mage/abilities/condition/common/Equipped.java +++ b/Mage/src/mage/abilities/condition/common/EquippedCondition.java @@ -39,9 +39,9 @@ import java.util.UUID; * * @author nantuko */ -public class Equipped implements Condition { +public class EquippedCondition implements Condition { - private static Equipped fInstance = new Equipped(); + private static EquippedCondition fInstance = new EquippedCondition(); public static Condition getInstance() { return fInstance; @@ -56,7 +56,6 @@ public class Equipped implements Condition { if (attached.getSubtype().contains("Equipment")) { return true; } - return false; } } return false; diff --git a/Mage/src/mage/abilities/condition/common/Flipped.java b/Mage/src/mage/abilities/condition/common/FlippedCondition.java similarity index 92% rename from Mage/src/mage/abilities/condition/common/Flipped.java rename to Mage/src/mage/abilities/condition/common/FlippedCondition.java index d081a0d833..d3bbffb6b1 100644 --- a/Mage/src/mage/abilities/condition/common/Flipped.java +++ b/Mage/src/mage/abilities/condition/common/FlippedCondition.java @@ -32,9 +32,9 @@ import mage.abilities.condition.Condition; import mage.game.Game; import mage.game.permanent.Permanent; -public class Flipped implements Condition { +public class FlippedCondition implements Condition { - private static Flipped fInstance = new Flipped(); + private static FlippedCondition fInstance = new FlippedCondition(); public static Condition getInstance() { return fInstance; diff --git a/Mage/src/mage/abilities/condition/common/HaveCounter.java b/Mage/src/mage/abilities/condition/common/HasCounterCondition.java similarity index 92% rename from Mage/src/mage/abilities/condition/common/HaveCounter.java rename to Mage/src/mage/abilities/condition/common/HasCounterCondition.java index ccf6f11648..1958e4a43a 100644 --- a/Mage/src/mage/abilities/condition/common/HaveCounter.java +++ b/Mage/src/mage/abilities/condition/common/HasCounterCondition.java @@ -36,15 +36,15 @@ import mage.game.Game; * * @author nantuko */ -public class HaveCounter implements Condition { +public class HasCounterCondition implements Condition { private CounterType counterType; private int amount = 1; - public HaveCounter(CounterType type) { + public HasCounterCondition(CounterType type) { this.counterType = type; } - public HaveCounter(CounterType type, int amount) { + public HasCounterCondition(CounterType type, int amount) { this.counterType = type; this.amount = amount; } diff --git a/Mage/src/mage/abilities/condition/common/Hellbent.java b/Mage/src/mage/abilities/condition/common/HellbentCondition.java similarity index 92% rename from Mage/src/mage/abilities/condition/common/Hellbent.java rename to Mage/src/mage/abilities/condition/common/HellbentCondition.java index 89f05b8f66..598c207fd4 100644 --- a/Mage/src/mage/abilities/condition/common/Hellbent.java +++ b/Mage/src/mage/abilities/condition/common/HellbentCondition.java @@ -31,9 +31,9 @@ import mage.abilities.Ability; import mage.abilities.condition.Condition; import mage.game.Game; -public class Hellbent implements Condition { +public class HellbentCondition implements Condition { - private static Hellbent fInstance = new Hellbent(); + private static HellbentCondition fInstance = new HellbentCondition(); public static Condition getInstance() { return fInstance; diff --git a/Mage/src/mage/abilities/condition/common/Metalcraft.java b/Mage/src/mage/abilities/condition/common/MetalcraftCondition.java similarity index 80% rename from Mage/src/mage/abilities/condition/common/Metalcraft.java rename to Mage/src/mage/abilities/condition/common/MetalcraftCondition.java index 353d98d99c..f915fd43ec 100644 --- a/Mage/src/mage/abilities/condition/common/Metalcraft.java +++ b/Mage/src/mage/abilities/condition/common/MetalcraftCondition.java @@ -11,7 +11,7 @@ import mage.game.Game; * * @author nantuko */ -public class Metalcraft implements Condition { +public class MetalcraftCondition implements Condition { private static final FilterPermanent filter = new FilterPermanent("artifact"); @@ -19,7 +19,7 @@ public class Metalcraft implements Condition { filter.getCardType().add(Constants.CardType.ARTIFACT); } - private static Metalcraft fInstance = new Metalcraft(); + private static MetalcraftCondition fInstance = new MetalcraftCondition(); public static Condition getInstance() { return fInstance; diff --git a/Mage/src/mage/abilities/condition/common/MyTurn.java b/Mage/src/mage/abilities/condition/common/MyTurnCondition.java similarity index 92% rename from Mage/src/mage/abilities/condition/common/MyTurn.java rename to Mage/src/mage/abilities/condition/common/MyTurnCondition.java index 2d38211241..68f58ed325 100644 --- a/Mage/src/mage/abilities/condition/common/MyTurn.java +++ b/Mage/src/mage/abilities/condition/common/MyTurnCondition.java @@ -31,8 +31,8 @@ import mage.abilities.Ability; import mage.abilities.condition.Condition; import mage.game.Game; -public class MyTurn implements Condition { - private static MyTurn fInstance = new MyTurn(); +public class MyTurnCondition implements Condition { + private static MyTurnCondition fInstance = new MyTurnCondition(); public static Condition getInstance() { return fInstance; diff --git a/Mage/src/mage/abilities/condition/common/NoCreature.java b/Mage/src/mage/abilities/condition/common/NoCreatureCondition.java similarity index 90% rename from Mage/src/mage/abilities/condition/common/NoCreature.java rename to Mage/src/mage/abilities/condition/common/NoCreatureCondition.java index ad554d7127..76ba8e6398 100644 --- a/Mage/src/mage/abilities/condition/common/NoCreature.java +++ b/Mage/src/mage/abilities/condition/common/NoCreatureCondition.java @@ -35,8 +35,8 @@ import mage.game.Game; /** * @author nantuko */ -public class NoCreature implements Condition { - private static NoCreature fInstance = new NoCreature(); +public class NoCreatureCondition implements Condition { + private static NoCreatureCondition fInstance = new NoCreatureCondition(); private static final FilterCreaturePermanent filter = new FilterCreaturePermanent(); @@ -46,7 +46,6 @@ public class NoCreature implements Condition { @Override public boolean apply(Game game, Ability source) { - System.out.println("out:"+game.getBattlefield().countAll(filter)); return game.getBattlefield().countAll(filter) == 0; } } diff --git a/Mage/src/mage/abilities/condition/common/NotMyTurn.java b/Mage/src/mage/abilities/condition/common/NotMyTurnCondition.java similarity index 91% rename from Mage/src/mage/abilities/condition/common/NotMyTurn.java rename to Mage/src/mage/abilities/condition/common/NotMyTurnCondition.java index 551938bb07..124eb57c79 100644 --- a/Mage/src/mage/abilities/condition/common/NotMyTurn.java +++ b/Mage/src/mage/abilities/condition/common/NotMyTurnCondition.java @@ -31,8 +31,8 @@ import mage.abilities.Ability; import mage.abilities.condition.Condition; import mage.game.Game; -public class NotMyTurn implements Condition { - private static NotMyTurn fInstance = new NotMyTurn(); +public class NotMyTurnCondition implements Condition { + private static NotMyTurnCondition fInstance = new NotMyTurnCondition(); public static Condition getInstance() { return fInstance; diff --git a/Mage/src/mage/abilities/condition/common/TenOrLessLife.java b/Mage/src/mage/abilities/condition/common/TenOrLessLifeCondition.java similarity index 95% rename from Mage/src/mage/abilities/condition/common/TenOrLessLife.java rename to Mage/src/mage/abilities/condition/common/TenOrLessLifeCondition.java index 0e00cec0f9..80287109f8 100644 --- a/Mage/src/mage/abilities/condition/common/TenOrLessLife.java +++ b/Mage/src/mage/abilities/condition/common/TenOrLessLifeCondition.java @@ -36,13 +36,13 @@ import mage.game.Game; * * @author maurer.it_at_gmail.com */ -public class TenOrLessLife implements Condition { +public class TenOrLessLifeCondition implements Condition { public static enum CheckType { AN_OPPONENT, CONTROLLER, TARGET_OPPONENT }; private CheckType type; - public TenOrLessLife ( CheckType type ) { + public TenOrLessLifeCondition ( CheckType type ) { this.type = type; } diff --git a/Mage/src/mage/abilities/condition/common/Unless.java b/Mage/src/mage/abilities/condition/common/UnlessCondition.java similarity index 95% rename from Mage/src/mage/abilities/condition/common/Unless.java rename to Mage/src/mage/abilities/condition/common/UnlessCondition.java index 22e36f040e..32046116f6 100644 --- a/Mage/src/mage/abilities/condition/common/Unless.java +++ b/Mage/src/mage/abilities/condition/common/UnlessCondition.java @@ -38,11 +38,11 @@ import mage.game.Game; * * @author maurer.it_at_gmail.com */ -public class Unless implements Condition { +public class UnlessCondition implements Condition { private Condition condition; - public Unless ( Condition condition ) { + public UnlessCondition ( Condition condition ) { this.condition = condition; } diff --git a/Mage/src/mage/abilities/effects/common/continious/BoostSourceWhileControlsEffect.java b/Mage/src/mage/abilities/effects/common/continious/BoostSourceWhileControlsEffect.java index c25828de03..3c2a30064d 100644 --- a/Mage/src/mage/abilities/effects/common/continious/BoostSourceWhileControlsEffect.java +++ b/Mage/src/mage/abilities/effects/common/continious/BoostSourceWhileControlsEffect.java @@ -28,7 +28,7 @@ package mage.abilities.effects.common.continious; -import mage.abilities.condition.common.ControlsPermanent; +import mage.abilities.condition.common.ControlsPermanentCondition; import mage.abilities.effects.WhileConditionContiniousEffect; import mage.Constants.Duration; import mage.Constants.Layer; @@ -53,7 +53,7 @@ public class BoostSourceWhileControlsEffect extends WhileConditionContiniousEffe private List filterDescription; public BoostSourceWhileControlsEffect(FilterPermanent filter, int power, int toughness) { - super(Duration.WhileOnBattlefield, Layer.PTChangingEffects_7, SubLayer.ModifyPT_7c, new ControlsPermanent(filter), Outcome.BoostCreature); + super(Duration.WhileOnBattlefield, Layer.PTChangingEffects_7, SubLayer.ModifyPT_7c, new ControlsPermanentCondition(filter), Outcome.BoostCreature); this.power = power; this.toughness = toughness; this.filterDescription = filter.getName(); diff --git a/Mage/src/mage/abilities/keyword/ReboundAbility.java b/Mage/src/mage/abilities/keyword/ReboundAbility.java index d29c001ec2..78a7877593 100644 --- a/Mage/src/mage/abilities/keyword/ReboundAbility.java +++ b/Mage/src/mage/abilities/keyword/ReboundAbility.java @@ -36,7 +36,7 @@ import mage.abilities.Ability; import mage.abilities.DelayedTriggeredAbility; import mage.abilities.SpellAbility; import mage.abilities.TriggeredAbilityImpl; -import mage.abilities.condition.common.MyTurn; +import mage.abilities.condition.common.MyTurnCondition; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.ReplacementEffectImpl; import mage.cards.Card; @@ -254,7 +254,7 @@ class ReboundEffectCastFromExileDelayedTrigger extends DelayedTriggeredAbility().copy(this); return new Library(this); }