Refactoring: CamelCase name for classes. (part 2)

This commit is contained in:
North 2011-07-16 09:32:21 +03:00
parent d976d73040
commit e3f46bbcfa
93 changed files with 178 additions and 178 deletions

View file

@ -35,7 +35,6 @@ import mage.Constants.CardType;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.MageInt; import mage.MageInt;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.common.AttacksTriggeredAbility;
import mage.abilities.effects.Effect; import mage.abilities.effects.Effect;
import mage.abilities.effects.common.PutLibraryIntoGraveTargetEffect; import mage.abilities.effects.common.PutLibraryIntoGraveTargetEffect;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -58,7 +57,7 @@ public class NemesisOfReason extends CardImpl<NemesisOfReason> {
this.color.setBlack(true); this.color.setBlack(true);
this.power = new MageInt(3); this.power = new MageInt(3);
this.toughness = new MageInt(7); this.toughness = new MageInt(7);
this.addAbility(new NemesisofReasonTriggeredAbility()); this.addAbility(new NemesisOfReasonTriggeredAbility());
} }
public NemesisOfReason (final NemesisOfReason card) { public NemesisOfReason (final NemesisOfReason card) {
@ -71,18 +70,18 @@ public class NemesisOfReason extends CardImpl<NemesisOfReason> {
} }
} }
class NemesisofReasonTriggeredAbility extends TriggeredAbilityImpl<NemesisofReasonTriggeredAbility> { class NemesisOfReasonTriggeredAbility extends TriggeredAbilityImpl<NemesisOfReasonTriggeredAbility> {
NemesisofReasonTriggeredAbility() { NemesisOfReasonTriggeredAbility() {
super(Constants.Zone.BATTLEFIELD, new PutLibraryIntoGraveTargetEffect(10)); super(Constants.Zone.BATTLEFIELD, new PutLibraryIntoGraveTargetEffect(10));
} }
NemesisofReasonTriggeredAbility(final NemesisofReasonTriggeredAbility ability) { NemesisOfReasonTriggeredAbility(final NemesisOfReasonTriggeredAbility ability) {
super(ability); super(ability);
} }
@Override @Override
public NemesisofReasonTriggeredAbility copy() { public NemesisOfReasonTriggeredAbility copy() {
return new NemesisofReasonTriggeredAbility(this); return new NemesisOfReasonTriggeredAbility(this);
} }
@Override @Override

View file

@ -30,9 +30,10 @@ package mage.sets.conflux;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
@ -62,7 +63,7 @@ public class WallOfReverence extends CardImpl<WallOfReverence> {
this.toughness = new MageInt(6); this.toughness = new MageInt(6);
this.addAbility(DefenderAbility.getInstance()); this.addAbility(DefenderAbility.getInstance());
this.addAbility(FlyingAbility.getInstance()); this.addAbility(FlyingAbility.getInstance());
this.addAbility(new WallofReverenceTriggeredAbility()); this.addAbility(new WallOfReverenceTriggeredAbility());
} }
public WallOfReverence (final WallOfReverence card) { public WallOfReverence (final WallOfReverence card) {
@ -75,19 +76,19 @@ public class WallOfReverence extends CardImpl<WallOfReverence> {
} }
} }
class WallofReverenceTriggeredAbility extends TriggeredAbilityImpl<WallofReverenceTriggeredAbility> { class WallOfReverenceTriggeredAbility extends TriggeredAbilityImpl<WallOfReverenceTriggeredAbility> {
WallofReverenceTriggeredAbility() { WallOfReverenceTriggeredAbility() {
super(Constants.Zone.BATTLEFIELD, new WallofReverenceTriggeredEffect(), true); super(Zone.BATTLEFIELD, new WallOfReverenceTriggeredEffect(), true);
this.addTarget(new TargetControlledCreaturePermanent()); this.addTarget(new TargetControlledCreaturePermanent());
} }
WallofReverenceTriggeredAbility(final WallofReverenceTriggeredAbility ability) { WallOfReverenceTriggeredAbility(final WallOfReverenceTriggeredAbility ability) {
super(ability); super(ability);
} }
@Override @Override
public WallofReverenceTriggeredAbility copy() { public WallOfReverenceTriggeredAbility copy() {
return new WallofReverenceTriggeredAbility(this); return new WallOfReverenceTriggeredAbility(this);
} }
@Override @Override
@ -104,12 +105,12 @@ class WallofReverenceTriggeredAbility extends TriggeredAbilityImpl<WallofReveren
} }
} }
class WallofReverenceTriggeredEffect extends OneShotEffect<WallofReverenceTriggeredEffect> { class WallOfReverenceTriggeredEffect extends OneShotEffect<WallOfReverenceTriggeredEffect> {
WallofReverenceTriggeredEffect() { WallOfReverenceTriggeredEffect() {
super(Constants.Outcome.GainLife); super(Outcome.GainLife);
} }
WallofReverenceTriggeredEffect(WallofReverenceTriggeredEffect effect) { WallOfReverenceTriggeredEffect(WallOfReverenceTriggeredEffect effect) {
super(effect); super(effect);
} }
@ -125,8 +126,8 @@ class WallofReverenceTriggeredEffect extends OneShotEffect<WallofReverenceTrigge
} }
@Override @Override
public WallofReverenceTriggeredEffect copy() { public WallOfReverenceTriggeredEffect copy() {
return new WallofReverenceTriggeredEffect(this); return new WallOfReverenceTriggeredEffect(this);
} }
@Override @Override

View file

@ -30,9 +30,11 @@ package mage.sets.darksteel;
import java.util.UUID; import java.util.UUID;
import mage.Constants; import mage.Constants.AttachmentType;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
@ -56,7 +58,7 @@ import mage.target.common.TargetCreatureOrPlayer;
*/ */
public class SwordOfFireAndIce extends CardImpl<SwordOfFireAndIce> { public class SwordOfFireAndIce extends CardImpl<SwordOfFireAndIce> {
private static FilterCard filter = new FilterCard("red and from blue"); private static final FilterCard filter = new FilterCard("red and from blue");
static { static {
filter.setUseColor(true); filter.setUseColor(true);
@ -70,10 +72,10 @@ public class SwordOfFireAndIce extends CardImpl<SwordOfFireAndIce> {
super(ownerId, 148, "Sword of Fire and Ice", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}"); super(ownerId, 148, "Sword of Fire and Ice", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}");
this.expansionSetCode = "DST"; this.expansionSetCode = "DST";
this.subtype.add("Equipment"); this.subtype.add("Equipment");
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2)));
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), Constants.AttachmentType.EQUIPMENT))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), AttachmentType.EQUIPMENT)));
this.addAbility(new SwordofFireandIceAbility()); this.addAbility(new SwordOfFireAndIceAbility());
this.addAbility(new EquipAbility(Constants.Outcome.AddAbility, new GenericManaCost(2))); this.addAbility(new EquipAbility(Outcome.AddAbility, new GenericManaCost(2)));
} }
public SwordOfFireAndIce(final SwordOfFireAndIce card) { public SwordOfFireAndIce(final SwordOfFireAndIce card) {
@ -87,21 +89,21 @@ public class SwordOfFireAndIce extends CardImpl<SwordOfFireAndIce> {
} }
class SwordofFireandIceAbility extends TriggeredAbilityImpl<SwordofFireandIceAbility> { class SwordOfFireAndIceAbility extends TriggeredAbilityImpl<SwordOfFireAndIceAbility> {
public SwordofFireandIceAbility() { public SwordOfFireAndIceAbility() {
super(Constants.Zone.BATTLEFIELD, new DamageTargetEffect(2)); super(Zone.BATTLEFIELD, new DamageTargetEffect(2));
this.addEffect(new DrawCardControllerEffect(1)); this.addEffect(new DrawCardControllerEffect(1));
this.addTarget(new TargetCreatureOrPlayer()); this.addTarget(new TargetCreatureOrPlayer());
} }
public SwordofFireandIceAbility(final SwordofFireandIceAbility ability) { public SwordOfFireAndIceAbility(final SwordOfFireAndIceAbility ability) {
super(ability); super(ability);
} }
@Override @Override
public SwordofFireandIceAbility copy() { public SwordOfFireAndIceAbility copy() {
return new SwordofFireandIceAbility(this); return new SwordOfFireAndIceAbility(this);
} }
@Override @Override

View file

@ -30,14 +30,14 @@ package mage.sets.darksteel;
import java.util.UUID; import java.util.UUID;
import mage.Constants; import mage.Constants.AttachmentType;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DamageTargetEffect;
import mage.abilities.effects.common.DrawCardControllerEffect;
import mage.abilities.effects.common.GainLifeEffect; import mage.abilities.effects.common.GainLifeEffect;
import mage.abilities.effects.common.ReturnToHandTargetEffect; import mage.abilities.effects.common.ReturnToHandTargetEffect;
import mage.abilities.effects.common.continious.BoostEquippedEffect; import mage.abilities.effects.common.continious.BoostEquippedEffect;
@ -52,16 +52,14 @@ import mage.game.Game;
import mage.game.events.DamagedPlayerEvent; import mage.game.events.DamagedPlayerEvent;
import mage.game.events.GameEvent; import mage.game.events.GameEvent;
import mage.game.permanent.Permanent; import mage.game.permanent.Permanent;
import mage.target.common.TargetCardInGraveyard;
import mage.target.common.TargetCardInYourGraveyard; import mage.target.common.TargetCardInYourGraveyard;
import mage.target.common.TargetCreatureOrPlayer;
/** /**
* @author Loki * @author Loki
*/ */
public class SwordOfLightAndShadow extends CardImpl<SwordOfLightAndShadow> { public class SwordOfLightAndShadow extends CardImpl<SwordOfLightAndShadow> {
private static FilterCard filter = new FilterCard("white and from black"); private static final FilterCard filter = new FilterCard("white and from black");
static { static {
filter.setUseColor(true); filter.setUseColor(true);
@ -74,10 +72,10 @@ public class SwordOfLightAndShadow extends CardImpl<SwordOfLightAndShadow> {
super(ownerId, 149, "Sword of Light and Shadow", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}"); super(ownerId, 149, "Sword of Light and Shadow", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}");
this.expansionSetCode = "DST"; this.expansionSetCode = "DST";
this.subtype.add("Equipment"); this.subtype.add("Equipment");
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2)));
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), Constants.AttachmentType.EQUIPMENT))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), AttachmentType.EQUIPMENT)));
this.addAbility(new SwordofLightandShadowAbility()); this.addAbility(new SwordOfLightAndShadowAbility());
this.addAbility(new EquipAbility(Constants.Outcome.AddAbility, new GenericManaCost(2))); this.addAbility(new EquipAbility(Outcome.AddAbility, new GenericManaCost(2)));
} }
public SwordOfLightAndShadow(final SwordOfLightAndShadow card) { public SwordOfLightAndShadow(final SwordOfLightAndShadow card) {
@ -91,23 +89,23 @@ public class SwordOfLightAndShadow extends CardImpl<SwordOfLightAndShadow> {
} }
class SwordofLightandShadowAbility extends TriggeredAbilityImpl<SwordofLightandShadowAbility> { class SwordOfLightAndShadowAbility extends TriggeredAbilityImpl<SwordOfLightAndShadowAbility> {
private static FilterCreatureCard filter = new FilterCreatureCard("creature"); private static FilterCreatureCard filter = new FilterCreatureCard("creature");
public SwordofLightandShadowAbility() { public SwordOfLightAndShadowAbility() {
super(Constants.Zone.BATTLEFIELD, new ReturnToHandTargetEffect()); super(Zone.BATTLEFIELD, new ReturnToHandTargetEffect());
this.addEffect(new GainLifeEffect(3)); this.addEffect(new GainLifeEffect(3));
this.addTarget(new TargetCardInYourGraveyard(filter)); this.addTarget(new TargetCardInYourGraveyard(filter));
} }
public SwordofLightandShadowAbility(final SwordofLightandShadowAbility ability) { public SwordOfLightAndShadowAbility(final SwordOfLightAndShadowAbility ability) {
super(ability); super(ability);
} }
@Override @Override
public SwordofLightandShadowAbility copy() { public SwordOfLightAndShadowAbility copy() {
return new SwordofLightandShadowAbility(this); return new SwordOfLightAndShadowAbility(this);
} }
@Override @Override

View file

@ -30,9 +30,9 @@ package mage.sets.darksteel;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleActivatedAbility;
@ -61,10 +61,10 @@ public class WandOfTheElements extends CardImpl<WandOfTheElements> {
public WandOfTheElements(UUID ownerId) { public WandOfTheElements(UUID ownerId) {
super(ownerId, 158, "Wand of the Elements", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{4}"); super(ownerId, 158, "Wand of the Elements", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{4}");
this.expansionSetCode = "DST"; this.expansionSetCode = "DST";
Ability firstAbility = new SimpleActivatedAbility(Constants.Zone.BATTLEFIELD, new CreateTokenEffect(new WandoftheElementsFirstToken()), new TapSourceCost()); Ability firstAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new WandOfTheElementsFirstToken()), new TapSourceCost());
firstAbility.addCost(new SacrificeTargetCost(new TargetControlledPermanent(islandFilter))); firstAbility.addCost(new SacrificeTargetCost(new TargetControlledPermanent(islandFilter)));
this.addAbility(firstAbility); this.addAbility(firstAbility);
Ability secondAbility = new SimpleActivatedAbility(Constants.Zone.BATTLEFIELD, new CreateTokenEffect(new WandoftheElementsSecondToken()), new TapSourceCost()); Ability secondAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new WandOfTheElementsSecondToken()), new TapSourceCost());
secondAbility.addCost(new SacrificeTargetCost(new TargetControlledPermanent(mountainFilter))); secondAbility.addCost(new SacrificeTargetCost(new TargetControlledPermanent(mountainFilter)));
this.addAbility(secondAbility); this.addAbility(secondAbility);
@ -80,8 +80,8 @@ public class WandOfTheElements extends CardImpl<WandOfTheElements> {
} }
} }
class WandoftheElementsFirstToken extends Token { class WandOfTheElementsFirstToken extends Token {
public WandoftheElementsFirstToken() { public WandOfTheElementsFirstToken() {
super("", "2/2 blue Elemental creature token with flying"); super("", "2/2 blue Elemental creature token with flying");
cardType.add(CardType.CREATURE); cardType.add(CardType.CREATURE);
this.subtype.add("Elemental"); this.subtype.add("Elemental");
@ -93,8 +93,8 @@ class WandoftheElementsFirstToken extends Token {
} }
class WandoftheElementsSecondToken extends Token { class WandOfTheElementsSecondToken extends Token {
public WandoftheElementsSecondToken() { public WandOfTheElementsSecondToken() {
super("", "3/3 red Elemental creature token"); super("", "3/3 red Elemental creature token");
cardType.add(CardType.CREATURE); cardType.add(CardType.CREATURE);
this.subtype.add("Elemental"); this.subtype.add("Elemental");

View file

@ -25,14 +25,14 @@
* authors and should not be interpreted as representing official policies, either expressed * authors and should not be interpreted as representing official policies, either expressed
* or implied, of BetaSteward_at_googlemail.com. * or implied, of BetaSteward_at_googlemail.com.
*/ */
package mage.sets.eventide; package mage.sets.eventide;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Duration;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
@ -51,7 +51,7 @@ import mage.players.Player;
*/ */
public class DivinityOfPride extends CardImpl<DivinityOfPride> { public class DivinityOfPride extends CardImpl<DivinityOfPride> {
public DivinityOfPride (UUID ownerId) { public DivinityOfPride(UUID ownerId) {
super(ownerId, 86, "Divinity of Pride", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{W/B}{W/B}{W/B}{W/B}{W/B}"); super(ownerId, 86, "Divinity of Pride", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{W/B}{W/B}{W/B}{W/B}{W/B}");
this.expansionSetCode = "EVE"; this.expansionSetCode = "EVE";
this.subtype.add("Spirit"); this.subtype.add("Spirit");
@ -62,10 +62,13 @@ public class DivinityOfPride extends CardImpl<DivinityOfPride> {
this.toughness = new MageInt(4); this.toughness = new MageInt(4);
this.addAbility(FlyingAbility.getInstance()); this.addAbility(FlyingAbility.getInstance());
this.addAbility(LifelinkAbility.getInstance()); this.addAbility(LifelinkAbility.getInstance());
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new ConditionalContinousEffect(new BoostSourceEffect(4, 4, Constants.Duration.WhileOnBattlefield), new DivinityofPrideCondition(), "Divinity of Pride gets +4/+4 as long as you have 25 or more life"))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD,
new ConditionalContinousEffect(new BoostSourceEffect(4, 4, Duration.WhileOnBattlefield),
new DivinityOfPrideCondition(),
"Divinity of Pride gets +4/+4 as long as you have 25 or more life")));
} }
public DivinityOfPride (final DivinityOfPride card) { public DivinityOfPride(final DivinityOfPride card) {
super(card); super(card);
} }
@ -73,10 +76,9 @@ public class DivinityOfPride extends CardImpl<DivinityOfPride> {
public DivinityOfPride copy() { public DivinityOfPride copy() {
return new DivinityOfPride(this); return new DivinityOfPride(this);
} }
} }
class DivinityofPrideCondition implements Condition { class DivinityOfPrideCondition implements Condition {
@Override @Override
public boolean apply(Game game, Ability source) { public boolean apply(Game game, Ability source) {

View file

@ -28,12 +28,12 @@
package mage.sets.guildpact; package mage.sets.guildpact;
import java.awt.font.TextHitInfo;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.DelayedTriggeredAbility; import mage.abilities.DelayedTriggeredAbility;
@ -66,10 +66,10 @@ public class GhostCouncilOfOrzhova extends CardImpl<GhostCouncilOfOrzhova> {
this.color.setBlack(true); this.color.setBlack(true);
this.power = new MageInt(4); this.power = new MageInt(4);
this.toughness = new MageInt(4); this.toughness = new MageInt(4);
Ability ability = new EntersBattlefieldTriggeredAbility(new GhostCouncilofOrzhovaEffect()); Ability ability = new EntersBattlefieldTriggeredAbility(new GhostCouncilOfOrzhovaEffect());
ability.addTarget(new TargetOpponent()); ability.addTarget(new TargetOpponent());
this.addAbility(ability); this.addAbility(ability);
ability = new SimpleActivatedAbility(Constants.Zone.BATTLEFIELD, new GhostCouncilofOrzhovaRemovingEffect(), new GenericManaCost(1)); ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GhostCouncilOfOrzhovaRemovingEffect(), new GenericManaCost(1));
ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent()));
this.addAbility(ability); this.addAbility(ability);
} }
@ -85,12 +85,12 @@ public class GhostCouncilOfOrzhova extends CardImpl<GhostCouncilOfOrzhova> {
} }
class GhostCouncilofOrzhovaEffect extends OneShotEffect<GhostCouncilofOrzhovaEffect> { class GhostCouncilOfOrzhovaEffect extends OneShotEffect<GhostCouncilOfOrzhovaEffect> {
GhostCouncilofOrzhovaEffect() { GhostCouncilOfOrzhovaEffect() {
super(Constants.Outcome.Damage); super(Outcome.Damage);
} }
GhostCouncilofOrzhovaEffect(final GhostCouncilofOrzhovaEffect effect) { GhostCouncilOfOrzhovaEffect(final GhostCouncilOfOrzhovaEffect effect) {
super(effect); super(effect);
} }
@ -106,8 +106,8 @@ class GhostCouncilofOrzhovaEffect extends OneShotEffect<GhostCouncilofOrzhovaEff
} }
@Override @Override
public GhostCouncilofOrzhovaEffect copy() { public GhostCouncilOfOrzhovaEffect copy() {
return new GhostCouncilofOrzhovaEffect(this); return new GhostCouncilOfOrzhovaEffect(this);
} }
@Override @Override
@ -116,15 +116,15 @@ class GhostCouncilofOrzhovaEffect extends OneShotEffect<GhostCouncilofOrzhovaEff
} }
} }
class GhostCouncilofOrzhovaRemovingEffect extends OneShotEffect<GhostCouncilofOrzhovaRemovingEffect> { class GhostCouncilOfOrzhovaRemovingEffect extends OneShotEffect<GhostCouncilOfOrzhovaRemovingEffect> {
private static final String effectText = "Exile Ghost Council of Orzhova. Return it to the battlefield under its owner's control at the beginning of the next end step"; private static final String effectText = "Exile Ghost Council of Orzhova. Return it to the battlefield under its owner's control at the beginning of the next end step";
GhostCouncilofOrzhovaRemovingEffect () { GhostCouncilOfOrzhovaRemovingEffect () {
super(Constants.Outcome.Benefit); super(Outcome.Benefit);
} }
GhostCouncilofOrzhovaRemovingEffect(GhostCouncilofOrzhovaRemovingEffect effect) { GhostCouncilOfOrzhovaRemovingEffect(GhostCouncilOfOrzhovaRemovingEffect effect) {
super(effect); super(effect);
} }
@ -134,7 +134,7 @@ class GhostCouncilofOrzhovaRemovingEffect extends OneShotEffect<GhostCouncilofOr
if (permanent != null) { if (permanent != null) {
if (permanent.moveToExile(source.getSourceId(), " Ghost Council of Orzhova Exile", source.getId(), game)) { if (permanent.moveToExile(source.getSourceId(), " Ghost Council of Orzhova Exile", source.getId(), game)) {
//create delayed triggered ability //create delayed triggered ability
GhostCouncilofOrzhovaDelayedTriggeredAbility delayedAbility = new GhostCouncilofOrzhovaDelayedTriggeredAbility(source.getSourceId()); GhostCouncilOfOrzhovaDelayedTriggeredAbility delayedAbility = new GhostCouncilOfOrzhovaDelayedTriggeredAbility(source.getSourceId());
delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setSourceId(source.getSourceId());
delayedAbility.setControllerId(source.getControllerId()); delayedAbility.setControllerId(source.getControllerId());
game.addDelayedTriggeredAbility(delayedAbility); game.addDelayedTriggeredAbility(delayedAbility);
@ -145,8 +145,8 @@ class GhostCouncilofOrzhovaRemovingEffect extends OneShotEffect<GhostCouncilofOr
} }
@Override @Override
public GhostCouncilofOrzhovaRemovingEffect copy() { public GhostCouncilOfOrzhovaRemovingEffect copy() {
return new GhostCouncilofOrzhovaRemovingEffect(this); return new GhostCouncilOfOrzhovaRemovingEffect(this);
} }
@Override @Override
@ -155,13 +155,13 @@ class GhostCouncilofOrzhovaRemovingEffect extends OneShotEffect<GhostCouncilofOr
} }
} }
class GhostCouncilofOrzhovaDelayedTriggeredAbility extends DelayedTriggeredAbility<GhostCouncilofOrzhovaDelayedTriggeredAbility> { class GhostCouncilOfOrzhovaDelayedTriggeredAbility extends DelayedTriggeredAbility<GhostCouncilOfOrzhovaDelayedTriggeredAbility> {
GhostCouncilofOrzhovaDelayedTriggeredAbility ( UUID exileId ) { GhostCouncilOfOrzhovaDelayedTriggeredAbility ( UUID exileId ) {
super(new ReturnFromExileEffect(exileId, Constants.Zone.BATTLEFIELD)); super(new ReturnFromExileEffect(exileId, Zone.BATTLEFIELD));
} }
GhostCouncilofOrzhovaDelayedTriggeredAbility(GhostCouncilofOrzhovaDelayedTriggeredAbility ability) { GhostCouncilOfOrzhovaDelayedTriggeredAbility(GhostCouncilOfOrzhovaDelayedTriggeredAbility ability) {
super(ability); super(ability);
} }
@ -173,7 +173,7 @@ class GhostCouncilofOrzhovaDelayedTriggeredAbility extends DelayedTriggeredAbili
return false; return false;
} }
@Override @Override
public GhostCouncilofOrzhovaDelayedTriggeredAbility copy() { public GhostCouncilOfOrzhovaDelayedTriggeredAbility copy() {
return new GhostCouncilofOrzhovaDelayedTriggeredAbility(this); return new GhostCouncilOfOrzhovaDelayedTriggeredAbility(this);
} }
} }

View file

@ -30,8 +30,8 @@ package mage.sets.mirrodinbesieged;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
@ -58,7 +58,7 @@ public class HeroOfBladehold extends CardImpl<HeroOfBladehold> {
this.power = new MageInt(3); this.power = new MageInt(3);
this.toughness = new MageInt(4); this.toughness = new MageInt(4);
this.addAbility(new BattleCryAbility()); this.addAbility(new BattleCryAbility());
this.addAbility(new AttacksTriggeredAbility(new HeroofBladeholdEffect(), false)); this.addAbility(new AttacksTriggeredAbility(new HeroOfBladeholdEffect(), false));
} }
public HeroOfBladehold(final HeroOfBladehold card) { public HeroOfBladehold(final HeroOfBladehold card) {
@ -72,12 +72,12 @@ public class HeroOfBladehold extends CardImpl<HeroOfBladehold> {
} }
class HeroofBladeholdEffect extends OneShotEffect<HeroofBladeholdEffect> { class HeroOfBladeholdEffect extends OneShotEffect<HeroOfBladeholdEffect> {
HeroofBladeholdEffect() { HeroOfBladeholdEffect() {
super(Constants.Outcome.PutCreatureInPlay); super(Outcome.PutCreatureInPlay);
} }
HeroofBladeholdEffect(final HeroofBladeholdEffect effect) { HeroOfBladeholdEffect(final HeroOfBladeholdEffect effect) {
super(effect); super(effect);
} }
@ -97,8 +97,8 @@ class HeroofBladeholdEffect extends OneShotEffect<HeroofBladeholdEffect> {
} }
@Override @Override
public HeroofBladeholdEffect copy() { public HeroOfBladeholdEffect copy() {
return new HeroofBladeholdEffect(this); return new HeroOfBladeholdEffect(this);
} }
@Override @Override

View file

@ -30,18 +30,18 @@ package mage.sets.newphyrexia;
import java.util.UUID; import java.util.UUID;
import mage.Constants; import mage.Constants.AttachmentType;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.dynamicvalue.common.CardsInControllerHandCount; import mage.abilities.dynamicvalue.common.CardsInControllerHandCount;
import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.OneShotEffect;
import mage.abilities.effects.common.DiscardTargetEffect;
import mage.abilities.effects.common.GainLifeEffect; import mage.abilities.effects.common.GainLifeEffect;
import mage.abilities.effects.common.UntapAllLandsControllerEffect;
import mage.abilities.effects.common.continious.BoostEquippedEffect; import mage.abilities.effects.common.continious.BoostEquippedEffect;
import mage.abilities.effects.common.continious.GainAbilityAttachedEffect; import mage.abilities.effects.common.continious.GainAbilityAttachedEffect;
import mage.abilities.keyword.EquipAbility; import mage.abilities.keyword.EquipAbility;
@ -61,7 +61,7 @@ import mage.target.TargetPlayer;
* @author Loki * @author Loki
*/ */
public class SwordOfWarAndPeace extends CardImpl<SwordOfWarAndPeace> { public class SwordOfWarAndPeace extends CardImpl<SwordOfWarAndPeace> {
private static FilterCard filter = new FilterCard("red and from white"); private static final FilterCard filter = new FilterCard("red and from white");
static { static {
filter.setUseColor(true); filter.setUseColor(true);
@ -74,10 +74,10 @@ public class SwordOfWarAndPeace extends CardImpl<SwordOfWarAndPeace> {
super(ownerId, 161, "Sword of War and Peace", Rarity.MYTHIC, new CardType[]{CardType.ARTIFACT}, "{3}"); super(ownerId, 161, "Sword of War and Peace", Rarity.MYTHIC, new CardType[]{CardType.ARTIFACT}, "{3}");
this.expansionSetCode = "NPH"; this.expansionSetCode = "NPH";
this.subtype.add("Equipment"); this.subtype.add("Equipment");
this.addAbility(new EquipAbility(Constants.Outcome.AddAbility, new GenericManaCost(2))); this.addAbility(new EquipAbility(Outcome.AddAbility, new GenericManaCost(2)));
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2)));
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), Constants.AttachmentType.EQUIPMENT))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), AttachmentType.EQUIPMENT)));
this.addAbility(new SwordofWarandPeaceAbility()); this.addAbility(new SwordOfWarAndPeaceAbility());
} }
public SwordOfWarAndPeace (final SwordOfWarAndPeace card) { public SwordOfWarAndPeace (final SwordOfWarAndPeace card) {
@ -91,21 +91,21 @@ public class SwordOfWarAndPeace extends CardImpl<SwordOfWarAndPeace> {
} }
class SwordofWarandPeaceAbility extends TriggeredAbilityImpl<SwordofWarandPeaceAbility> { class SwordOfWarAndPeaceAbility extends TriggeredAbilityImpl<SwordOfWarAndPeaceAbility> {
public SwordofWarandPeaceAbility() { public SwordOfWarAndPeaceAbility() {
super(Constants.Zone.BATTLEFIELD, new SwordofWarandPeaceDamageEffect()); super(Zone.BATTLEFIELD, new SwordOfWarAndPeaceDamageEffect());
this.addEffect(new GainLifeEffect(new CardsInControllerHandCount())); this.addEffect(new GainLifeEffect(new CardsInControllerHandCount()));
this.addTarget(new TargetPlayer()); this.addTarget(new TargetPlayer());
} }
public SwordofWarandPeaceAbility(final SwordofWarandPeaceAbility ability) { public SwordOfWarAndPeaceAbility(final SwordOfWarAndPeaceAbility ability) {
super(ability); super(ability);
} }
@Override @Override
public SwordofWarandPeaceAbility copy() { public SwordOfWarAndPeaceAbility copy() {
return new SwordofWarandPeaceAbility(this); return new SwordOfWarAndPeaceAbility(this);
} }
@Override @Override
@ -127,12 +127,12 @@ class SwordofWarandPeaceAbility extends TriggeredAbilityImpl<SwordofWarandPeaceA
} }
} }
class SwordofWarandPeaceDamageEffect extends OneShotEffect<SwordofWarandPeaceDamageEffect> { class SwordOfWarAndPeaceDamageEffect extends OneShotEffect<SwordOfWarAndPeaceDamageEffect> {
SwordofWarandPeaceDamageEffect() { SwordOfWarAndPeaceDamageEffect() {
super(Constants.Outcome.Damage); super(Outcome.Damage);
} }
SwordofWarandPeaceDamageEffect(final SwordofWarandPeaceDamageEffect effect) { SwordOfWarAndPeaceDamageEffect(final SwordOfWarAndPeaceDamageEffect effect) {
super(effect); super(effect);
} }
@ -146,8 +146,8 @@ class SwordofWarandPeaceDamageEffect extends OneShotEffect<SwordofWarandPeaceDam
} }
@Override @Override
public SwordofWarandPeaceDamageEffect copy() { public SwordOfWarAndPeaceDamageEffect copy() {
return new SwordofWarandPeaceDamageEffect(this); return new SwordOfWarAndPeaceDamageEffect(this);
} }
@Override @Override

View file

@ -30,9 +30,10 @@ package mage.sets.riseoftheeldrazi;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
@ -59,9 +60,9 @@ public class KozilekButcherOfTruth extends CardImpl<KozilekButcherOfTruth> {
this.subtype.add("Eldrazi"); this.subtype.add("Eldrazi");
this.power = new MageInt(12); this.power = new MageInt(12);
this.toughness = new MageInt(12); this.toughness = new MageInt(12);
this.addAbility(new KozilekButcherofTruthOnCastAbility()); this.addAbility(new KozilekButcherOfTruthOnCastAbility());
this.addAbility(new AnnihilatorAbility(4)); this.addAbility(new AnnihilatorAbility(4));
this.addAbility(new PutIntoGraveFromAnywhereTriggeredAbility(new KozilekButcherofTruthEffect(), false)); this.addAbility(new PutIntoGraveFromAnywhereTriggeredAbility(new KozilekButcherOfTruthEffect(), false));
} }
public KozilekButcherOfTruth (final KozilekButcherOfTruth card) { public KozilekButcherOfTruth (final KozilekButcherOfTruth card) {
@ -75,15 +76,15 @@ public class KozilekButcherOfTruth extends CardImpl<KozilekButcherOfTruth> {
} }
class KozilekButcherofTruthOnCastAbility extends TriggeredAbilityImpl<KozilekButcherofTruthOnCastAbility> { class KozilekButcherOfTruthOnCastAbility extends TriggeredAbilityImpl<KozilekButcherOfTruthOnCastAbility> {
private static final String abilityText = "When you cast Kozilek, Butcher of Truth, draw four cards"; private static final String abilityText = "When you cast Kozilek, Butcher of Truth, draw four cards";
KozilekButcherofTruthOnCastAbility() { KozilekButcherOfTruthOnCastAbility() {
super(Constants.Zone.STACK, new DrawCardControllerEffect(4)); super(Zone.STACK, new DrawCardControllerEffect(4));
} }
KozilekButcherofTruthOnCastAbility(final KozilekButcherofTruthOnCastAbility ability) { KozilekButcherOfTruthOnCastAbility(final KozilekButcherOfTruthOnCastAbility ability) {
super(ability); super(ability);
} }
@ -99,8 +100,8 @@ class KozilekButcherofTruthOnCastAbility extends TriggeredAbilityImpl<KozilekBut
} }
@Override @Override
public KozilekButcherofTruthOnCastAbility copy() { public KozilekButcherOfTruthOnCastAbility copy() {
return new KozilekButcherofTruthOnCastAbility(this); return new KozilekButcherOfTruthOnCastAbility(this);
} }
@Override @Override
@ -109,12 +110,12 @@ class KozilekButcherofTruthOnCastAbility extends TriggeredAbilityImpl<KozilekBut
} }
} }
class KozilekButcherofTruthEffect extends OneShotEffect<KozilekButcherofTruthEffect> { class KozilekButcherOfTruthEffect extends OneShotEffect<KozilekButcherOfTruthEffect> {
KozilekButcherofTruthEffect() { KozilekButcherOfTruthEffect() {
super(Constants.Outcome.Benefit); super(Outcome.Benefit);
} }
KozilekButcherofTruthEffect(final KozilekButcherofTruthEffect effect) { KozilekButcherOfTruthEffect(final KozilekButcherOfTruthEffect effect) {
super(effect); super(effect);
} }
@ -133,8 +134,8 @@ class KozilekButcherofTruthEffect extends OneShotEffect<KozilekButcherofTruthEff
} }
@Override @Override
public KozilekButcherofTruthEffect copy() { public KozilekButcherOfTruthEffect copy() {
return new KozilekButcherofTruthEffect(this); return new KozilekButcherOfTruthEffect(this);
} }
@Override @Override

View file

@ -30,13 +30,14 @@ package mage.sets.riseoftheeldrazi;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Duration;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.effects.ReplacementEffect;
import mage.abilities.effects.ReplacementEffectImpl; import mage.abilities.effects.ReplacementEffectImpl;
import mage.abilities.keyword.FlyingAbility; import mage.abilities.keyword.FlyingAbility;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -44,7 +45,6 @@ import mage.game.Game;
import mage.game.events.GameEvent; import mage.game.events.GameEvent;
import mage.game.permanent.Permanent; import mage.game.permanent.Permanent;
import javax.xml.datatype.Duration;
/** /**
* *
@ -61,7 +61,7 @@ public class LinvalaKeeperOfSilence extends CardImpl<LinvalaKeeperOfSilence> {
this.power = new MageInt(3); this.power = new MageInt(3);
this.toughness = new MageInt(4); this.toughness = new MageInt(4);
this.addAbility(FlyingAbility.getInstance()); this.addAbility(FlyingAbility.getInstance());
this.addAbility(new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, new LinvalaKeeperofSilenceEffect())); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new LinvalaKeeperOfSilenceEffect()));
} }
public LinvalaKeeperOfSilence (final LinvalaKeeperOfSilence card) { public LinvalaKeeperOfSilence (final LinvalaKeeperOfSilence card) {
@ -74,12 +74,12 @@ public class LinvalaKeeperOfSilence extends CardImpl<LinvalaKeeperOfSilence> {
} }
} }
class LinvalaKeeperofSilenceEffect extends ReplacementEffectImpl<LinvalaKeeperofSilenceEffect> { class LinvalaKeeperOfSilenceEffect extends ReplacementEffectImpl<LinvalaKeeperOfSilenceEffect> {
LinvalaKeeperofSilenceEffect() { LinvalaKeeperOfSilenceEffect() {
super(Constants.Duration.WhileOnBattlefield, Constants.Outcome.Detriment); super(Duration.WhileOnBattlefield, Outcome.Detriment);
} }
LinvalaKeeperofSilenceEffect(final LinvalaKeeperofSilenceEffect effect) { LinvalaKeeperOfSilenceEffect(final LinvalaKeeperOfSilenceEffect effect) {
super(effect); super(effect);
} }
@ -104,8 +104,8 @@ class LinvalaKeeperofSilenceEffect extends ReplacementEffectImpl<LinvalaKeeperof
} }
@Override @Override
public LinvalaKeeperofSilenceEffect copy() { public LinvalaKeeperOfSilenceEffect copy() {
return new LinvalaKeeperofSilenceEffect(this); return new LinvalaKeeperOfSilenceEffect(this);
} }
@Override @Override

View file

@ -40,7 +40,6 @@ import mage.abilities.effects.OneShotEffect;
import mage.abilities.effects.common.DestroyTargetEffect; import mage.abilities.effects.common.DestroyTargetEffect;
import mage.abilities.keyword.AnnihilatorAbility; import mage.abilities.keyword.AnnihilatorAbility;
import mage.abilities.keyword.IndestructibleAbility; import mage.abilities.keyword.IndestructibleAbility;
import mage.cards.Card;
import mage.cards.CardImpl; import mage.cards.CardImpl;
import mage.game.Game; import mage.game.Game;
import mage.game.events.GameEvent; import mage.game.events.GameEvent;
@ -66,10 +65,10 @@ public class UlamogTheInfiniteGyre extends CardImpl<UlamogTheInfiniteGyre> {
this.power = new MageInt(10); this.power = new MageInt(10);
this.toughness = new MageInt(10); this.toughness = new MageInt(10);
this.addAbility(new UlamogtheInfiniteGyreDestroyOnCastAbility()); this.addAbility(new UlamogTheInfiniteGyreDestroyOnCastAbility());
this.addAbility(new AnnihilatorAbility(4)); this.addAbility(new AnnihilatorAbility(4));
this.addAbility(IndestructibleAbility.getInstance()); this.addAbility(IndestructibleAbility.getInstance());
this.addAbility(new ZoneChangeTriggeredAbility(Zone.GRAVEYARD, new UlamogtheInfiniteGyreEnterGraveyardEffect(), effectText, false)); this.addAbility(new ZoneChangeTriggeredAbility(Zone.GRAVEYARD, new UlamogTheInfiniteGyreEnterGraveyardEffect(), effectText, false));
} }
public UlamogTheInfiniteGyre(final UlamogTheInfiniteGyre card) { public UlamogTheInfiniteGyre(final UlamogTheInfiniteGyre card) {
@ -82,16 +81,16 @@ public class UlamogTheInfiniteGyre extends CardImpl<UlamogTheInfiniteGyre> {
} }
} }
class UlamogtheInfiniteGyreDestroyOnCastAbility extends TriggeredAbilityImpl<UlamogtheInfiniteGyreDestroyOnCastAbility> { class UlamogTheInfiniteGyreDestroyOnCastAbility extends TriggeredAbilityImpl<UlamogTheInfiniteGyreDestroyOnCastAbility> {
private static final String abilityText = "When you cast Ulamog, the Infinite Gyre, destroy target permanent"; private static final String abilityText = "When you cast Ulamog, the Infinite Gyre, destroy target permanent";
UlamogtheInfiniteGyreDestroyOnCastAbility ( ) { UlamogTheInfiniteGyreDestroyOnCastAbility ( ) {
super(Zone.STACK, new DestroyTargetEffect()); super(Zone.STACK, new DestroyTargetEffect());
this.addTarget(new TargetPermanent()); this.addTarget(new TargetPermanent());
} }
UlamogtheInfiniteGyreDestroyOnCastAbility(UlamogtheInfiniteGyreDestroyOnCastAbility ability) { UlamogTheInfiniteGyreDestroyOnCastAbility(UlamogTheInfiniteGyreDestroyOnCastAbility ability) {
super(ability); super(ability);
} }
@ -107,8 +106,8 @@ class UlamogtheInfiniteGyreDestroyOnCastAbility extends TriggeredAbilityImpl<Ula
} }
@Override @Override
public UlamogtheInfiniteGyreDestroyOnCastAbility copy() { public UlamogTheInfiniteGyreDestroyOnCastAbility copy() {
return new UlamogtheInfiniteGyreDestroyOnCastAbility(this); return new UlamogTheInfiniteGyreDestroyOnCastAbility(this);
} }
@Override @Override
@ -117,22 +116,20 @@ class UlamogtheInfiniteGyreDestroyOnCastAbility extends TriggeredAbilityImpl<Ula
} }
} }
class UlamogtheInfiniteGyreEnterGraveyardEffect extends OneShotEffect<UlamogtheInfiniteGyreEnterGraveyardEffect> { class UlamogTheInfiniteGyreEnterGraveyardEffect extends OneShotEffect<UlamogTheInfiniteGyreEnterGraveyardEffect> {
UlamogtheInfiniteGyreEnterGraveyardEffect ( ) { UlamogTheInfiniteGyreEnterGraveyardEffect ( ) {
super(Outcome.Benefit); super(Outcome.Benefit);
} }
UlamogtheInfiniteGyreEnterGraveyardEffect(UlamogtheInfiniteGyreEnterGraveyardEffect effect) { UlamogTheInfiniteGyreEnterGraveyardEffect(UlamogTheInfiniteGyreEnterGraveyardEffect effect) {
super(effect); super(effect);
} }
@Override @Override
public boolean apply(Game game, Ability source) { public boolean apply(Game game, Ability source) {
Player player = game.getPlayer(source.getControllerId()); Player player = game.getPlayer(source.getControllerId());
/*Card permanent = (Card)game.getObject(source.getSourceId());*/ if (player != null) {
if (player != null /* && permanent != null */) {
/*permanent.moveToZone(Zone.LIBRARY, source.getId(), game, true);*/
player.getLibrary().addAll(player.getGraveyard().getCards(game), game); player.getLibrary().addAll(player.getGraveyard().getCards(game), game);
player.getGraveyard().clear(); player.getGraveyard().clear();
player.getLibrary().shuffle(); player.getLibrary().shuffle();
@ -142,7 +139,7 @@ class UlamogtheInfiniteGyreEnterGraveyardEffect extends OneShotEffect<UlamogtheI
} }
@Override @Override
public UlamogtheInfiniteGyreEnterGraveyardEffect copy() { public UlamogTheInfiniteGyreEnterGraveyardEffect copy() {
return new UlamogtheInfiniteGyreEnterGraveyardEffect(this); return new UlamogTheInfiniteGyreEnterGraveyardEffect(this);
} }
} }

View file

@ -30,8 +30,8 @@ package mage.sets.scarsofmirrodin;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone; import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
@ -58,7 +58,7 @@ import mage.target.TargetCard;
*/ */
public class GethLordOfTheVault extends CardImpl<GethLordOfTheVault> { public class GethLordOfTheVault extends CardImpl<GethLordOfTheVault> {
private static FilterCard filter = new FilterCard("artifact or creature card"); private static final FilterCard filter = new FilterCard("artifact or creature card");
static { static {
filter.getCardType().add(CardType.CREATURE); filter.getCardType().add(CardType.CREATURE);
@ -76,8 +76,8 @@ public class GethLordOfTheVault extends CardImpl<GethLordOfTheVault> {
this.toughness = new MageInt(5); this.toughness = new MageInt(5);
this.addAbility(IntimidateAbility.getInstance()); this.addAbility(IntimidateAbility.getInstance());
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GethLordoftheVaultEffect(), new ManaCostsImpl("{X}{B}")); Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GethLordOfTheVaultEffect(), new ManaCostsImpl("{X}{B}"));
ability.addTarget(new GethLordoftheVaultEffectTarget(filter)); ability.addTarget(new GethLordOfTheVaultEffectTarget(filter));
this.addAbility(ability); this.addAbility(ability);
} }
@ -106,13 +106,13 @@ public class GethLordOfTheVault extends CardImpl<GethLordOfTheVault> {
} }
} }
class GethLordoftheVaultEffect extends OneShotEffect<GethLordoftheVaultEffect> { class GethLordOfTheVaultEffect extends OneShotEffect<GethLordOfTheVaultEffect> {
public GethLordoftheVaultEffect() { public GethLordOfTheVaultEffect() {
super(Constants.Outcome.Benefit); super(Outcome.Benefit);
} }
public GethLordoftheVaultEffect(final GethLordoftheVaultEffect effect) { public GethLordOfTheVaultEffect(final GethLordOfTheVaultEffect effect) {
super(effect); super(effect);
} }
@ -150,8 +150,8 @@ class GethLordoftheVaultEffect extends OneShotEffect<GethLordoftheVaultEffect> {
} }
@Override @Override
public GethLordoftheVaultEffect copy() { public GethLordOfTheVaultEffect copy() {
return new GethLordoftheVaultEffect(this); return new GethLordOfTheVaultEffect(this);
} }
@Override @Override
@ -160,18 +160,18 @@ class GethLordoftheVaultEffect extends OneShotEffect<GethLordoftheVaultEffect> {
} }
} }
class GethLordoftheVaultEffectTarget extends TargetCard<GethLordoftheVaultEffectTarget> { class GethLordOfTheVaultEffectTarget extends TargetCard<GethLordOfTheVaultEffectTarget> {
public GethLordoftheVaultEffectTarget(FilterCard filter) { public GethLordOfTheVaultEffectTarget(FilterCard filter) {
this(1, 1, filter); this(1, 1, filter);
} }
public GethLordoftheVaultEffectTarget(int minNumTargets, int maxNumTargets, FilterCard filter) { public GethLordOfTheVaultEffectTarget(int minNumTargets, int maxNumTargets, FilterCard filter) {
super(minNumTargets, maxNumTargets, Zone.GRAVEYARD, filter); super(minNumTargets, maxNumTargets, Zone.GRAVEYARD, filter);
this.targetName = filter.getMessage() + " from an opponent's graveyard"; this.targetName = filter.getMessage() + " from an opponent's graveyard";
} }
public GethLordoftheVaultEffectTarget(final GethLordoftheVaultEffectTarget target) { public GethLordOfTheVaultEffectTarget(final GethLordOfTheVaultEffectTarget target) {
super(target); super(target);
} }
@ -192,7 +192,7 @@ class GethLordoftheVaultEffectTarget extends TargetCard<GethLordoftheVaultEffect
} }
@Override @Override
public GethLordoftheVaultEffectTarget copy() { public GethLordOfTheVaultEffectTarget copy() {
return new GethLordoftheVaultEffectTarget(this); return new GethLordOfTheVaultEffectTarget(this);
} }
} }

View file

@ -30,13 +30,13 @@ package mage.sets.scarsofmirrodin;
import java.util.UUID; import java.util.UUID;
import mage.Constants;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Duration; import mage.Constants.Duration;
import mage.Constants.Layer; import mage.Constants.Layer;
import mage.Constants.Outcome; import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.SubLayer; import mage.Constants.SubLayer;
import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
@ -83,7 +83,7 @@ public class LiegeOfTheTangle extends CardImpl<LiegeOfTheTangle> {
class LiegeOfTheTangleTriggeredAbility extends TriggeredAbilityImpl<LiegeOfTheTangleTriggeredAbility> { class LiegeOfTheTangleTriggeredAbility extends TriggeredAbilityImpl<LiegeOfTheTangleTriggeredAbility> {
LiegeOfTheTangleTriggeredAbility() { LiegeOfTheTangleTriggeredAbility() {
super(Constants.Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.AWAKENING.createInstance())); super(Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.AWAKENING.createInstance()));
this.addEffect(new LiegeOfTheTangleEffect()); this.addEffect(new LiegeOfTheTangleEffect());
// Ability ability = new SimpleStaticAbility(Constants.Zone.BATTLEFIELD, // Ability ability = new SimpleStaticAbility(Constants.Zone.BATTLEFIELD,
// new ConditionalContinousEffect( // new ConditionalContinousEffect(
@ -196,7 +196,7 @@ class AwakeningLandToken extends Token {
public AwakeningLandToken() { public AwakeningLandToken() {
super("", "an 8/8 green Elemental creature"); super("", "an 8/8 green Elemental creature");
cardType.add(Constants.CardType.CREATURE); cardType.add(CardType.CREATURE);
color.setGreen(true); color.setGreen(true);
subtype.add("Elemental"); subtype.add("Elemental");
power = new MageInt(8); power = new MageInt(8);

View file

@ -30,8 +30,9 @@ package mage.sets.scarsofmirrodin;
import java.util.UUID; import java.util.UUID;
import mage.Constants; import mage.Constants.AttachmentType;
import mage.Constants.CardType; import mage.Constants.CardType;
import mage.Constants.Outcome;
import mage.Constants.Rarity; import mage.Constants.Rarity;
import mage.Constants.Zone; import mage.Constants.Zone;
import mage.MageInt; import mage.MageInt;
@ -75,9 +76,9 @@ public class SwordOfBodyAndMind extends CardImpl<SwordOfBodyAndMind> {
super(ownerId, 208, "Sword of Body and Mind", Rarity.MYTHIC, new CardType[]{CardType.ARTIFACT}, "{3}"); super(ownerId, 208, "Sword of Body and Mind", Rarity.MYTHIC, new CardType[]{CardType.ARTIFACT}, "{3}");
this.expansionSetCode = "SOM"; this.expansionSetCode = "SOM";
this.subtype.add("Equipment"); this.subtype.add("Equipment");
this.addAbility(new EquipAbility(Constants.Outcome.AddAbility, new GenericManaCost(2))); this.addAbility(new EquipAbility(Outcome.AddAbility, new GenericManaCost(2)));
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(2, 2)));
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), Constants.AttachmentType.EQUIPMENT))); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), AttachmentType.EQUIPMENT)));
this.addAbility(new SwordOfBodyAndMindAbility()); this.addAbility(new SwordOfBodyAndMindAbility());
} }

View file

@ -39,7 +39,6 @@ import mage.abilities.Ability;
import mage.cards.Card; import mage.cards.Card;
import mage.game.Game; import mage.game.Game;
import mage.game.events.ZoneChangeEvent; import mage.game.events.ZoneChangeEvent;
import mage.game.permanent.Permanent;
import mage.game.permanent.PermanentToken; import mage.game.permanent.PermanentToken;
public class Token extends MageObjectImpl<Token> { public class Token extends MageObjectImpl<Token> {