Merge origin/master

This commit is contained in:
fireshoes 2016-11-02 10:26:02 -05:00
commit c85d71049a
33 changed files with 1027 additions and 638 deletions

View file

@ -50,7 +50,15 @@ public class AudioManager {
* AudioManager singleton. * AudioManager singleton.
*/ */
private static final AudioManager audioManager = new AudioManager(); private static final AudioManager audioManager = new AudioManager();
private final LinePool linePool = new LinePool(); private LinePool linePool;
public AudioManager() {
try {
linePool = new LinePool();
} catch (Exception e) {
log.warn("Failed to initialize AudioManager. No sounds will be played.", e);
}
}
public static AudioManager getManager() { public static AudioManager getManager() {
return audioManager; return audioManager;
@ -269,35 +277,37 @@ public class AudioManager {
checkAndPlayClip(getManager().playerWon); checkAndPlayClip(getManager().playerWon);
} }
private static boolean audioGroupEnabled(AudioGroup audioGroup) {
switch (audioGroup) {
case GameSounds:
return "true".equals(PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_GAME_ON, "true"));
case DraftSounds:
return "true".equals(PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_DRAFT_ON, "true"));
case SkipSounds:
return "true".equals(PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_SKIP_BUTTONS_ON, "true"));
case OtherSounds:
return "true".equals(PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_OTHER_ON, "true"));
}
return false;
}
private static void checkAndPlayClip(MageClip mageClip) { private static void checkAndPlayClip(MageClip mageClip) {
try { try {
if (mageClip != null) { if (mageClip == null || mageClip.getBuffer() == null) {
boolean playSound = false; return;
switch (mageClip.getAudioGroup()) { }
case GameSounds: if (audioGroupEnabled(mageClip.getAudioGroup())) {
playSound = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_GAME_ON, "true").equals("true"); audioManager.play(mageClip);
break;
case DraftSounds:
playSound = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_DRAFT_ON, "true").equals("true");
break;
case SkipSounds:
playSound = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_SKIP_BUTTONS_ON, "true").equals("true");
break;
case OtherSounds:
playSound = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_SOUNDS_OTHER_ON, "true").equals("true");
}
if (playSound) {
audioManager.play(mageClip);
}
} }
} catch (Exception e) { } catch (Exception e) {
Logger.getLogger(AudioManager.class).fatal("Error while playing sound clip.", e); log.warn("Error while playing sound clip.", e);
} }
} }
public void play(final MageClip mageClip) { public void play(final MageClip mageClip) {
linePool.playSound(mageClip); if (linePool != null) {
linePool.playSound(mageClip);
}
} }
} }

View file

@ -1,7 +1,9 @@
package mage.client.util.audio; package mage.client.util.audio;
import java.util.ArrayDeque;
import java.util.HashSet; import java.util.HashSet;
import java.util.LinkedList; import java.util.LinkedList;
import java.util.Queue;
import java.util.Set; import java.util.Set;
import java.util.Timer; import java.util.Timer;
import java.util.TimerTask; import java.util.TimerTask;
@ -9,9 +11,7 @@ import java.util.TimerTask;
import javax.sound.sampled.AudioFormat; import javax.sound.sampled.AudioFormat;
import javax.sound.sampled.AudioSystem; import javax.sound.sampled.AudioSystem;
import javax.sound.sampled.DataLine; import javax.sound.sampled.DataLine;
import javax.sound.sampled.LineEvent;
import javax.sound.sampled.LineEvent.Type; import javax.sound.sampled.LineEvent.Type;
import javax.sound.sampled.LineListener;
import javax.sound.sampled.LineUnavailableException; import javax.sound.sampled.LineUnavailableException;
import javax.sound.sampled.Mixer; import javax.sound.sampled.Mixer;
import javax.sound.sampled.SourceDataLine; import javax.sound.sampled.SourceDataLine;
@ -25,11 +25,11 @@ public class LinePool {
private final Logger log = LoggerFactory.getLogger(getClass()); private final Logger log = LoggerFactory.getLogger(getClass());
private static final int LINE_CLEANUP_INTERVAL = 30000; private static final int LINE_CLEANUP_INTERVAL = 30000;
AudioFormat format;
Set<SourceDataLine> freeLines = new HashSet<>(); private final Queue<SourceDataLine> freeLines = new ArrayDeque<>();
Set<SourceDataLine> activeLines = new HashSet<>(); private final Queue<SourceDataLine> activeLines = new ArrayDeque<>();
Set<SourceDataLine> busyLines = new HashSet<>(); private final Set<SourceDataLine> busyLines = new HashSet<>();
LinkedList<MageClip> queue = new LinkedList<>(); private final LinkedList<MageClip> queue = new LinkedList<>();
/* /*
* Initially all the lines are in the freeLines pool. When a sound plays, one line is being selected randomly from * Initially all the lines are in the freeLines pool. When a sound plays, one line is being selected randomly from
@ -47,7 +47,6 @@ public class LinePool {
} }
public LinePool(AudioFormat audioFormat, int size, int alwaysActive) { public LinePool(AudioFormat audioFormat, int size, int alwaysActive) {
format = audioFormat;
this.alwaysActive = alwaysActive; this.alwaysActive = alwaysActive;
mixer = AudioSystem.getMixer(null); mixer = AudioSystem.getMixer(null);
DataLine.Info lineInfo = new DataLine.Info(SourceDataLine.class, audioFormat); DataLine.Info lineInfo = new DataLine.Info(SourceDataLine.class, audioFormat);
@ -56,11 +55,10 @@ public class LinePool {
SourceDataLine line = (SourceDataLine) mixer.getLine(lineInfo); SourceDataLine line = (SourceDataLine) mixer.getLine(lineInfo);
freeLines.add(line); freeLines.add(line);
} catch (LineUnavailableException e) { } catch (LineUnavailableException e) {
e.printStackTrace(); log.warn("Failed to get line from mixer", e);
} }
} }
new Timer("Line cleanup", true).scheduleAtFixedRate(new TimerTask() { new Timer("Line cleanup", true).scheduleAtFixedRate(new TimerTask() {
@Override @Override
public void run() { public void run() {
synchronized (LinePool.this) { synchronized (LinePool.this) {
@ -75,74 +73,75 @@ public class LinePool {
}, LINE_CLEANUP_INTERVAL, LINE_CLEANUP_INTERVAL); }, LINE_CLEANUP_INTERVAL, LINE_CLEANUP_INTERVAL);
} }
private synchronized SourceDataLine borrowLine() {
SourceDataLine line = activeLines.poll();
if (line == null) {
line = freeLines.poll();
}
if (line != null) {
busyLines.add(line);
}
return line;
}
private synchronized void returnLine(SourceDataLine line) {
busyLines.remove(line);
if (activeLines.size() < alwaysActive) {
activeLines.add(line);
} else {
freeLines.add(line);
}
}
public void playSound(final MageClip mageClip) { public void playSound(final MageClip mageClip) {
final SourceDataLine line; final SourceDataLine line;
synchronized (LinePool.this) { synchronized (LinePool.this) {
log.debug("Playing {}", mageClip.getFilename()); log.debug("Playing {}", mageClip.getFilename());
logLineStats(); logLineStats();
if (activeLines.size() > 0) { line = borrowLine();
line = activeLines.iterator().next(); if (line == null) {
} else if (freeLines.size() > 0) {
line = freeLines.iterator().next();
} else {
// no lines available, queue sound to play it when a line is available // no lines available, queue sound to play it when a line is available
queue.add(mageClip); queue.add(mageClip);
log.debug("Sound {} queued.", mageClip.getFilename()); log.debug("Sound {} queued.", mageClip.getFilename());
return; return;
} }
freeLines.remove(line);
activeLines.remove(line);
busyLines.add(line);
logLineStats(); logLineStats();
} }
ThreadUtils.threadPool.submit(new Runnable() { ThreadUtils.threadPool.submit(() -> {
synchronized (LinePool.this) {
@Override try {
public void run() { if (!line.isOpen()) {
synchronized (LinePool.this) { line.open();
try { line.addLineListener(event -> {
if (!line.isOpen()) { log.debug("Event: {}", event);
line.open(); if (event.getType() != Type.STOP) {
line.addLineListener(new LineListener() { return;
}
@Override synchronized (LinePool.this) {
public void update(LineEvent event) { log.debug("Before stop on line {}", line);
log.debug("Event: {}", event); logLineStats();
if (event.getType() != Type.STOP) { returnLine(line);
return; log.debug("After stop on line {}", line);
} logLineStats();
synchronized (LinePool.this) { MageClip queuedSound = queue.poll();
log.debug("Before stop on line {}", line); if (queuedSound != null) {
logLineStats(); log.debug("Playing queued sound {}", queuedSound);
busyLines.remove(line); playSound(queuedSound);
if (activeLines.size() < LinePool.this.alwaysActive) {
activeLines.add(line);
} else {
freeLines.add(line);
}
log.debug("After stop on line {}", line);
logLineStats();
if (queue.size() > 0) {
MageClip queuedSound = queue.poll();
log.debug("Playing queued sound {}", queuedSound);
playSound(queuedSound);
}
}
} }
}); }
} });
line.start();
} catch (LineUnavailableException e) {
e.printStackTrace();
} }
line.start();
} catch (LineUnavailableException e) {
log.warn("Failed to open line", e);
} }
byte[] buffer = mageClip.getBuffer();
log.debug("Before write to line {}", line);
line.write(buffer, 0, buffer.length);
line.drain();
line.stop();
log.debug("Line completed: {}", line);
} }
byte[] buffer = mageClip.getBuffer();
log.debug("Before write to line {}", line);
line.write(buffer, 0, buffer.length);
line.drain();
line.stop();
log.debug("Line completed: {}", line);
}); });
} }

View file

@ -28,8 +28,13 @@
package mage.client.util.audio; package mage.client.util.audio;
import org.apache.log4j.Logger;
import java.io.ByteArrayOutputStream;
import java.io.File; import java.io.File;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import javax.sound.sampled.AudioInputStream; import javax.sound.sampled.AudioInputStream;
import javax.sound.sampled.AudioSystem; import javax.sound.sampled.AudioSystem;
@ -40,30 +45,36 @@ import javax.sound.sampled.UnsupportedAudioFileException;
* @author LevelX2 * @author LevelX2
*/ */
public class MageClip { public class MageClip {
private static final Logger log = Logger.getLogger(MageClip.class);
private final AudioGroup audioGroup; private final AudioGroup audioGroup;
private String filename; private final String filename;
private byte buf[]; private final byte buf[];
public MageClip(String filename, AudioGroup audioGroup) { public MageClip(String filename, AudioGroup audioGroup) {
this.filename = filename; this.filename = filename;
this.audioGroup = audioGroup; this.audioGroup = audioGroup;
loadStream(); this.buf = loadStream();
} }
private void loadStream() { private byte[] loadStream() {
File file = new File(filename); File file = new File(filename);
try { try {
AudioInputStream soundIn = AudioSystem.getAudioInputStream(file); AudioInputStream soundIn = AudioSystem.getAudioInputStream(file);
byte tmp[] = new byte[(int) file.length()]; ByteArrayOutputStream bytesOut = new ByteArrayOutputStream();
int read = 0; copy(soundIn, bytesOut);
read = soundIn.read(tmp, 0, tmp.length); return bytesOut.toByteArray();
buf = new byte[read]; } catch (UnsupportedAudioFileException | IOException e) {
System.arraycopy(tmp, 0, buf, 0, read); // truncate the buffer to the actual audio size log.warn("Failed to read " + filename, e);
} catch (UnsupportedAudioFileException e) { return null;
e.printStackTrace(); }
} catch (IOException e) { }
e.printStackTrace();
private static void copy(InputStream source, OutputStream sink) throws IOException {
byte[] buf = new byte[1024];
int n;
while ((n = source.read(buf)) > 0) {
sink.write(buf, 0, n);
} }
} }
@ -71,7 +82,7 @@ public class MageClip {
return audioGroup; return audioGroup;
} }
public byte[] getBuffer(){ public byte[] getBuffer() {
return buf; return buf;
} }

View file

@ -33,6 +33,7 @@ import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import mage.abilities.common.CanBeYourCommanderAbility; import mage.abilities.common.CanBeYourCommanderAbility;
import mage.abilities.keyword.PartnerAbility;
import mage.cards.Card; import mage.cards.Card;
import mage.cards.ExpansionSet; import mage.cards.ExpansionSet;
import mage.cards.Sets; import mage.cards.Sets;
@ -105,9 +106,10 @@ public class Commander extends Constructed {
@Override @Override
public boolean validate(Deck deck) { public boolean validate(Deck deck) {
boolean valid = true; boolean valid = true;
FilterMana colorIdentity = new FilterMana();
if (deck.getCards().size() != 99) { if (deck.getCards().size() + deck.getSideboard().size() != 100) {
invalid.put("Deck", "Must contain 99 cards: has " + deck.getCards().size() + " cards"); invalid.put("Deck", "Must contain 100 cards: has " + (deck.getCards().size() + deck.getSideboard().size()) + " cards");
valid = false; valid = false;
} }
@ -132,34 +134,48 @@ public class Commander extends Constructed {
} }
} }
if (deck.getSideboard().size() == 1) { if (deck.getSideboard().size() < 1 || deck.getSideboard().size() > 2) {
Card commander = (Card) deck.getSideboard().toArray()[0]; invalid.put("Commander", "Sideboard must contain only the commander(s)");
if (commander == null) { valid = false;
invalid.put("Commander", "Commander invalid "); } else {
return false; for (Card commander : deck.getSideboard()) {
} if (bannedCommander.contains(commander.getName())) {
if ((commander.getCardType().contains(CardType.CREATURE) && commander.getSupertype().contains("Legendary"))
|| (commander.getCardType().contains(CardType.PLANESWALKER) && commander.getAbilities().contains(CanBeYourCommanderAbility.getInstance()))) {
if (!bannedCommander.contains(commander.getName())) {
FilterMana color = CardUtil.getColorIdentity(commander);
for (Card card : deck.getCards()) {
if (!cardHasValidColor(color, card)) {
invalid.put(card.getName(), "Invalid color (" + commander.getName() + ")");
valid = false;
}
}
} else {
invalid.put("Commander", "Commander banned (" + commander.getName() + ")"); invalid.put("Commander", "Commander banned (" + commander.getName() + ")");
valid = false; valid = false;
} }
} else { if ((!commander.getCardType().contains(CardType.CREATURE) || !commander.getSupertype().contains("Legendary"))
invalid.put("Commander", "Commander invalid (" + commander.getName() + ")"); && (!commander.getCardType().contains(CardType.PLANESWALKER) || !commander.getAbilities().contains(CanBeYourCommanderAbility.getInstance()))) {
invalid.put("Commander", "Commander invalid (" + commander.getName() + ")");
valid = false;
}
if (deck.getSideboard().size() == 2 && !commander.getAbilities().contains(PartnerAbility.getInstance())) {
invalid.put("Commander", "Commander without Partner (" + commander.getName() + ")");
valid = false;
}
FilterMana commanderColor = CardUtil.getColorIdentity(commander);
if (commanderColor.isWhite()) {
colorIdentity.setWhite(true);
}
if (commanderColor.isBlue()) {
colorIdentity.setBlue(true);
}
if (commanderColor.isBlack()) {
colorIdentity.setBlack(true);
}
if (commanderColor.isRed()) {
colorIdentity.setRed(true);
}
if (commanderColor.isGreen()) {
colorIdentity.setGreen(true);
}
}
}
for (Card card : deck.getCards()) {
if (!cardHasValidColor(colorIdentity, card)) {
invalid.put(card.getName(), "Invalid color (" + colorIdentity.toString() + ")");
valid = false; valid = false;
} }
} else {
invalid.put("Commander", "Sideboard must contain only the commander");
} }
for (Card card : deck.getCards()) { for (Card card : deck.getCards()) {
if (!isSetAllowed(card.getExpansionSetCode())) { if (!isSetAllowed(card.getExpansionSetCode())) {
if (!legalSets(card)) { if (!legalSets(card)) {

View file

@ -0,0 +1,119 @@
/*
* 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.cards.b;
import java.util.UUID;
import mage.MageInt;
import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
import mage.abilities.keyword.DoubleStrikeAbility;
import mage.abilities.keyword.LifelinkAbility;
import mage.abilities.keyword.PartnerAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Duration;
import mage.constants.Zone;
import mage.filter.common.FilterControlledCreaturePermanent;
import mage.game.Game;
import mage.game.events.GameEvent;
import mage.game.events.GameEvent.EventType;
import mage.target.common.TargetControlledCreaturePermanent;
/**
*
* @author spjspj
*/
public class BruseTarlBoorishHerder extends CardImpl {
public BruseTarlBoorishHerder(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{R}{W}");
this.supertype.add("Legendary");
this.subtype.add("Human");
this.subtype.add("Ally");
this.power = new MageInt(3);
this.toughness = new MageInt(3);
// Whenever Bruse Tarl, Boorish Herder enters the battlefield or attacks, target creature you control gains double strike and lifelink until end of turn.
this.addAbility(new BruseTarlAbility());
// Partner
this.addAbility(PartnerAbility.getInstance());
}
public BruseTarlBoorishHerder(final BruseTarlBoorishHerder card) {
super(card);
}
@Override
public BruseTarlBoorishHerder copy() {
return new BruseTarlBoorishHerder(this);
}
}
class BruseTarlAbility extends TriggeredAbilityImpl {
private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("target creature you control");
public BruseTarlAbility() {
super(Zone.BATTLEFIELD, new GainAbilityTargetEffect(DoubleStrikeAbility.getInstance(), Duration.EndOfTurn), false);
addEffect(new GainAbilityTargetEffect(LifelinkAbility.getInstance(), Duration.EndOfTurn));
this.addTarget(new TargetControlledCreaturePermanent(filter));
}
public BruseTarlAbility(final BruseTarlAbility ability) {
super(ability);
}
@Override
public BruseTarlAbility copy() {
return new BruseTarlAbility(this);
}
@Override
public boolean checkEventType(GameEvent event, Game game) {
return event.getType() == EventType.ATTACKER_DECLARED || event.getType() == EventType.ENTERS_THE_BATTLEFIELD;
}
@Override
public boolean checkTrigger(GameEvent event, Game game) {
if (event.getType() == GameEvent.EventType.ATTACKER_DECLARED && event.getSourceId().equals(this.getSourceId())) {
return true;
}
if (event.getType() == GameEvent.EventType.ENTERS_THE_BATTLEFIELD && event.getTargetId().equals(this.getSourceId())) {
return true;
}
return false;
}
@Override
public String getRule() {
return "Whenever {this} enters the battlefield or attacks, target creature you control gains double strike and lifelink until end of turn";
}
}

View file

@ -27,6 +27,8 @@
*/ */
package mage.cards.c; package mage.cards.c;
import java.util.ArrayList;
import java.util.List;
import java.util.UUID; import java.util.UUID;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleActivatedAbility;
@ -71,28 +73,44 @@ public class CommandBeacon extends CardImpl {
} }
class CommandBeaconEffect extends OneShotEffect { class CommandBeaconEffect extends OneShotEffect {
CommandBeaconEffect() { CommandBeaconEffect() {
super(Outcome.ReturnToHand); super(Outcome.ReturnToHand);
this.staticText = "Put your commander into your hand from the command zone"; this.staticText = "Put your commander into your hand from the command zone";
} }
CommandBeaconEffect(final CommandBeaconEffect effect) { CommandBeaconEffect(final CommandBeaconEffect effect) {
super(effect); super(effect);
} }
@Override @Override
public CommandBeaconEffect copy() { public CommandBeaconEffect copy() {
return new CommandBeaconEffect(this); return new CommandBeaconEffect(this);
} }
@Override @Override
public boolean apply(Game game, Ability source) { public boolean apply(Game game, Ability source) {
Player controller = game.getPlayer(source.getControllerId()); Player controller = game.getPlayer(source.getControllerId());
if (controller != null) { if (controller != null) {
Card commander = game.getCard(controller.getCommanderId()); List<Card> commandersInCommandZone = new ArrayList<>(1);
if (commander != null && game.getState().getZone(commander.getId()) == Zone.COMMAND) { for (UUID commanderId : controller.getCommandersIds()) {
controller.moveCards(commander, Zone.HAND, source, game); Card commander = game.getCard(commanderId);
if (commander != null && game.getState().getZone(commander.getId()) == Zone.COMMAND) {
commandersInCommandZone.add(commander);
}
}
if (commandersInCommandZone.size() == 1) {
controller.moveCards(commandersInCommandZone.get(0), Zone.HAND, source, game);
}
else if (commandersInCommandZone.size() == 2) {
Card firstCommander = commandersInCommandZone.get(0);
Card secondCommander = commandersInCommandZone.get(1);
if (controller.chooseUse(Outcome.ReturnToHand, "Return which commander to hand?", null, firstCommander.getName(), secondCommander.getName(), source, game)) {
controller.moveCards(firstCommander, Zone.HAND, source, game);
}
else {
controller.moveCards(secondCommander, Zone.HAND, source, game);
}
} }
return true; return true;
} }

View file

@ -28,7 +28,6 @@
package mage.cards.c; package mage.cards.c;
import java.util.UUID; import java.util.UUID;
import mage.ObjectColor;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.OneShotEffect;
import mage.cards.CardImpl; import mage.cards.CardImpl;
@ -69,8 +68,6 @@ public class ConsignToDream extends CardImpl {
class ConsignToDreamEffect extends OneShotEffect { class ConsignToDreamEffect extends OneShotEffect {
boolean applied = false;
public ConsignToDreamEffect() { public ConsignToDreamEffect() {
super(Outcome.ReturnToHand); super(Outcome.ReturnToHand);
this.staticText = "Return target permanent to its owner's hand. If that permanent is red or green, put it on top of its owner's library instead"; this.staticText = "Return target permanent to its owner's hand. If that permanent is red or green, put it on top of its owner's library instead";
@ -87,10 +84,10 @@ class ConsignToDreamEffect extends OneShotEffect {
@Override @Override
public boolean apply(Game game, Ability source) { public boolean apply(Game game, Ability source) {
boolean applied = false;
Permanent target = game.getPermanent(source.getFirstTarget()); Permanent target = game.getPermanent(source.getFirstTarget());
if (target != null) { if (target != null) {
if (target.getColor(game).contains(ObjectColor.RED) if (target.getColor(game).isRed() || target.getColor(game).isGreen()) {
|| target.getColor(game).contains(ObjectColor.GREEN)) {
applied = target.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); applied = target.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true);
} else { } else {
applied = target.moveToZone(Zone.HAND, source.getSourceId(), game, false); applied = target.moveToZone(Zone.HAND, source.getSourceId(), game, false);

View file

@ -127,17 +127,19 @@ class ConspiracyEffect extends ContinuousEffectImpl {
} }
} }
// commander in command zone // commander in command zone
if (controller.getCommanderId() != null && game.getState().getZone(controller.getCommanderId()).equals(Zone.COMMAND)) { for (UUID commanderId : controller.getCommandersIds()) {
Card card = game.getCard(controller.getCommanderId()); if (game.getState().getZone(commanderId).equals(Zone.COMMAND)) {
if (card.getCardType().contains(CardType.CREATURE)) { Card card = game.getCard(commanderId);
setCreatureSubtype(card, choice, game); if (card.getCardType().contains(CardType.CREATURE)) {
setCreatureSubtype(card, choice, game);
}
} }
} }
// creature spells you control // creature spells you control
for (Iterator<StackObject> iterator = game.getStack().iterator(); iterator.hasNext();) { for (Iterator<StackObject> iterator = game.getStack().iterator(); iterator.hasNext();) {
StackObject stackObject = iterator.next(); StackObject stackObject = iterator.next();
if (stackObject instanceof Spell && if (stackObject instanceof Spell &&
stackObject.getControllerId().equals(source.getControllerId()) && stackObject.getControllerId().equals(source.getControllerId()) &&
stackObject.getCardType().contains(CardType.CREATURE)) { stackObject.getCardType().contains(CardType.CREATURE)) {
Card card = ((Spell) stackObject).getCard(); Card card = ((Spell) stackObject).getCard();
setCreatureSubtype(card, choice, game); setCreatureSubtype(card, choice, game);
@ -153,20 +155,20 @@ class ConspiracyEffect extends ContinuousEffectImpl {
} }
return false; return false;
} }
private void setCreatureSubtype(MageObject object, String subtype, Game game) { private void setCreatureSubtype(MageObject object, String subtype, Game game) {
if (object != null) { if (object != null) {
if (object instanceof Card) { if (object instanceof Card) {
Card card = (Card) object; Card card = (Card) object;
setChosenSubtype( setChosenSubtype(
game.getState().getCreateCardAttribute(card).getSubtype(), game.getState().getCreateCardAttribute(card).getSubtype(),
subtype); subtype);
} else { } else {
setChosenSubtype(object.getSubtype(game), subtype); setChosenSubtype(object.getSubtype(game), subtype);
} }
} }
} }
private void setChosenSubtype(List<String> subtype, String choice) { private void setChosenSubtype(List<String> subtype, String choice) {
if (subtype.size() != 1 || !subtype.contains(choice)) { if (subtype.size() != 1 || !subtype.contains(choice)) {
subtype.removeAll(CardRepository.instance.getCreatureTypes()); subtype.removeAll(CardRepository.instance.getCreatureTypes());

View file

@ -28,7 +28,6 @@
package mage.cards.c; package mage.cards.c;
import java.util.UUID; import java.util.UUID;
import mage.ObjectColor;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DoIfCostPaid; import mage.abilities.effects.common.DoIfCostPaid;
@ -89,7 +88,7 @@ class CrystalRodAbility extends TriggeredAbilityImpl {
@Override @Override
public boolean checkTrigger(GameEvent event, Game game) { public boolean checkTrigger(GameEvent event, Game game) {
Spell spell = game.getStack().getSpell(event.getTargetId()); Spell spell = game.getStack().getSpell(event.getTargetId());
return spell != null && spell.getColor(game).contains(ObjectColor.BLUE); return spell != null && spell.getColor(game).isBlue();
} }
@Override @Override

View file

@ -29,7 +29,6 @@ package mage.cards.f;
import java.util.UUID; import java.util.UUID;
import mage.MageInt; import mage.MageInt;
import mage.ObjectColor;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.abilities.effects.ContinuousRuleModifyingEffectImpl;
@ -122,8 +121,7 @@ class FiendslayerPaladinEffect extends ContinuousRuleModifyingEffectImpl {
Card targetCard = game.getCard(event.getTargetId()); Card targetCard = game.getCard(event.getTargetId());
StackObject stackObject = (StackObject) game.getStack().getStackObject(event.getSourceId()); StackObject stackObject = (StackObject) game.getStack().getStackObject(event.getSourceId());
if (targetCard != null && stackObject != null && targetCard.getId().equals(source.getSourceId())) { if (targetCard != null && stackObject != null && targetCard.getId().equals(source.getSourceId())) {
if (stackObject.getColor(game).contains(ObjectColor.BLACK) if (stackObject.getColor(game).isBlack() || stackObject.getColor(game).isRed()) {
|| stackObject.getColor(game).contains(ObjectColor.RED)) {
if (!stackObject.getControllerId().equals(source.getControllerId()) if (!stackObject.getControllerId().equals(source.getControllerId())
&& stackObject.getCardType().contains(CardType.INSTANT) && stackObject.getCardType().contains(CardType.INSTANT)
|| stackObject.getCardType().contains(CardType.SORCERY)) { || stackObject.getCardType().contains(CardType.SORCERY)) {

View file

@ -0,0 +1,131 @@
/*
* 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.cards.g;
import java.util.UUID;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.BeginningOfEndStepTriggeredAbility;
import mage.abilities.common.SimpleStaticAbility;
import mage.abilities.effects.Effect;
import mage.abilities.effects.OneShotEffect;
import mage.abilities.effects.common.combat.AttacksIfAbleAllEffect;
import mage.abilities.keyword.FirstStrikeAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Duration;
import mage.constants.Outcome;
import mage.constants.TargetController;
import mage.constants.Zone;
import mage.filter.common.FilterCreaturePermanent;
import mage.filter.predicate.permanent.ControllerPredicate;
import mage.game.Game;
import mage.game.permanent.token.Token;
import mage.players.Player;
/**
*
* @author spjspj
*/
public class GoblinSpymaster extends CardImpl {
public GoblinSpymaster(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{R}");
this.subtype.add("Goblin");
this.subtype.add("Rogue");
this.power = new MageInt(2);
this.toughness = new MageInt(1);
// First strike
this.addAbility(FirstStrikeAbility.getInstance());
// At the beginning of each opponent's end step, that player creates a 1/1 red Goblin creature token with "Creatures you control attack each combat if able."
this.addAbility(new BeginningOfEndStepTriggeredAbility(Zone.BATTLEFIELD, new SpyMasterGoblinCreateTokenEffect(), TargetController.OPPONENT, null, false));
}
public GoblinSpymaster(final GoblinSpymaster card) {
super(card);
}
@Override
public GoblinSpymaster copy() {
return new GoblinSpymaster(this);
}
}
class SpyMasterGoblinCreateTokenEffect extends OneShotEffect {
public SpyMasterGoblinCreateTokenEffect() {
super(Outcome.Detriment);
this.staticText = "that player creates a 1/1 red Goblin creature token with \"Creatures you control attack each combat if able.\"";
}
public SpyMasterGoblinCreateTokenEffect(final SpyMasterGoblinCreateTokenEffect effect) {
super(effect);
}
@Override
public SpyMasterGoblinCreateTokenEffect copy() {
return new SpyMasterGoblinCreateTokenEffect(this);
}
@Override
public boolean apply(Game game, Ability source) {
Player player = game.getPlayer(game.getActivePlayerId());
if (player != null) {
Token token = new SpyMasterGoblinToken();
token.putOntoBattlefield(1, game, source.getSourceId(), player.getId());
}
return true;
}
}
class SpyMasterGoblinToken extends Token {
private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Creatures you control");
static {
filter.add(new ControllerPredicate(TargetController.YOU));
}
SpyMasterGoblinToken() {
super("Goblin", "1/1 red Goblin creature token with \"Creatures you control attack each combat if able.\"");
cardType.add(CardType.CREATURE);
color.setRed(true);
subtype.add("Goblin");
power = new MageInt(1);
toughness = new MageInt(1);
Effect effect = new AttacksIfAbleAllEffect(filter, Duration.WhileOnBattlefield, true);
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect));
}
}

View file

@ -28,7 +28,6 @@
package mage.cards.i; package mage.cards.i;
import java.util.UUID; import java.util.UUID;
import mage.ObjectColor;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.OneShotEffect;
import mage.abilities.effects.common.PreventAllDamageByAllPermanentsEffect; import mage.abilities.effects.common.PreventAllDamageByAllPermanentsEffect;
@ -95,8 +94,7 @@ class InquisitorsSnareEffect extends OneShotEffect {
FilterCreaturePermanent filter = new FilterCreaturePermanent(); FilterCreaturePermanent filter = new FilterCreaturePermanent();
filter.add(new PermanentIdPredicate(targetCreature.getId())); filter.add(new PermanentIdPredicate(targetCreature.getId()));
game.addEffect(new PreventAllDamageByAllPermanentsEffect(filter, Duration.EndOfTurn, false), source); game.addEffect(new PreventAllDamageByAllPermanentsEffect(filter, Duration.EndOfTurn, false), source);
if (targetCreature.getColor(game).contains(ObjectColor.BLACK) if (targetCreature.getColor(game).isBlack() || targetCreature.getColor(game).isRed()) {
|| targetCreature.getColor(game).contains(ObjectColor.RED)) {
return targetCreature.destroy(source.getSourceId(), game, false); return targetCreature.destroy(source.getSourceId(), game, false);
} }
} }

View file

@ -28,7 +28,6 @@
package mage.cards.i; package mage.cards.i;
import java.util.UUID; import java.util.UUID;
import mage.ObjectColor;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DoIfCostPaid; import mage.abilities.effects.common.DoIfCostPaid;
@ -45,7 +44,6 @@ import mage.game.stack.Spell;
/** /**
* *
* @author KholdFuzion * @author KholdFuzion
*/ */
public class IronStar extends CardImpl { public class IronStar extends CardImpl {
@ -89,7 +87,7 @@ class IronStarAbility extends TriggeredAbilityImpl {
@Override @Override
public boolean checkTrigger(GameEvent event, Game game) { public boolean checkTrigger(GameEvent event, Game game) {
Spell spell = game.getStack().getSpell(event.getTargetId()); Spell spell = game.getStack().getSpell(event.getTargetId());
return spell != null && spell.getColor(game).contains(ObjectColor.RED); return spell != null && spell.getColor(game).isRed();
} }
@Override @Override

View file

@ -88,7 +88,7 @@ class IvoryCupAbility extends TriggeredAbilityImpl {
@Override @Override
public boolean checkTrigger(GameEvent event, Game game) { public boolean checkTrigger(GameEvent event, Game game) {
Spell spell = game.getStack().getSpell(event.getTargetId()); Spell spell = game.getStack().getSpell(event.getTargetId());
return spell != null && spell.getColor(game).contains(ObjectColor.WHITE); return spell != null && spell.getColor(game).isWhite();
} }
@Override @Override

View file

@ -140,7 +140,7 @@ class KarnLiberatedEffect extends OneShotEffect {
if (card.getOwnerId().equals(player.getId()) && !card.isCopy() // no copies if (card.getOwnerId().equals(player.getId()) && !card.isCopy() // no copies
&& !player.getSideboard().contains(card.getId()) && !player.getSideboard().contains(card.getId())
&& !cards.contains(card)) { // not the exiled cards && !cards.contains(card)) { // not the exiled cards
if (card.getId().equals(player.getCommanderId())) { if (player.getCommandersIds().contains(card.getId())) {
game.addCommander(new Commander(card)); game.addCommander(new Commander(card));
game.setZone(card.getId(), Zone.COMMAND); game.setZone(card.getId(), Zone.COMMAND);
} else { } else {

View file

@ -119,7 +119,7 @@ class OpalPalaceWatcher extends Watcher {
for (UUID playerId : game.getPlayerList()) { for (UUID playerId : game.getPlayerList()) {
Player player = game.getPlayer(playerId); Player player = game.getPlayer(playerId);
if (player != null) { if (player != null) {
if (player.getCommanderId() != null && player.getCommanderId().equals(card.getId())) { if (player.getCommandersIds().contains(card.getId())) {
commanderId.add(card.getId()); commanderId.add(card.getId());
break; break;
} }

View file

@ -131,10 +131,12 @@ class TeferiMageOfZhalfirAddFlashEffect extends ContinuousEffectImpl {
} }
} }
// commander in command zone // commander in command zone
if (controller.getCommanderId() != null && game.getState().getZone(controller.getCommanderId()).equals(Zone.COMMAND)) { for (UUID commanderId : controller.getCommandersIds()) {
Card card = game.getCard(controller.getCommanderId()); if (game.getState().getZone(commanderId).equals(Zone.COMMAND)) {
if (card.getCardType().contains(CardType.CREATURE)) { Card card = game.getCard(commanderId);
game.getState().addOtherAbility(card, FlashAbility.getInstance()); if (card.getCardType().contains(CardType.CREATURE)) {
game.getState().addOtherAbility(card, FlashAbility.getInstance());
}
} }
} }
return true; return true;

View file

@ -28,7 +28,6 @@
package mage.cards.t; package mage.cards.t;
import java.util.UUID; import java.util.UUID;
import mage.ObjectColor;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DoIfCostPaid; import mage.abilities.effects.common.DoIfCostPaid;
@ -89,7 +88,7 @@ class ThroneOfBoneAbility extends TriggeredAbilityImpl {
@Override @Override
public boolean checkTrigger(GameEvent event, Game game) { public boolean checkTrigger(GameEvent event, Game game) {
Spell spell = game.getStack().getSpell(event.getTargetId()); Spell spell = game.getStack().getSpell(event.getTargetId());
return spell != null && spell.getColor(game).contains(ObjectColor.BLACK); return spell != null && spell.getColor(game).isBlack();
} }
@Override @Override

View file

@ -0,0 +1,106 @@
/*
* 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.cards.t;
import java.util.List;
import java.util.UUID;
import mage.abilities.Ability;
import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.OneShotEffect;
import mage.abilities.keyword.BasicLandcyclingAbility;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.Outcome;
import mage.filter.common.FilterLandPermanent;
import mage.game.Game;
import mage.game.permanent.Permanent;
import mage.players.Player;
/**
*
* @author Styxo
*/
public class TreacherousTerrain extends CardImpl {
public TreacherousTerrain(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{6}{R}{G}");
// Treacherous Terrain deals damage to each opponent requal to the number of lands that player controls.
this.getSpellAbility().addEffect(new TreacherousTerrainEffect());
// Basic landcycling {2}
this.addAbility(new BasicLandcyclingAbility(new ManaCostsImpl("{2}")));
}
public TreacherousTerrain(final TreacherousTerrain card) {
super(card);
}
@Override
public TreacherousTerrain copy() {
return new TreacherousTerrain(this);
}
}
class TreacherousTerrainEffect extends OneShotEffect {
public TreacherousTerrainEffect() {
super(Outcome.Damage);
staticText = "{this} deals damage to each opponent equal to the number of lands that player controls";
}
public TreacherousTerrainEffect(final TreacherousTerrainEffect effect) {
super(effect);
}
@Override
public boolean apply(Game game, Ability source) {
List<Permanent> permanents = game.getBattlefield().getActivePermanents(new FilterLandPermanent(), source.getControllerId(), source.getSourceId(), game);
for (UUID playerId : game.getOpponents(source.getControllerId())) {
Player player = game.getPlayer(playerId);
if (player != null) {
int amount = 0;
for (Permanent permanent : permanents) {
if (permanent.getControllerId().equals(playerId)) {
amount++;
}
}
if (amount > 0) {
player.damage(amount, source.getSourceId(), game, false, true);
}
}
}
return true;
}
@Override
public TreacherousTerrainEffect copy() {
return new TreacherousTerrainEffect(this);
}
}

View file

@ -28,7 +28,6 @@
package mage.cards.w; package mage.cards.w;
import java.util.UUID; import java.util.UUID;
import mage.ObjectColor;
import mage.abilities.TriggeredAbilityImpl; import mage.abilities.TriggeredAbilityImpl;
import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.costs.mana.GenericManaCost;
import mage.abilities.effects.common.DoIfCostPaid; import mage.abilities.effects.common.DoIfCostPaid;
@ -89,7 +88,7 @@ class WoodenSphereAbility extends TriggeredAbilityImpl {
@Override @Override
public boolean checkTrigger(GameEvent event, Game game) { public boolean checkTrigger(GameEvent event, Game game) {
Spell spell = game.getStack().getSpell(event.getTargetId()); Spell spell = game.getStack().getSpell(event.getTargetId());
return spell != null && spell.getColor(game).contains(ObjectColor.GREEN); return spell != null && spell.getColor(game).isGreen();
} }
@Override @Override

View file

@ -1,373 +1,376 @@
/* /*
* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved.
* *
* Redistribution and use in source and binary forms, with or without modification, are * Redistribution and use in source and binary forms, with or without modification, are
* permitted provided that the following conditions are met: * permitted provided that the following conditions are met:
* *
* 1. Redistributions of source code must retain the above copyright notice, this list of * 1. Redistributions of source code must retain the above copyright notice, this list of
* conditions and the following disclaimer. * conditions and the following disclaimer.
* *
* 2. Redistributions in binary form must reproduce the above copyright notice, this list * 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 * of conditions and the following disclaimer in the documentation and/or other materials
* provided with the distribution. * provided with the distribution.
* *
* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * 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 * 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 * 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 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 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 * 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 * 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 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
* *
* The views and conclusions contained in the software and documentation are those of the * 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 * 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; package mage.sets;
import mage.cards.CardGraphicInfo; import mage.cards.CardGraphicInfo;
import mage.cards.ExpansionSet; import mage.cards.ExpansionSet;
import mage.constants.Rarity; import mage.constants.Rarity;
import mage.constants.SetType; import mage.constants.SetType;
/** /**
* *
* @author fireshoes * @author fireshoes
*/ */
public class Commander2016 extends ExpansionSet { public class Commander2016 extends ExpansionSet {
private static final Commander2016 fINSTANCE = new Commander2016(); private static final Commander2016 fINSTANCE = new Commander2016();
public static Commander2016 getInstance() { public static Commander2016 getInstance() {
return fINSTANCE; return fINSTANCE;
} }
private Commander2016() { private Commander2016() {
super("Commander 2016 Edition", "C16", ExpansionSet.buildDate(2016, 11, 11), SetType.SUPPLEMENTAL); super("Commander 2016 Edition", "C16", ExpansionSet.buildDate(2016, 11, 11), SetType.SUPPLEMENTAL);
this.blockName = "Command Zone"; this.blockName = "Command Zone";
cards.add(new SetCardInfo("Abzan Charm", 177, Rarity.UNCOMMON, mage.cards.a.AbzanCharm.class)); cards.add(new SetCardInfo("Abzan Charm", 177, Rarity.UNCOMMON, mage.cards.a.AbzanCharm.class));
cards.add(new SetCardInfo("Abzan Falconer", 57, Rarity.UNCOMMON, mage.cards.a.AbzanFalconer.class)); cards.add(new SetCardInfo("Abzan Falconer", 57, Rarity.UNCOMMON, mage.cards.a.AbzanFalconer.class));
cards.add(new SetCardInfo("Academy Elite", 81, Rarity.RARE, mage.cards.a.AcademyElite.class)); cards.add(new SetCardInfo("Academy Elite", 81, Rarity.RARE, mage.cards.a.AcademyElite.class));
cards.add(new SetCardInfo("Aeon Chronicler", 82, Rarity.RARE, mage.cards.a.AeonChronicler.class)); cards.add(new SetCardInfo("Aeon Chronicler", 82, Rarity.RARE, mage.cards.a.AeonChronicler.class));
cards.add(new SetCardInfo("Akiri, Line-Slinger", 26, Rarity.RARE, mage.cards.a.AkiriLineSlinger.class)); cards.add(new SetCardInfo("Akiri, Line-Slinger", 26, Rarity.RARE, mage.cards.a.AkiriLineSlinger.class));
cards.add(new SetCardInfo("Akroan Horse", 241, Rarity.RARE, mage.cards.a.AkroanHorse.class)); cards.add(new SetCardInfo("Akroan Horse", 241, Rarity.RARE, mage.cards.a.AkroanHorse.class));
cards.add(new SetCardInfo("Alesha, Who Smiles at Death", 119, Rarity.RARE, mage.cards.a.AleshaWhoSmilesAtDeath.class)); cards.add(new SetCardInfo("Alesha, Who Smiles at Death", 119, Rarity.RARE, mage.cards.a.AleshaWhoSmilesAtDeath.class));
cards.add(new SetCardInfo("Ancient Excavation", 27, Rarity.UNCOMMON, mage.cards.a.AncientExcavation.class)); cards.add(new SetCardInfo("Ancient Excavation", 27, Rarity.UNCOMMON, mage.cards.a.AncientExcavation.class));
cards.add(new SetCardInfo("Ankle Shanker", 178, Rarity.RARE, mage.cards.a.AnkleShanker.class)); cards.add(new SetCardInfo("Ankle Shanker", 178, Rarity.RARE, mage.cards.a.AnkleShanker.class));
cards.add(new SetCardInfo("Arcane Denial", 83, Rarity.COMMON, mage.cards.a.ArcaneDenial.class)); cards.add(new SetCardInfo("Arcane Denial", 83, Rarity.COMMON, mage.cards.a.ArcaneDenial.class));
cards.add(new SetCardInfo("Arcane Sanctum", 281, Rarity.UNCOMMON, mage.cards.a.ArcaneSanctum.class)); cards.add(new SetCardInfo("Arcane Sanctum", 281, Rarity.UNCOMMON, mage.cards.a.ArcaneSanctum.class));
cards.add(new SetCardInfo("Armory Automaton", 51, Rarity.RARE, mage.cards.a.ArmoryAutomaton.class)); cards.add(new SetCardInfo("Armory Automaton", 51, Rarity.RARE, mage.cards.a.ArmoryAutomaton.class));
cards.add(new SetCardInfo("Army of the Damned", 105, Rarity.MYTHIC, mage.cards.a.ArmyOfTheDamned.class)); cards.add(new SetCardInfo("Army of the Damned", 105, Rarity.MYTHIC, mage.cards.a.ArmyOfTheDamned.class));
cards.add(new SetCardInfo("Artifact Mutation", 179, Rarity.RARE, mage.cards.a.ArtifactMutation.class)); cards.add(new SetCardInfo("Artifact Mutation", 179, Rarity.RARE, mage.cards.a.ArtifactMutation.class));
cards.add(new SetCardInfo("Ash Barrens", 56, Rarity.COMMON, mage.cards.a.AshBarrens.class)); cards.add(new SetCardInfo("Ash Barrens", 56, Rarity.COMMON, mage.cards.a.AshBarrens.class));
cards.add(new SetCardInfo("Assault Suit", 242, Rarity.UNCOMMON, mage.cards.a.AssaultSuit.class)); cards.add(new SetCardInfo("Assault Suit", 242, Rarity.UNCOMMON, mage.cards.a.AssaultSuit.class));
cards.add(new SetCardInfo("Astral Cornucopia", 243, Rarity.RARE, mage.cards.a.AstralCornucopia.class)); cards.add(new SetCardInfo("Astral Cornucopia", 243, Rarity.RARE, mage.cards.a.AstralCornucopia.class));
cards.add(new SetCardInfo("Atraxa, Praetors' Voice", 28, Rarity.MYTHIC, mage.cards.a.AtraxaPraetorsVoice.class)); cards.add(new SetCardInfo("Atraxa, Praetors' Voice", 28, Rarity.MYTHIC, mage.cards.a.AtraxaPraetorsVoice.class));
cards.add(new SetCardInfo("Aura Mutation", 180, Rarity.RARE, mage.cards.a.AuraMutation.class)); cards.add(new SetCardInfo("Aura Mutation", 180, Rarity.RARE, mage.cards.a.AuraMutation.class));
cards.add(new SetCardInfo("Azorius Chancery", 282, Rarity.UNCOMMON, mage.cards.a.AzoriusChancery.class)); cards.add(new SetCardInfo("Azorius Chancery", 282, Rarity.UNCOMMON, mage.cards.a.AzoriusChancery.class));
cards.add(new SetCardInfo("Baleful Strix", 181, Rarity.UNCOMMON, mage.cards.b.BalefulStrix.class)); cards.add(new SetCardInfo("Baleful Strix", 181, Rarity.UNCOMMON, mage.cards.b.BalefulStrix.class));
cards.add(new SetCardInfo("Bane of the Living", 106, Rarity.RARE, mage.cards.b.BaneOfTheLiving.class)); cards.add(new SetCardInfo("Bane of the Living", 106, Rarity.RARE, mage.cards.b.BaneOfTheLiving.class));
cards.add(new SetCardInfo("Beacon of Unrest", 107, Rarity.RARE, mage.cards.b.BeaconOfUnrest.class)); cards.add(new SetCardInfo("Beacon of Unrest", 107, Rarity.RARE, mage.cards.b.BeaconOfUnrest.class));
cards.add(new SetCardInfo("Beast Within", 141, Rarity.UNCOMMON, mage.cards.b.BeastWithin.class)); cards.add(new SetCardInfo("Beast Within", 141, Rarity.UNCOMMON, mage.cards.b.BeastWithin.class));
cards.add(new SetCardInfo("Beastmaster Ascension", 142, Rarity.RARE, mage.cards.b.BeastmasterAscension.class)); cards.add(new SetCardInfo("Beastmaster Ascension", 142, Rarity.RARE, mage.cards.b.BeastmasterAscension.class));
cards.add(new SetCardInfo("Bituminous Blast", 182, Rarity.UNCOMMON, mage.cards.b.BituminousBlast.class)); cards.add(new SetCardInfo("Bituminous Blast", 182, Rarity.UNCOMMON, mage.cards.b.BituminousBlast.class));
cards.add(new SetCardInfo("Blasphemous Act", 120, Rarity.RARE, mage.cards.b.BlasphemousAct.class)); cards.add(new SetCardInfo("Blasphemous Act", 120, Rarity.RARE, mage.cards.b.BlasphemousAct.class));
cards.add(new SetCardInfo("Blazing Archon", 58, Rarity.RARE, mage.cards.b.BlazingArchon.class)); cards.add(new SetCardInfo("Blazing Archon", 58, Rarity.RARE, mage.cards.b.BlazingArchon.class));
cards.add(new SetCardInfo("Blind Obedience", 59, Rarity.RARE, mage.cards.b.BlindObedience.class)); cards.add(new SetCardInfo("Blind Obedience", 59, Rarity.RARE, mage.cards.b.BlindObedience.class));
cards.add(new SetCardInfo("Blinkmoth Urn", 244, Rarity.RARE, mage.cards.b.BlinkmothUrn.class)); cards.add(new SetCardInfo("Blinkmoth Urn", 244, Rarity.RARE, mage.cards.b.BlinkmothUrn.class));
cards.add(new SetCardInfo("Blood Tyrant", 183, Rarity.RARE, mage.cards.b.BloodTyrant.class)); cards.add(new SetCardInfo("Blood Tyrant", 183, Rarity.RARE, mage.cards.b.BloodTyrant.class));
cards.add(new SetCardInfo("Bloodbraid Elf", 184, Rarity.UNCOMMON, mage.cards.b.BloodbraidElf.class)); cards.add(new SetCardInfo("Bloodbraid Elf", 184, Rarity.UNCOMMON, mage.cards.b.BloodbraidElf.class));
cards.add(new SetCardInfo("Bonehoard", 245, Rarity.RARE, mage.cards.b.Bonehoard.class)); cards.add(new SetCardInfo("Bonehoard", 245, Rarity.RARE, mage.cards.b.Bonehoard.class));
cards.add(new SetCardInfo("Boompile", 52, Rarity.RARE, mage.cards.b.Boompile.class)); cards.add(new SetCardInfo("Boompile", 52, Rarity.RARE, mage.cards.b.Boompile.class));
cards.add(new SetCardInfo("Boros Charm", 185, Rarity.UNCOMMON, mage.cards.b.BorosCharm.class)); cards.add(new SetCardInfo("Boros Charm", 185, Rarity.UNCOMMON, mage.cards.b.BorosCharm.class));
cards.add(new SetCardInfo("Boros Garrison", 283, Rarity.UNCOMMON, mage.cards.b.BorosGarrison.class)); cards.add(new SetCardInfo("Boros Garrison", 283, Rarity.UNCOMMON, mage.cards.b.BorosGarrison.class));
cards.add(new SetCardInfo("Brave the Sands", 60, Rarity.UNCOMMON, mage.cards.b.BraveTheSands.class)); cards.add(new SetCardInfo("Brave the Sands", 60, Rarity.UNCOMMON, mage.cards.b.BraveTheSands.class));
cards.add(new SetCardInfo("Breath of Fury", 121, Rarity.RARE, mage.cards.b.BreathOfFury.class)); cards.add(new SetCardInfo("Breath of Fury", 121, Rarity.RARE, mage.cards.b.BreathOfFury.class));
cards.add(new SetCardInfo("Bred for the Hunt", 186, Rarity.UNCOMMON, mage.cards.b.BredForTheHunt.class)); cards.add(new SetCardInfo("Bred for the Hunt", 186, Rarity.UNCOMMON, mage.cards.b.BredForTheHunt.class));
cards.add(new SetCardInfo("Breya, Etherium Shaper", 29, Rarity.MYTHIC, mage.cards.b.BreyaEtheriumShaper.class)); cards.add(new SetCardInfo("Breya, Etherium Shaper", 29, Rarity.MYTHIC, mage.cards.b.BreyaEtheriumShaper.class));
cards.add(new SetCardInfo("Brutal Hordechief", 108, Rarity.MYTHIC, mage.cards.b.BrutalHordechief.class)); cards.add(new SetCardInfo("Bruse Tarl, Boorish Herder", 30, Rarity.MYTHIC, mage.cards.b.BruseTarlBoorishHerder.class));
cards.add(new SetCardInfo("Burgeoning", 143, Rarity.RARE, mage.cards.b.Burgeoning.class)); cards.add(new SetCardInfo("Brutal Hordechief", 108, Rarity.MYTHIC, mage.cards.b.BrutalHordechief.class));
cards.add(new SetCardInfo("Buried Ruin", 284, Rarity.UNCOMMON, mage.cards.b.BuriedRuin.class)); cards.add(new SetCardInfo("Burgeoning", 143, Rarity.RARE, mage.cards.b.Burgeoning.class));
cards.add(new SetCardInfo("Cauldron of Souls", 246, Rarity.RARE, mage.cards.c.CauldronOfSouls.class)); cards.add(new SetCardInfo("Buried Ruin", 284, Rarity.UNCOMMON, mage.cards.b.BuriedRuin.class));
cards.add(new SetCardInfo("Cathars' Crusade", 61, Rarity.RARE, mage.cards.c.CatharsCrusade.class)); cards.add(new SetCardInfo("Cauldron of Souls", 246, Rarity.RARE, mage.cards.c.CauldronOfSouls.class));
cards.add(new SetCardInfo("Caves of Koilos", 285, Rarity.RARE, mage.cards.c.CavesOfKoilos.class)); cards.add(new SetCardInfo("Cathars' Crusade", 61, Rarity.RARE, mage.cards.c.CatharsCrusade.class));
cards.add(new SetCardInfo("Chain of Vapor", 84, Rarity.UNCOMMON, mage.cards.c.ChainOfVapor.class)); cards.add(new SetCardInfo("Caves of Koilos", 285, Rarity.RARE, mage.cards.c.CavesOfKoilos.class));
cards.add(new SetCardInfo("Champion of Lambholt", 144, Rarity.RARE, mage.cards.c.ChampionOfLambholt.class)); cards.add(new SetCardInfo("Chain of Vapor", 84, Rarity.UNCOMMON, mage.cards.c.ChainOfVapor.class));
cards.add(new SetCardInfo("Chaos Warp", 122, Rarity.RARE, mage.cards.c.ChaosWarp.class)); cards.add(new SetCardInfo("Champion of Lambholt", 144, Rarity.RARE, mage.cards.c.ChampionOfLambholt.class));
cards.add(new SetCardInfo("Chasm Skulker", 85, Rarity.RARE, mage.cards.c.ChasmSkulker.class)); cards.add(new SetCardInfo("Chaos Warp", 122, Rarity.RARE, mage.cards.c.ChaosWarp.class));
cards.add(new SetCardInfo("Chief Engineer", 86, Rarity.RARE, mage.cards.c.ChiefEngineer.class)); cards.add(new SetCardInfo("Chasm Skulker", 85, Rarity.RARE, mage.cards.c.ChasmSkulker.class));
cards.add(new SetCardInfo("Chromatic Lantern", 247, Rarity.RARE, mage.cards.c.ChromaticLantern.class)); cards.add(new SetCardInfo("Chief Engineer", 86, Rarity.RARE, mage.cards.c.ChiefEngineer.class));
cards.add(new SetCardInfo("Citadel Siege", 62, Rarity.RARE, mage.cards.c.CitadelSiege.class)); cards.add(new SetCardInfo("Chromatic Lantern", 247, Rarity.RARE, mage.cards.c.ChromaticLantern.class));
cards.add(new SetCardInfo("Clan Defiance", 187, Rarity.RARE, mage.cards.c.ClanDefiance.class)); cards.add(new SetCardInfo("Citadel Siege", 62, Rarity.RARE, mage.cards.c.CitadelSiege.class));
cards.add(new SetCardInfo("Coastal Breach", 6, Rarity.RARE, mage.cards.c.CoastalBreach.class)); cards.add(new SetCardInfo("Clan Defiance", 187, Rarity.RARE, mage.cards.c.ClanDefiance.class));
cards.add(new SetCardInfo("Coiling Oracle", 188, Rarity.COMMON, mage.cards.c.CoilingOracle.class)); cards.add(new SetCardInfo("Coastal Breach", 6, Rarity.RARE, mage.cards.c.CoastalBreach.class));
cards.add(new SetCardInfo("Collective Voyage", 145, Rarity.RARE, mage.cards.c.CollectiveVoyage.class)); cards.add(new SetCardInfo("Coiling Oracle", 188, Rarity.COMMON, mage.cards.c.CoilingOracle.class));
cards.add(new SetCardInfo("Command Tower", 286, Rarity.COMMON, mage.cards.c.CommandTower.class)); cards.add(new SetCardInfo("Collective Voyage", 145, Rarity.RARE, mage.cards.c.CollectiveVoyage.class));
cards.add(new SetCardInfo("Commander's Sphere", 248, Rarity.COMMON, mage.cards.c.CommandersSphere.class)); cards.add(new SetCardInfo("Command Tower", 286, Rarity.COMMON, mage.cards.c.CommandTower.class));
cards.add(new SetCardInfo("Conqueror's Flail", 53, Rarity.RARE, mage.cards.c.ConquerorsFlail.class)); cards.add(new SetCardInfo("Commander's Sphere", 248, Rarity.COMMON, mage.cards.c.CommandersSphere.class));
cards.add(new SetCardInfo("Consuming Aberration", 189, Rarity.RARE, mage.cards.c.ConsumingAberration.class)); cards.add(new SetCardInfo("Conqueror's Flail", 53, Rarity.RARE, mage.cards.c.ConquerorsFlail.class));
cards.add(new SetCardInfo("Corpsejack Menace", 190, Rarity.RARE, mage.cards.c.CorpsejackMenace.class)); cards.add(new SetCardInfo("Consuming Aberration", 189, Rarity.RARE, mage.cards.c.ConsumingAberration.class));
cards.add(new SetCardInfo("Crackling Doom", 191, Rarity.RARE, mage.cards.c.CracklingDoom.class)); cards.add(new SetCardInfo("Corpsejack Menace", 190, Rarity.RARE, mage.cards.c.CorpsejackMenace.class));
cards.add(new SetCardInfo("Cranial Plating", 249, Rarity.UNCOMMON, mage.cards.c.CranialPlating.class)); cards.add(new SetCardInfo("Crackling Doom", 191, Rarity.RARE, mage.cards.c.CracklingDoom.class));
cards.add(new SetCardInfo("Crumbling Necropolis", 287, Rarity.UNCOMMON, mage.cards.c.CrumblingNecropolis.class)); cards.add(new SetCardInfo("Cranial Plating", 249, Rarity.UNCOMMON, mage.cards.c.CranialPlating.class));
cards.add(new SetCardInfo("Crystalline Crawler", 54, Rarity.RARE, mage.cards.c.CrystallineCrawler.class)); cards.add(new SetCardInfo("Crumbling Necropolis", 287, Rarity.UNCOMMON, mage.cards.c.CrumblingNecropolis.class));
cards.add(new SetCardInfo("Cultivate", 146, Rarity.COMMON, mage.cards.c.Cultivate.class)); cards.add(new SetCardInfo("Crystalline Crawler", 54, Rarity.RARE, mage.cards.c.CrystallineCrawler.class));
cards.add(new SetCardInfo("Curtains' Call", 13, Rarity.RARE, mage.cards.c.CurtainsCall.class)); cards.add(new SetCardInfo("Cultivate", 146, Rarity.COMMON, mage.cards.c.Cultivate.class));
cards.add(new SetCardInfo("Curse of Vengeance", 12, Rarity.RARE, mage.cards.c.CurseOfVengeance.class)); cards.add(new SetCardInfo("Curtains' Call", 13, Rarity.RARE, mage.cards.c.CurtainsCall.class));
cards.add(new SetCardInfo("Custodi Soulbinders", 63, Rarity.RARE, mage.cards.c.CustodiSoulbinders.class)); cards.add(new SetCardInfo("Curse of Vengeance", 12, Rarity.RARE, mage.cards.c.CurseOfVengeance.class));
cards.add(new SetCardInfo("Daretti, Scrap Savant", 123, Rarity.MYTHIC, mage.cards.d.DarettiScrapSavant.class)); cards.add(new SetCardInfo("Custodi Soulbinders", 63, Rarity.RARE, mage.cards.c.CustodiSoulbinders.class));
cards.add(new SetCardInfo("Darksteel Citadel", 288, Rarity.UNCOMMON, mage.cards.d.DarksteelCitadel.class)); cards.add(new SetCardInfo("Daretti, Scrap Savant", 123, Rarity.MYTHIC, mage.cards.d.DarettiScrapSavant.class));
cards.add(new SetCardInfo("Darksteel Ingot", 250, Rarity.UNCOMMON, mage.cards.d.DarksteelIngot.class)); cards.add(new SetCardInfo("Darksteel Citadel", 288, Rarity.UNCOMMON, mage.cards.d.DarksteelCitadel.class));
cards.add(new SetCardInfo("Darkwater Catacombs", 289, Rarity.RARE, mage.cards.d.DarkwaterCatacombs.class)); cards.add(new SetCardInfo("Darksteel Ingot", 250, Rarity.UNCOMMON, mage.cards.d.DarksteelIngot.class));
cards.add(new SetCardInfo("Dauntless Escort", 192, Rarity.RARE, mage.cards.d.DauntlessEscort.class)); cards.add(new SetCardInfo("Darkwater Catacombs", 289, Rarity.RARE, mage.cards.d.DarkwaterCatacombs.class));
cards.add(new SetCardInfo("Decimate", 193, Rarity.RARE, mage.cards.d.Decimate.class)); cards.add(new SetCardInfo("Dauntless Escort", 192, Rarity.RARE, mage.cards.d.DauntlessEscort.class));
cards.add(new SetCardInfo("Deepglow Skate", 7, Rarity.RARE, mage.cards.d.DeepglowSkate.class)); cards.add(new SetCardInfo("Decimate", 193, Rarity.RARE, mage.cards.d.Decimate.class));
cards.add(new SetCardInfo("Den Protector", 147, Rarity.RARE, mage.cards.d.DenProtector.class)); cards.add(new SetCardInfo("Deepglow Skate", 7, Rarity.RARE, mage.cards.d.DeepglowSkate.class));
cards.add(new SetCardInfo("Devastation Tide", 87, Rarity.RARE, mage.cards.d.DevastationTide.class)); cards.add(new SetCardInfo("Den Protector", 147, Rarity.RARE, mage.cards.d.DenProtector.class));
cards.add(new SetCardInfo("Dimir Aqueduct", 290, Rarity.UNCOMMON, mage.cards.d.DimirAqueduct.class)); cards.add(new SetCardInfo("Devastation Tide", 87, Rarity.RARE, mage.cards.d.DevastationTide.class));
cards.add(new SetCardInfo("Disdainful Stroke", 88, Rarity.COMMON, mage.cards.d.DisdainfulStroke.class)); cards.add(new SetCardInfo("Dimir Aqueduct", 290, Rarity.UNCOMMON, mage.cards.d.DimirAqueduct.class));
cards.add(new SetCardInfo("Dismal Backwater", 291, Rarity.COMMON, mage.cards.d.DismalBackwater.class)); cards.add(new SetCardInfo("Disdainful Stroke", 88, Rarity.COMMON, mage.cards.d.DisdainfulStroke.class));
cards.add(new SetCardInfo("Dispeller's Capsule", 64, Rarity.COMMON, mage.cards.d.DispellersCapsule.class)); cards.add(new SetCardInfo("Dismal Backwater", 291, Rarity.COMMON, mage.cards.d.DismalBackwater.class));
cards.add(new SetCardInfo("Divergent Transformations", 17, Rarity.RARE, mage.cards.d.DivergentTransformations.class)); cards.add(new SetCardInfo("Dispeller's Capsule", 64, Rarity.COMMON, mage.cards.d.DispellersCapsule.class));
cards.add(new SetCardInfo("Dragon Mage", 124, Rarity.RARE, mage.cards.d.DragonMage.class)); cards.add(new SetCardInfo("Divergent Transformations", 17, Rarity.RARE, mage.cards.d.DivergentTransformations.class));
cards.add(new SetCardInfo("Dragonskull Summit", 292, Rarity.RARE, mage.cards.d.DragonskullSummit.class)); cards.add(new SetCardInfo("Dragon Mage", 124, Rarity.RARE, mage.cards.d.DragonMage.class));
cards.add(new SetCardInfo("Dreadship Reef", 293, Rarity.UNCOMMON, mage.cards.d.DreadshipReef.class)); cards.add(new SetCardInfo("Dragonskull Summit", 292, Rarity.RARE, mage.cards.d.DragonskullSummit.class));
cards.add(new SetCardInfo("Duelist's Heritage", 1, Rarity.RARE, mage.cards.d.DuelistsHeritage.class)); cards.add(new SetCardInfo("Dreadship Reef", 293, Rarity.UNCOMMON, mage.cards.d.DreadshipReef.class));
cards.add(new SetCardInfo("Duneblast", 194, Rarity.RARE, mage.cards.d.Duneblast.class)); cards.add(new SetCardInfo("Duelist's Heritage", 1, Rarity.RARE, mage.cards.d.DuelistsHeritage.class));
cards.add(new SetCardInfo("Edric, Spymaster of Trest", 195, Rarity.RARE, mage.cards.e.EdricSpymasterOfTrest.class)); cards.add(new SetCardInfo("Duneblast", 194, Rarity.RARE, mage.cards.d.Duneblast.class));
cards.add(new SetCardInfo("Elite Scaleguard", 65, Rarity.UNCOMMON, mage.cards.e.EliteScaleguard.class)); cards.add(new SetCardInfo("Edric, Spymaster of Trest", 195, Rarity.RARE, mage.cards.e.EdricSpymasterOfTrest.class));
cards.add(new SetCardInfo("Empyrial Plate", 251, Rarity.RARE, mage.cards.e.EmpyrialPlate.class)); cards.add(new SetCardInfo("Elite Scaleguard", 65, Rarity.UNCOMMON, mage.cards.e.EliteScaleguard.class));
cards.add(new SetCardInfo("Enduring Scalelord", 196, Rarity.UNCOMMON, mage.cards.e.EnduringScalelord.class)); cards.add(new SetCardInfo("Empyrial Plate", 251, Rarity.RARE, mage.cards.e.EmpyrialPlate.class));
cards.add(new SetCardInfo("Entrapment Maneuver", 2, Rarity.RARE, mage.cards.e.EntrapmentManeuver.class)); cards.add(new SetCardInfo("Enduring Scalelord", 196, Rarity.UNCOMMON, mage.cards.e.EnduringScalelord.class));
cards.add(new SetCardInfo("Etched Oracle", 252, Rarity.UNCOMMON, mage.cards.e.EtchedOracle.class)); cards.add(new SetCardInfo("Entrapment Maneuver", 2, Rarity.RARE, mage.cards.e.EntrapmentManeuver.class));
cards.add(new SetCardInfo("Etherium Sculptor", 89, Rarity.COMMON, mage.cards.e.EtheriumSculptor.class)); cards.add(new SetCardInfo("Etched Oracle", 252, Rarity.UNCOMMON, mage.cards.e.EtchedOracle.class));
cards.add(new SetCardInfo("Etherium-Horn Sorcerer", 197, Rarity.RARE, mage.cards.e.EtheriumHornSorcerer.class)); cards.add(new SetCardInfo("Etherium Sculptor", 89, Rarity.COMMON, mage.cards.e.EtheriumSculptor.class));
cards.add(new SetCardInfo("Ethersworn Adjudicator", 90, Rarity.MYTHIC, mage.cards.e.EtherswornAdjudicator.class)); cards.add(new SetCardInfo("Etherium-Horn Sorcerer", 197, Rarity.RARE, mage.cards.e.EtheriumHornSorcerer.class));
cards.add(new SetCardInfo("Evacuation", 91, Rarity.RARE, mage.cards.e.Evacuation.class)); cards.add(new SetCardInfo("Ethersworn Adjudicator", 90, Rarity.MYTHIC, mage.cards.e.EtherswornAdjudicator.class));
cards.add(new SetCardInfo("Everflowing Chalice", 253, Rarity.UNCOMMON, mage.cards.e.EverflowingChalice.class)); cards.add(new SetCardInfo("Evacuation", 91, Rarity.RARE, mage.cards.e.Evacuation.class));
cards.add(new SetCardInfo("Everlasting Torment", 233, Rarity.RARE, mage.cards.e.EverlastingTorment.class)); cards.add(new SetCardInfo("Everflowing Chalice", 253, Rarity.UNCOMMON, mage.cards.e.EverflowingChalice.class));
cards.add(new SetCardInfo("Evolving Wilds", 294, Rarity.COMMON, mage.cards.e.EvolvingWilds.class)); cards.add(new SetCardInfo("Everlasting Torment", 233, Rarity.RARE, mage.cards.e.EverlastingTorment.class));
cards.add(new SetCardInfo("Executioner's Capsule", 109, Rarity.COMMON, mage.cards.e.ExecutionersCapsule.class)); cards.add(new SetCardInfo("Evolving Wilds", 294, Rarity.COMMON, mage.cards.e.EvolvingWilds.class));
cards.add(new SetCardInfo("Exotic Orchard", 295, Rarity.RARE, mage.cards.e.ExoticOrchard.class)); cards.add(new SetCardInfo("Executioner's Capsule", 109, Rarity.COMMON, mage.cards.e.ExecutionersCapsule.class));
cards.add(new SetCardInfo("Far Wanderings", 148, Rarity.COMMON, mage.cards.f.FarWanderings.class)); cards.add(new SetCardInfo("Exotic Orchard", 295, Rarity.RARE, mage.cards.e.ExoticOrchard.class));
cards.add(new SetCardInfo("Farseek", 149, Rarity.COMMON, mage.cards.f.Farseek.class)); cards.add(new SetCardInfo("Far Wanderings", 148, Rarity.COMMON, mage.cards.f.FarWanderings.class));
cards.add(new SetCardInfo("Fathom Mage", 198, Rarity.RARE, mage.cards.f.FathomMage.class)); cards.add(new SetCardInfo("Farseek", 149, Rarity.COMMON, mage.cards.f.Farseek.class));
cards.add(new SetCardInfo("Fellwar Stone", 254, Rarity.UNCOMMON, mage.cards.f.FellwarStone.class)); cards.add(new SetCardInfo("Fathom Mage", 198, Rarity.RARE, mage.cards.f.FathomMage.class));
cards.add(new SetCardInfo("Festercreep", 110, Rarity.COMMON, mage.cards.f.Festercreep.class)); cards.add(new SetCardInfo("Fellwar Stone", 254, Rarity.UNCOMMON, mage.cards.f.FellwarStone.class));
cards.add(new SetCardInfo("Filigree Angel", 199, Rarity.RARE, mage.cards.f.FiligreeAngel.class)); cards.add(new SetCardInfo("Festercreep", 110, Rarity.COMMON, mage.cards.f.Festercreep.class));
cards.add(new SetCardInfo("Forbidden Orchard", 296, Rarity.RARE, mage.cards.f.ForbiddenOrchard.class)); cards.add(new SetCardInfo("Filigree Angel", 199, Rarity.RARE, mage.cards.f.FiligreeAngel.class));
cards.add(new SetCardInfo("Forest", 349, Rarity.LAND, mage.cards.basiclands.Forest.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Forbidden Orchard", 296, Rarity.RARE, mage.cards.f.ForbiddenOrchard.class));
cards.add(new SetCardInfo("Forest", 350, Rarity.LAND, mage.cards.basiclands.Forest.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Forest", 349, Rarity.LAND, mage.cards.basiclands.Forest.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Forest", 351, Rarity.LAND, mage.cards.basiclands.Forest.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Forest", 350, Rarity.LAND, mage.cards.basiclands.Forest.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Forgotten Ancient", 150, Rarity.RARE, mage.cards.f.ForgottenAncient.class)); cards.add(new SetCardInfo("Forest", 351, Rarity.LAND, mage.cards.basiclands.Forest.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Frontier Bivouac", 297, Rarity.UNCOMMON, mage.cards.f.FrontierBivouac.class)); cards.add(new SetCardInfo("Forgotten Ancient", 150, Rarity.RARE, mage.cards.f.ForgottenAncient.class));
cards.add(new SetCardInfo("Gamekeeper", 151, Rarity.UNCOMMON, mage.cards.g.Gamekeeper.class)); cards.add(new SetCardInfo("Frontier Bivouac", 297, Rarity.UNCOMMON, mage.cards.f.FrontierBivouac.class));
cards.add(new SetCardInfo("Ghastly Conscription", 111, Rarity.MYTHIC, mage.cards.g.GhastlyConscription.class)); cards.add(new SetCardInfo("Gamekeeper", 151, Rarity.UNCOMMON, mage.cards.g.Gamekeeper.class));
cards.add(new SetCardInfo("Ghave, Guru of Spores", 200, Rarity.MYTHIC, mage.cards.g.GhaveGuruOfSpores.class)); cards.add(new SetCardInfo("Ghastly Conscription", 111, Rarity.MYTHIC, mage.cards.g.GhastlyConscription.class));
cards.add(new SetCardInfo("Ghostly Prison", 66, Rarity.UNCOMMON, mage.cards.g.GhostlyPrison.class)); cards.add(new SetCardInfo("Ghave, Guru of Spores", 200, Rarity.MYTHIC, mage.cards.g.GhaveGuruOfSpores.class));
cards.add(new SetCardInfo("Glint-Eye Nephilim", 201, Rarity.RARE, mage.cards.g.GlintEyeNephilim.class)); cards.add(new SetCardInfo("Ghostly Prison", 66, Rarity.UNCOMMON, mage.cards.g.GhostlyPrison.class));
cards.add(new SetCardInfo("Godo, Bandit Warlord", 125, Rarity.RARE, mage.cards.g.GodoBanditWarlord.class)); cards.add(new SetCardInfo("Glint-Eye Nephilim", 201, Rarity.RARE, mage.cards.g.GlintEyeNephilim.class));
cards.add(new SetCardInfo("Golgari Rot Farm", 298, Rarity.UNCOMMON, mage.cards.g.GolgariRotFarm.class)); cards.add(new SetCardInfo("Goblin Spymaster", 19, Rarity.RARE, mage.cards.g.GoblinSpymaster.class));
cards.add(new SetCardInfo("Golgari Signet", 255, Rarity.COMMON, mage.cards.g.GolgariSignet.class)); cards.add(new SetCardInfo("Godo, Bandit Warlord", 125, Rarity.RARE, mage.cards.g.GodoBanditWarlord.class));
cards.add(new SetCardInfo("Grab the Reins", 126, Rarity.UNCOMMON, mage.cards.g.GrabTheReins.class)); cards.add(new SetCardInfo("Golgari Rot Farm", 298, Rarity.UNCOMMON, mage.cards.g.GolgariRotFarm.class));
cards.add(new SetCardInfo("Grand Coliseum", 299, Rarity.RARE, mage.cards.g.GrandColiseum.class)); cards.add(new SetCardInfo("Golgari Signet", 255, Rarity.COMMON, mage.cards.g.GolgariSignet.class));
cards.add(new SetCardInfo("Grave Upheaval", 31, Rarity.UNCOMMON, mage.cards.g.GraveUpheaval.class)); cards.add(new SetCardInfo("Grab the Reins", 126, Rarity.UNCOMMON, mage.cards.g.GrabTheReins.class));
cards.add(new SetCardInfo("Gruul Signet", 256, Rarity.COMMON, mage.cards.g.GruulSignet.class)); cards.add(new SetCardInfo("Grand Coliseum", 299, Rarity.RARE, mage.cards.g.GrandColiseum.class));
cards.add(new SetCardInfo("Gruul Turf", 300, Rarity.UNCOMMON, mage.cards.g.GruulTurf.class)); cards.add(new SetCardInfo("Grave Upheaval", 31, Rarity.UNCOMMON, mage.cards.g.GraveUpheaval.class));
cards.add(new SetCardInfo("Guiltfeeder", 112, Rarity.RARE, mage.cards.g.Guiltfeeder.class)); cards.add(new SetCardInfo("Gruul Signet", 256, Rarity.COMMON, mage.cards.g.GruulSignet.class));
cards.add(new SetCardInfo("Gwafa Hazid, Profiteer", 202, Rarity.RARE, mage.cards.g.GwafaHazidProfiteer.class)); cards.add(new SetCardInfo("Gruul Turf", 300, Rarity.UNCOMMON, mage.cards.g.GruulTurf.class));
cards.add(new SetCardInfo("Hanna, Ship's Navigator", 203, Rarity.RARE, mage.cards.h.HannaShipsNavigator.class)); cards.add(new SetCardInfo("Guiltfeeder", 112, Rarity.RARE, mage.cards.g.Guiltfeeder.class));
cards.add(new SetCardInfo("Hardened Scales", 152, Rarity.RARE, mage.cards.h.HardenedScales.class)); cards.add(new SetCardInfo("Gwafa Hazid, Profiteer", 202, Rarity.RARE, mage.cards.g.GwafaHazidProfiteer.class));
cards.add(new SetCardInfo("Hellkite Igniter", 127, Rarity.RARE, mage.cards.h.HellkiteIgniter.class)); cards.add(new SetCardInfo("Hanna, Ship's Navigator", 203, Rarity.RARE, mage.cards.h.HannaShipsNavigator.class));
cards.add(new SetCardInfo("Hellkite Tyrant", 128, Rarity.MYTHIC, mage.cards.h.HellkiteTyrant.class)); cards.add(new SetCardInfo("Hardened Scales", 152, Rarity.RARE, mage.cards.h.HardenedScales.class));
cards.add(new SetCardInfo("Homeward Path", 301, Rarity.RARE, mage.cards.h.HomewardPath.class)); cards.add(new SetCardInfo("Hellkite Igniter", 127, Rarity.RARE, mage.cards.h.HellkiteIgniter.class));
cards.add(new SetCardInfo("Hoofprints of the Stag", 67, Rarity.RARE, mage.cards.h.HoofprintsOfTheStag.class)); cards.add(new SetCardInfo("Hellkite Tyrant", 128, Rarity.MYTHIC, mage.cards.h.HellkiteTyrant.class));
cards.add(new SetCardInfo("Horizon Chimera", 204, Rarity.UNCOMMON, mage.cards.h.HorizonChimera.class)); cards.add(new SetCardInfo("Homeward Path", 301, Rarity.RARE, mage.cards.h.HomewardPath.class));
cards.add(new SetCardInfo("Howling Mine", 257, Rarity.RARE, mage.cards.h.HowlingMine.class)); cards.add(new SetCardInfo("Hoofprints of the Stag", 67, Rarity.RARE, mage.cards.h.HoofprintsOfTheStag.class));
cards.add(new SetCardInfo("Humble Defector", 129, Rarity.UNCOMMON, mage.cards.h.HumbleDefector.class)); cards.add(new SetCardInfo("Horizon Chimera", 204, Rarity.UNCOMMON, mage.cards.h.HorizonChimera.class));
cards.add(new SetCardInfo("Hushwing Gryff", 68, Rarity.RARE, mage.cards.h.HushwingGryff.class)); cards.add(new SetCardInfo("Howling Mine", 257, Rarity.RARE, mage.cards.h.HowlingMine.class));
cards.add(new SetCardInfo("Ichor Wellspring", 258, Rarity.COMMON, mage.cards.i.IchorWellspring.class)); cards.add(new SetCardInfo("Humble Defector", 129, Rarity.UNCOMMON, mage.cards.h.HumbleDefector.class));
cards.add(new SetCardInfo("In Garruk's Wake", 113, Rarity.RARE, mage.cards.i.InGarruksWake.class)); cards.add(new SetCardInfo("Hushwing Gryff", 68, Rarity.RARE, mage.cards.h.HushwingGryff.class));
cards.add(new SetCardInfo("Inspiring Call", 153, Rarity.UNCOMMON, mage.cards.i.InspiringCall.class)); cards.add(new SetCardInfo("Ichor Wellspring", 258, Rarity.COMMON, mage.cards.i.IchorWellspring.class));
cards.add(new SetCardInfo("Iroas, God of Victory", 205, Rarity.MYTHIC, mage.cards.i.IroasGodOfVictory.class)); cards.add(new SetCardInfo("In Garruk's Wake", 113, Rarity.RARE, mage.cards.i.InGarruksWake.class));
cards.add(new SetCardInfo("Island", 340, Rarity.LAND, mage.cards.basiclands.Island.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Inspiring Call", 153, Rarity.UNCOMMON, mage.cards.i.InspiringCall.class));
cards.add(new SetCardInfo("Island", 341, Rarity.LAND, mage.cards.basiclands.Island.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Iroas, God of Victory", 205, Rarity.MYTHIC, mage.cards.i.IroasGodOfVictory.class));
cards.add(new SetCardInfo("Island", 342, Rarity.LAND, mage.cards.basiclands.Island.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Island", 340, Rarity.LAND, mage.cards.basiclands.Island.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Izzet Boilerworks", 302, Rarity.UNCOMMON, mage.cards.i.IzzetBoilerworks.class)); cards.add(new SetCardInfo("Island", 341, Rarity.LAND, mage.cards.basiclands.Island.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Jor Kadeen, the Prevailer", 206, Rarity.RARE, mage.cards.j.JorKadeenThePrevailer.class)); cards.add(new SetCardInfo("Island", 342, Rarity.LAND, mage.cards.basiclands.Island.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Jungle Hollow", 303, Rarity.COMMON, mage.cards.j.JungleHollow.class)); cards.add(new SetCardInfo("Izzet Boilerworks", 302, Rarity.UNCOMMON, mage.cards.i.IzzetBoilerworks.class));
cards.add(new SetCardInfo("Jungle Shrine", 304, Rarity.UNCOMMON, mage.cards.j.JungleShrine.class)); cards.add(new SetCardInfo("Jor Kadeen, the Prevailer", 206, Rarity.RARE, mage.cards.j.JorKadeenThePrevailer.class));
cards.add(new SetCardInfo("Juniper Order Ranger", 207, Rarity.UNCOMMON, mage.cards.j.JuniperOrderRanger.class)); cards.add(new SetCardInfo("Jungle Hollow", 303, Rarity.COMMON, mage.cards.j.JungleHollow.class));
cards.add(new SetCardInfo("Kalonian Hydra", 154, Rarity.MYTHIC, mage.cards.k.KalonianHydra.class)); cards.add(new SetCardInfo("Jungle Shrine", 304, Rarity.UNCOMMON, mage.cards.j.JungleShrine.class));
cards.add(new SetCardInfo("Karplusan Forest", 305, Rarity.RARE, mage.cards.k.KarplusanForest.class)); cards.add(new SetCardInfo("Juniper Order Ranger", 207, Rarity.UNCOMMON, mage.cards.j.JuniperOrderRanger.class));
cards.add(new SetCardInfo("Kazuul, Tyrant of the Cliffs", 130, Rarity.RARE, mage.cards.k.KazuulTyrantOfTheCliffs.class)); cards.add(new SetCardInfo("Kalonian Hydra", 154, Rarity.MYTHIC, mage.cards.k.KalonianHydra.class));
cards.add(new SetCardInfo("Keening Stone", 259, Rarity.RARE, mage.cards.k.KeeningStone.class)); cards.add(new SetCardInfo("Karplusan Forest", 305, Rarity.RARE, mage.cards.k.KarplusanForest.class));
cards.add(new SetCardInfo("Kodama's Reach", 155, Rarity.COMMON, mage.cards.k.KodamasReach.class)); cards.add(new SetCardInfo("Kazuul, Tyrant of the Cliffs", 130, Rarity.RARE, mage.cards.k.KazuulTyrantOfTheCliffs.class));
cards.add(new SetCardInfo("Korozda Guildmage", 208, Rarity.UNCOMMON, mage.cards.k.KorozdaGuildmage.class)); cards.add(new SetCardInfo("Keening Stone", 259, Rarity.RARE, mage.cards.k.KeeningStone.class));
cards.add(new SetCardInfo("Krosan Verge", 306, Rarity.UNCOMMON, mage.cards.k.KrosanVerge.class)); cards.add(new SetCardInfo("Kodama's Reach", 155, Rarity.COMMON, mage.cards.k.KodamasReach.class));
cards.add(new SetCardInfo("Languish", 114, Rarity.RARE, mage.cards.l.Languish.class)); cards.add(new SetCardInfo("Korozda Guildmage", 208, Rarity.UNCOMMON, mage.cards.k.KorozdaGuildmage.class));
cards.add(new SetCardInfo("Lavalanche", 209, Rarity.RARE, mage.cards.l.Lavalanche.class)); cards.add(new SetCardInfo("Krosan Verge", 306, Rarity.UNCOMMON, mage.cards.k.KrosanVerge.class));
cards.add(new SetCardInfo("Lightning Greaves", 260, Rarity.UNCOMMON, mage.cards.l.LightningGreaves.class)); cards.add(new SetCardInfo("Languish", 114, Rarity.RARE, mage.cards.l.Languish.class));
cards.add(new SetCardInfo("Loxodon Warhammer", 261, Rarity.UNCOMMON, mage.cards.l.LoxodonWarhammer.class)); cards.add(new SetCardInfo("Lavalanche", 209, Rarity.RARE, mage.cards.l.Lavalanche.class));
cards.add(new SetCardInfo("Lurking Predators", 156, Rarity.RARE, mage.cards.l.LurkingPredators.class)); cards.add(new SetCardInfo("Lightning Greaves", 260, Rarity.UNCOMMON, mage.cards.l.LightningGreaves.class));
cards.add(new SetCardInfo("Magus of the Will", 14, Rarity.RARE, mage.cards.m.MagusOfTheWill.class)); cards.add(new SetCardInfo("Loxodon Warhammer", 261, Rarity.UNCOMMON, mage.cards.l.LoxodonWarhammer.class));
cards.add(new SetCardInfo("Managorger Hydra", 157, Rarity.RARE, mage.cards.m.ManagorgerHydra.class)); cards.add(new SetCardInfo("Lurking Predators", 156, Rarity.RARE, mage.cards.l.LurkingPredators.class));
cards.add(new SetCardInfo("Master Biomancer", 210, Rarity.MYTHIC, mage.cards.m.MasterBiomancer.class)); cards.add(new SetCardInfo("Magus of the Will", 14, Rarity.RARE, mage.cards.m.MagusOfTheWill.class));
cards.add(new SetCardInfo("Master of Etherium", 92, Rarity.RARE, mage.cards.m.MasterOfEtherium.class)); cards.add(new SetCardInfo("Managorger Hydra", 157, Rarity.RARE, mage.cards.m.ManagorgerHydra.class));
cards.add(new SetCardInfo("Mentor of the Meek", 69, Rarity.RARE, mage.cards.m.MentorOfTheMeek.class)); cards.add(new SetCardInfo("Master Biomancer", 210, Rarity.MYTHIC, mage.cards.m.MasterBiomancer.class));
cards.add(new SetCardInfo("Merciless Eviction", 211, Rarity.RARE, mage.cards.m.MercilessEviction.class)); cards.add(new SetCardInfo("Master of Etherium", 92, Rarity.RARE, mage.cards.m.MasterOfEtherium.class));
cards.add(new SetCardInfo("Migratory Route", 38, Rarity.UNCOMMON, mage.cards.m.MigratoryRoute.class)); cards.add(new SetCardInfo("Mentor of the Meek", 69, Rarity.RARE, mage.cards.m.MentorOfTheMeek.class));
cards.add(new SetCardInfo("Minds Aglow", 93, Rarity.RARE, mage.cards.m.MindsAglow.class)); cards.add(new SetCardInfo("Merciless Eviction", 211, Rarity.RARE, mage.cards.m.MercilessEviction.class));
cards.add(new SetCardInfo("Mirror Entity", 70, Rarity.RARE, mage.cards.m.MirrorEntity.class)); cards.add(new SetCardInfo("Migratory Route", 38, Rarity.UNCOMMON, mage.cards.m.MigratoryRoute.class));
cards.add(new SetCardInfo("Mirrorweave", 234, Rarity.RARE, mage.cards.m.Mirrorweave.class)); cards.add(new SetCardInfo("Minds Aglow", 93, Rarity.RARE, mage.cards.m.MindsAglow.class));
cards.add(new SetCardInfo("Mortify", 212, Rarity.UNCOMMON, mage.cards.m.Mortify.class)); cards.add(new SetCardInfo("Mirror Entity", 70, Rarity.RARE, mage.cards.m.MirrorEntity.class));
cards.add(new SetCardInfo("Mosswort Bridge", 307, Rarity.RARE, mage.cards.m.MosswortBridge.class)); cards.add(new SetCardInfo("Mirrorweave", 234, Rarity.RARE, mage.cards.m.Mirrorweave.class));
cards.add(new SetCardInfo("Mountain", 346, Rarity.LAND, mage.cards.basiclands.Mountain.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Mortify", 212, Rarity.UNCOMMON, mage.cards.m.Mortify.class));
cards.add(new SetCardInfo("Mountain", 347, Rarity.LAND, mage.cards.basiclands.Mountain.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Mosswort Bridge", 307, Rarity.RARE, mage.cards.m.MosswortBridge.class));
cards.add(new SetCardInfo("Mountain", 348, Rarity.LAND, mage.cards.basiclands.Mountain.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Mountain", 346, Rarity.LAND, mage.cards.basiclands.Mountain.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Murmuring Bosk", 308, Rarity.RARE, mage.cards.m.MurmuringBosk.class)); cards.add(new SetCardInfo("Mountain", 347, Rarity.LAND, mage.cards.basiclands.Mountain.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Mycoloth", 158, Rarity.RARE, mage.cards.m.Mycoloth.class)); cards.add(new SetCardInfo("Mountain", 348, Rarity.LAND, mage.cards.basiclands.Mountain.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Mycosynth Wellspring", 262, Rarity.COMMON, mage.cards.m.MycosynthWellspring.class)); cards.add(new SetCardInfo("Murmuring Bosk", 308, Rarity.RARE, mage.cards.m.MurmuringBosk.class));
cards.add(new SetCardInfo("Myr Battlesphere", 263, Rarity.RARE, mage.cards.m.MyrBattlesphere.class)); cards.add(new SetCardInfo("Mycoloth", 158, Rarity.RARE, mage.cards.m.Mycoloth.class));
cards.add(new SetCardInfo("Myr Retriever", 264, Rarity.UNCOMMON, mage.cards.m.MyrRetriever.class)); cards.add(new SetCardInfo("Mycosynth Wellspring", 262, Rarity.COMMON, mage.cards.m.MycosynthWellspring.class));
cards.add(new SetCardInfo("Myriad Landscape", 309, Rarity.UNCOMMON, mage.cards.m.MyriadLandscape.class)); cards.add(new SetCardInfo("Myr Battlesphere", 263, Rarity.RARE, mage.cards.m.MyrBattlesphere.class));
cards.add(new SetCardInfo("Mystic Monastery", 310, Rarity.UNCOMMON, mage.cards.m.MysticMonastery.class)); cards.add(new SetCardInfo("Myr Retriever", 264, Rarity.UNCOMMON, mage.cards.m.MyrRetriever.class));
cards.add(new SetCardInfo("Nath of the Gilt-Leaf", 213, Rarity.RARE, mage.cards.n.NathOfTheGiltLeaf.class)); cards.add(new SetCardInfo("Myriad Landscape", 309, Rarity.UNCOMMON, mage.cards.m.MyriadLandscape.class));
cards.add(new SetCardInfo("Naya Charm", 214, Rarity.UNCOMMON, mage.cards.n.NayaCharm.class)); cards.add(new SetCardInfo("Mystic Monastery", 310, Rarity.UNCOMMON, mage.cards.m.MysticMonastery.class));
cards.add(new SetCardInfo("Necrogenesis", 215, Rarity.UNCOMMON, mage.cards.n.Necrogenesis.class)); cards.add(new SetCardInfo("Nath of the Gilt-Leaf", 213, Rarity.RARE, mage.cards.n.NathOfTheGiltLeaf.class));
cards.add(new SetCardInfo("Necroplasm", 115, Rarity.RARE, mage.cards.n.Necroplasm.class)); cards.add(new SetCardInfo("Naya Charm", 214, Rarity.UNCOMMON, mage.cards.n.NayaCharm.class));
cards.add(new SetCardInfo("Nevinyrral's Disk", 265, Rarity.RARE, mage.cards.n.NevinyrralsDisk.class)); cards.add(new SetCardInfo("Necrogenesis", 215, Rarity.UNCOMMON, mage.cards.n.Necrogenesis.class));
cards.add(new SetCardInfo("Nomad Outpost", 311, Rarity.UNCOMMON, mage.cards.n.NomadOutpost.class)); cards.add(new SetCardInfo("Necroplasm", 115, Rarity.RARE, mage.cards.n.Necroplasm.class));
cards.add(new SetCardInfo("Oath of Druids", 159, Rarity.RARE, mage.cards.o.OathOfDruids.class)); cards.add(new SetCardInfo("Nevinyrral's Disk", 265, Rarity.RARE, mage.cards.n.NevinyrralsDisk.class));
cards.add(new SetCardInfo("Oblation", 71, Rarity.RARE, mage.cards.o.Oblation.class)); cards.add(new SetCardInfo("Nomad Outpost", 311, Rarity.UNCOMMON, mage.cards.n.NomadOutpost.class));
cards.add(new SetCardInfo("Opal Palace", 312, Rarity.COMMON, mage.cards.o.OpalPalace.class)); cards.add(new SetCardInfo("Oath of Druids", 159, Rarity.RARE, mage.cards.o.OathOfDruids.class));
cards.add(new SetCardInfo("Open the Vaults", 72, Rarity.RARE, mage.cards.o.OpenTheVaults.class)); cards.add(new SetCardInfo("Oblation", 71, Rarity.RARE, mage.cards.o.Oblation.class));
cards.add(new SetCardInfo("Opulent Palace", 313, Rarity.UNCOMMON, mage.cards.o.OpulentPalace.class)); cards.add(new SetCardInfo("Opal Palace", 312, Rarity.COMMON, mage.cards.o.OpalPalace.class));
cards.add(new SetCardInfo("Order // Chaos", 240, Rarity.UNCOMMON, mage.cards.o.OrderChaos.class)); cards.add(new SetCardInfo("Open the Vaults", 72, Rarity.RARE, mage.cards.o.OpenTheVaults.class));
cards.add(new SetCardInfo("Orzhov Basilica", 314, Rarity.UNCOMMON, mage.cards.o.OrzhovBasilica.class)); cards.add(new SetCardInfo("Opulent Palace", 313, Rarity.UNCOMMON, mage.cards.o.OpulentPalace.class));
cards.add(new SetCardInfo("Orzhov Signet", 266, Rarity.COMMON, mage.cards.o.OrzhovSignet.class)); cards.add(new SetCardInfo("Order // Chaos", 240, Rarity.UNCOMMON, mage.cards.o.OrderChaos.class));
cards.add(new SetCardInfo("Past in Flames", 131, Rarity.MYTHIC, mage.cards.p.PastInFlames.class)); cards.add(new SetCardInfo("Orzhov Basilica", 314, Rarity.UNCOMMON, mage.cards.o.OrzhovBasilica.class));
cards.add(new SetCardInfo("Phyrexian Rebirth", 73, Rarity.RARE, mage.cards.p.PhyrexianRebirth.class)); cards.add(new SetCardInfo("Orzhov Signet", 266, Rarity.COMMON, mage.cards.o.OrzhovSignet.class));
cards.add(new SetCardInfo("Plains", 337, Rarity.LAND, mage.cards.basiclands.Plains.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Past in Flames", 131, Rarity.MYTHIC, mage.cards.p.PastInFlames.class));
cards.add(new SetCardInfo("Plains", 338, Rarity.LAND, mage.cards.basiclands.Plains.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Phyrexian Rebirth", 73, Rarity.RARE, mage.cards.p.PhyrexianRebirth.class));
cards.add(new SetCardInfo("Plains", 339, Rarity.LAND, mage.cards.basiclands.Plains.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Plains", 337, Rarity.LAND, mage.cards.basiclands.Plains.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Primeval Protector", 23, Rarity.RARE, mage.cards.p.PrimevalProtector.class)); cards.add(new SetCardInfo("Plains", 338, Rarity.LAND, mage.cards.basiclands.Plains.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Prismatic Geoscope", 55, Rarity.RARE, mage.cards.p.PrismaticGeoscope.class)); cards.add(new SetCardInfo("Plains", 339, Rarity.LAND, mage.cards.basiclands.Plains.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Progenitor Mimic", 216, Rarity.MYTHIC, mage.cards.p.ProgenitorMimic.class)); cards.add(new SetCardInfo("Primeval Protector", 23, Rarity.RARE, mage.cards.p.PrimevalProtector.class));
cards.add(new SetCardInfo("Propaganda", 94, Rarity.UNCOMMON, mage.cards.p.Propaganda.class)); cards.add(new SetCardInfo("Prismatic Geoscope", 55, Rarity.RARE, mage.cards.p.PrismaticGeoscope.class));
cards.add(new SetCardInfo("Psychosis Crawler", 267, Rarity.RARE, mage.cards.p.PsychosisCrawler.class)); cards.add(new SetCardInfo("Progenitor Mimic", 216, Rarity.MYTHIC, mage.cards.p.ProgenitorMimic.class));
cards.add(new SetCardInfo("Putrefy", 217, Rarity.UNCOMMON, mage.cards.p.Putrefy.class)); cards.add(new SetCardInfo("Propaganda", 94, Rarity.UNCOMMON, mage.cards.p.Propaganda.class));
cards.add(new SetCardInfo("Quirion Explorer", 160, Rarity.COMMON, mage.cards.q.QuirionExplorer.class)); cards.add(new SetCardInfo("Psychosis Crawler", 267, Rarity.RARE, mage.cards.p.PsychosisCrawler.class));
cards.add(new SetCardInfo("Rakdos Carnarium", 315, Rarity.UNCOMMON, mage.cards.r.RakdosCarnarium.class)); cards.add(new SetCardInfo("Putrefy", 217, Rarity.UNCOMMON, mage.cards.p.Putrefy.class));
cards.add(new SetCardInfo("Rakdos Charm", 218, Rarity.UNCOMMON, mage.cards.r.RakdosCharm.class)); cards.add(new SetCardInfo("Quirion Explorer", 160, Rarity.COMMON, mage.cards.q.QuirionExplorer.class));
cards.add(new SetCardInfo("Rakdos Signet", 268, Rarity.COMMON, mage.cards.r.RakdosSignet.class)); cards.add(new SetCardInfo("Rakdos Carnarium", 315, Rarity.UNCOMMON, mage.cards.r.RakdosCarnarium.class));
cards.add(new SetCardInfo("Rampant Growth", 161, Rarity.COMMON, mage.cards.r.RampantGrowth.class)); cards.add(new SetCardInfo("Rakdos Charm", 218, Rarity.UNCOMMON, mage.cards.r.RakdosCharm.class));
cards.add(new SetCardInfo("Read the Runes", 95, Rarity.RARE, mage.cards.r.ReadTheRunes.class)); cards.add(new SetCardInfo("Rakdos Signet", 268, Rarity.COMMON, mage.cards.r.RakdosSignet.class));
cards.add(new SetCardInfo("Realm Seekers", 162, Rarity.RARE, mage.cards.r.RealmSeekers.class)); cards.add(new SetCardInfo("Rampant Growth", 161, Rarity.COMMON, mage.cards.r.RampantGrowth.class));
cards.add(new SetCardInfo("Reforge the Soul", 132, Rarity.RARE, mage.cards.r.ReforgeTheSoul.class)); cards.add(new SetCardInfo("Read the Runes", 95, Rarity.RARE, mage.cards.r.ReadTheRunes.class));
cards.add(new SetCardInfo("Reins of Power", 96, Rarity.RARE, mage.cards.r.ReinsOfPower.class)); cards.add(new SetCardInfo("Realm Seekers", 162, Rarity.RARE, mage.cards.r.RealmSeekers.class));
cards.add(new SetCardInfo("Reliquary Tower", 316, Rarity.UNCOMMON, mage.cards.r.ReliquaryTower.class)); cards.add(new SetCardInfo("Reforge the Soul", 132, Rarity.RARE, mage.cards.r.ReforgeTheSoul.class));
cards.add(new SetCardInfo("Reveillark", 74, Rarity.RARE, mage.cards.r.Reveillark.class)); cards.add(new SetCardInfo("Reins of Power", 96, Rarity.RARE, mage.cards.r.ReinsOfPower.class));
cards.add(new SetCardInfo("Reverse the Sands", 75, Rarity.RARE, mage.cards.r.ReverseTheSands.class)); cards.add(new SetCardInfo("Reliquary Tower", 316, Rarity.UNCOMMON, mage.cards.r.ReliquaryTower.class));
cards.add(new SetCardInfo("Rites of Flourishing", 163, Rarity.RARE, mage.cards.r.RitesOfFlourishing.class)); cards.add(new SetCardInfo("Reveillark", 74, Rarity.RARE, mage.cards.r.Reveillark.class));
cards.add(new SetCardInfo("Rootbound Crag", 317, Rarity.RARE, mage.cards.r.RootboundCrag.class)); cards.add(new SetCardInfo("Reverse the Sands", 75, Rarity.RARE, mage.cards.r.ReverseTheSands.class));
cards.add(new SetCardInfo("Rubblehulk", 219, Rarity.RARE, mage.cards.r.Rubblehulk.class)); cards.add(new SetCardInfo("Rites of Flourishing", 163, Rarity.RARE, mage.cards.r.RitesOfFlourishing.class));
cards.add(new SetCardInfo("Rugged Highlands", 318, Rarity.COMMON, mage.cards.r.RuggedHighlands.class)); cards.add(new SetCardInfo("Rootbound Crag", 317, Rarity.RARE, mage.cards.r.RootboundCrag.class));
cards.add(new SetCardInfo("Rupture Spire", 319, Rarity.COMMON, mage.cards.r.RuptureSpire.class)); cards.add(new SetCardInfo("Rubblehulk", 219, Rarity.RARE, mage.cards.r.Rubblehulk.class));
cards.add(new SetCardInfo("Sakura-Tribe Elder", 164, Rarity.COMMON, mage.cards.s.SakuraTribeElder.class)); cards.add(new SetCardInfo("Rugged Highlands", 318, Rarity.COMMON, mage.cards.r.RuggedHighlands.class));
cards.add(new SetCardInfo("Sanctum Gargoyle", 76, Rarity.COMMON, mage.cards.s.SanctumGargoyle.class)); cards.add(new SetCardInfo("Rupture Spire", 319, Rarity.COMMON, mage.cards.r.RuptureSpire.class));
cards.add(new SetCardInfo("Sandsteppe Citadel", 320, Rarity.UNCOMMON, mage.cards.s.SandsteppeCitadel.class)); cards.add(new SetCardInfo("Sakura-Tribe Elder", 164, Rarity.COMMON, mage.cards.s.SakuraTribeElder.class));
cards.add(new SetCardInfo("Sangromancer", 116, Rarity.RARE, mage.cards.s.Sangromancer.class)); cards.add(new SetCardInfo("Sanctum Gargoyle", 76, Rarity.COMMON, mage.cards.s.SanctumGargoyle.class));
cards.add(new SetCardInfo("Satyr Wayfinder", 165, Rarity.COMMON, mage.cards.s.SatyrWayfinder.class)); cards.add(new SetCardInfo("Sandsteppe Citadel", 320, Rarity.UNCOMMON, mage.cards.s.SandsteppeCitadel.class));
cards.add(new SetCardInfo("Savage Lands", 321, Rarity.UNCOMMON, mage.cards.s.SavageLands.class)); cards.add(new SetCardInfo("Sangromancer", 116, Rarity.RARE, mage.cards.s.Sangromancer.class));
cards.add(new SetCardInfo("Scavenging Ooze", 166, Rarity.RARE, mage.cards.s.ScavengingOoze.class)); cards.add(new SetCardInfo("Satyr Wayfinder", 165, Rarity.COMMON, mage.cards.s.SatyrWayfinder.class));
cards.add(new SetCardInfo("Seaside Citadel", 322, Rarity.UNCOMMON, mage.cards.s.SeasideCitadel.class)); cards.add(new SetCardInfo("Savage Lands", 321, Rarity.UNCOMMON, mage.cards.s.SavageLands.class));
cards.add(new SetCardInfo("Seat of the Synod", 323, Rarity.COMMON, mage.cards.s.SeatOfTheSynod.class)); cards.add(new SetCardInfo("Scavenging Ooze", 166, Rarity.RARE, mage.cards.s.ScavengingOoze.class));
cards.add(new SetCardInfo("Seeds of Renewal", 24, Rarity.RARE, mage.cards.s.SeedsOfRenewal.class)); cards.add(new SetCardInfo("Seaside Citadel", 322, Rarity.UNCOMMON, mage.cards.s.SeasideCitadel.class));
cards.add(new SetCardInfo("Selesnya Guildmage", 235, Rarity.UNCOMMON, mage.cards.s.SelesnyaGuildmage.class)); cards.add(new SetCardInfo("Seat of the Synod", 323, Rarity.COMMON, mage.cards.s.SeatOfTheSynod.class));
cards.add(new SetCardInfo("Selesnya Sanctuary", 324, Rarity.UNCOMMON, mage.cards.s.SelesnyaSanctuary.class)); cards.add(new SetCardInfo("Seeds of Renewal", 24, Rarity.RARE, mage.cards.s.SeedsOfRenewal.class));
cards.add(new SetCardInfo("Selvala, Explorer Returned", 220, Rarity.RARE, mage.cards.s.SelvalaExplorerReturned.class)); cards.add(new SetCardInfo("Selesnya Guildmage", 235, Rarity.UNCOMMON, mage.cards.s.SelesnyaGuildmage.class));
cards.add(new SetCardInfo("Shadowblood Ridge", 325, Rarity.RARE, mage.cards.s.ShadowbloodRidge.class)); cards.add(new SetCardInfo("Selesnya Sanctuary", 324, Rarity.UNCOMMON, mage.cards.s.SelesnyaSanctuary.class));
cards.add(new SetCardInfo("Shamanic Revelation", 167, Rarity.RARE, mage.cards.s.ShamanicRevelation.class)); cards.add(new SetCardInfo("Selvala, Explorer Returned", 220, Rarity.RARE, mage.cards.s.SelvalaExplorerReturned.class));
cards.add(new SetCardInfo("Sharuum the Hegemon", 221, Rarity.MYTHIC, mage.cards.s.SharuumTheHegemon.class)); cards.add(new SetCardInfo("Shadowblood Ridge", 325, Rarity.RARE, mage.cards.s.ShadowbloodRidge.class));
cards.add(new SetCardInfo("Shimmer Myr", 269, Rarity.RARE, mage.cards.s.ShimmerMyr.class)); cards.add(new SetCardInfo("Shamanic Revelation", 167, Rarity.RARE, mage.cards.s.ShamanicRevelation.class));
cards.add(new SetCardInfo("Simic Growth Chamber", 326, Rarity.UNCOMMON, mage.cards.s.SimicGrowthChamber.class)); cards.add(new SetCardInfo("Sharuum the Hegemon", 221, Rarity.MYTHIC, mage.cards.s.SharuumTheHegemon.class));
cards.add(new SetCardInfo("Simic Signet", 270, Rarity.COMMON, mage.cards.s.SimicSignet.class)); cards.add(new SetCardInfo("Shimmer Myr", 269, Rarity.RARE, mage.cards.s.ShimmerMyr.class));
cards.add(new SetCardInfo("Skullclamp", 271, Rarity.UNCOMMON, mage.cards.s.Skullclamp.class)); cards.add(new SetCardInfo("Simic Growth Chamber", 326, Rarity.UNCOMMON, mage.cards.s.SimicGrowthChamber.class));
cards.add(new SetCardInfo("Slobad, Goblin Tinkerer", 133, Rarity.RARE, mage.cards.s.SlobadGoblinTinkerer.class)); cards.add(new SetCardInfo("Simic Signet", 270, Rarity.COMMON, mage.cards.s.SimicSignet.class));
cards.add(new SetCardInfo("Sol Ring", 272, Rarity.UNCOMMON, mage.cards.s.SolRing.class)); cards.add(new SetCardInfo("Skullclamp", 271, Rarity.UNCOMMON, mage.cards.s.Skullclamp.class));
cards.add(new SetCardInfo("Solemn Simulacrum", 273, Rarity.RARE, mage.cards.s.SolemnSimulacrum.class)); cards.add(new SetCardInfo("Slobad, Goblin Tinkerer", 133, Rarity.RARE, mage.cards.s.SlobadGoblinTinkerer.class));
cards.add(new SetCardInfo("Solidarity of Heroes", 168, Rarity.UNCOMMON, mage.cards.s.SolidarityOfHeroes.class)); cards.add(new SetCardInfo("Sol Ring", 272, Rarity.UNCOMMON, mage.cards.s.SolRing.class));
cards.add(new SetCardInfo("Soul of New Phyrexia", 274, Rarity.MYTHIC, mage.cards.s.SoulOfNewPhyrexia.class)); cards.add(new SetCardInfo("Solemn Simulacrum", 273, Rarity.RARE, mage.cards.s.SolemnSimulacrum.class));
cards.add(new SetCardInfo("Spellheart Chimera", 222, Rarity.UNCOMMON, mage.cards.s.SpellheartChimera.class)); cards.add(new SetCardInfo("Solidarity of Heroes", 168, Rarity.UNCOMMON, mage.cards.s.SolidarityOfHeroes.class));
cards.add(new SetCardInfo("Spelltwine", 97, Rarity.RARE, mage.cards.s.Spelltwine.class)); cards.add(new SetCardInfo("Soul of New Phyrexia", 274, Rarity.MYTHIC, mage.cards.s.SoulOfNewPhyrexia.class));
cards.add(new SetCardInfo("Sphere of Safety", 77, Rarity.UNCOMMON, mage.cards.s.SphereOfSafety.class)); cards.add(new SetCardInfo("Spellheart Chimera", 222, Rarity.UNCOMMON, mage.cards.s.SpellheartChimera.class));
cards.add(new SetCardInfo("Sphinx Summoner", 223, Rarity.RARE, mage.cards.s.SphinxSummoner.class)); cards.add(new SetCardInfo("Spelltwine", 97, Rarity.RARE, mage.cards.s.Spelltwine.class));
cards.add(new SetCardInfo("Spinerock Knoll", 327, Rarity.RARE, mage.cards.s.SpinerockKnoll.class)); cards.add(new SetCardInfo("Sphere of Safety", 77, Rarity.UNCOMMON, mage.cards.s.SphereOfSafety.class));
cards.add(new SetCardInfo("Spitting Image", 236, Rarity.RARE, mage.cards.s.SpittingImage.class)); cards.add(new SetCardInfo("Sphinx Summoner", 223, Rarity.RARE, mage.cards.s.SphinxSummoner.class));
cards.add(new SetCardInfo("Stalking Vengeance", 134, Rarity.RARE, mage.cards.s.StalkingVengeance.class)); cards.add(new SetCardInfo("Spinerock Knoll", 327, Rarity.RARE, mage.cards.s.SpinerockKnoll.class));
cards.add(new SetCardInfo("Sublime Exhalation", 5, Rarity.RARE, mage.cards.s.SublimeExhalation.class)); cards.add(new SetCardInfo("Spitting Image", 236, Rarity.RARE, mage.cards.s.SpittingImage.class));
cards.add(new SetCardInfo("Sunforger", 275, Rarity.RARE, mage.cards.s.Sunforger.class)); cards.add(new SetCardInfo("Stalking Vengeance", 134, Rarity.RARE, mage.cards.s.StalkingVengeance.class));
cards.add(new SetCardInfo("Sungrass Prairie", 328, Rarity.RARE, mage.cards.s.SungrassPrairie.class)); cards.add(new SetCardInfo("Sublime Exhalation", 5, Rarity.RARE, mage.cards.s.SublimeExhalation.class));
cards.add(new SetCardInfo("Sunpetal Grove", 329, Rarity.RARE, mage.cards.s.SunpetalGrove.class)); cards.add(new SetCardInfo("Sunforger", 275, Rarity.RARE, mage.cards.s.Sunforger.class));
cards.add(new SetCardInfo("Swamp", 343, Rarity.LAND, mage.cards.basiclands.Swamp.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Sungrass Prairie", 328, Rarity.RARE, mage.cards.s.SungrassPrairie.class));
cards.add(new SetCardInfo("Swamp", 344, Rarity.LAND, mage.cards.basiclands.Swamp.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Sunpetal Grove", 329, Rarity.RARE, mage.cards.s.SunpetalGrove.class));
cards.add(new SetCardInfo("Swamp", 345, Rarity.LAND, mage.cards.basiclands.Swamp.class, new CardGraphicInfo(null, true))); cards.add(new SetCardInfo("Swamp", 343, Rarity.LAND, mage.cards.basiclands.Swamp.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Swan Song", 98, Rarity.RARE, mage.cards.s.SwanSong.class)); cards.add(new SetCardInfo("Swamp", 344, Rarity.LAND, mage.cards.basiclands.Swamp.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Swiftfoot Boots", 276, Rarity.UNCOMMON, mage.cards.s.SwiftfootBoots.class)); cards.add(new SetCardInfo("Swamp", 345, Rarity.LAND, mage.cards.basiclands.Swamp.class, new CardGraphicInfo(null, true)));
cards.add(new SetCardInfo("Swiftwater Cliffs", 330, Rarity.COMMON, mage.cards.s.SwiftwaterCliffs.class)); cards.add(new SetCardInfo("Swan Song", 98, Rarity.RARE, mage.cards.s.SwanSong.class));
cards.add(new SetCardInfo("Swords to Plowshares", 78, Rarity.UNCOMMON, mage.cards.s.SwordsToPlowshares.class)); cards.add(new SetCardInfo("Swiftfoot Boots", 276, Rarity.UNCOMMON, mage.cards.s.SwiftfootBoots.class));
cards.add(new SetCardInfo("Sydri, Galvanic Genius", 224, Rarity.MYTHIC, mage.cards.s.SydriGalvanicGenius.class)); cards.add(new SetCardInfo("Swiftwater Cliffs", 330, Rarity.COMMON, mage.cards.s.SwiftwaterCliffs.class));
cards.add(new SetCardInfo("Sylvan Reclamation", 44, Rarity.UNCOMMON, mage.cards.s.SylvanReclamation.class)); cards.add(new SetCardInfo("Swords to Plowshares", 78, Rarity.UNCOMMON, mage.cards.s.SwordsToPlowshares.class));
cards.add(new SetCardInfo("Sylvok Explorer", 169, Rarity.COMMON, mage.cards.s.SylvokExplorer.class)); cards.add(new SetCardInfo("Sydri, Galvanic Genius", 224, Rarity.MYTHIC, mage.cards.s.SydriGalvanicGenius.class));
cards.add(new SetCardInfo("Taurean Mauler", 135, Rarity.RARE, mage.cards.t.TaureanMauler.class)); cards.add(new SetCardInfo("Sylvan Reclamation", 44, Rarity.UNCOMMON, mage.cards.s.SylvanReclamation.class));
cards.add(new SetCardInfo("Temple Bell", 277, Rarity.RARE, mage.cards.t.TempleBell.class)); cards.add(new SetCardInfo("Sylvok Explorer", 169, Rarity.COMMON, mage.cards.s.SylvokExplorer.class));
cards.add(new SetCardInfo("Temple of the False God", 331, Rarity.UNCOMMON, mage.cards.t.TempleOfTheFalseGod.class)); cards.add(new SetCardInfo("Taurean Mauler", 135, Rarity.RARE, mage.cards.t.TaureanMauler.class));
cards.add(new SetCardInfo("Tempt with Discovery", 170, Rarity.RARE, mage.cards.t.TemptWithDiscovery.class)); cards.add(new SetCardInfo("Temple Bell", 277, Rarity.RARE, mage.cards.t.TempleBell.class));
cards.add(new SetCardInfo("Terminate", 225, Rarity.COMMON, mage.cards.t.Terminate.class)); cards.add(new SetCardInfo("Temple of the False God", 331, Rarity.UNCOMMON, mage.cards.t.TempleOfTheFalseGod.class));
cards.add(new SetCardInfo("Terramorphic Expanse", 332, Rarity.COMMON, mage.cards.t.TerramorphicExpanse.class)); cards.add(new SetCardInfo("Tempt with Discovery", 170, Rarity.RARE, mage.cards.t.TemptWithDiscovery.class));
cards.add(new SetCardInfo("Tezzeret's Gambit", 99, Rarity.UNCOMMON, mage.cards.t.TezzeretsGambit.class)); cards.add(new SetCardInfo("Terminate", 225, Rarity.COMMON, mage.cards.t.Terminate.class));
cards.add(new SetCardInfo("Thelonite Hermit", 171, Rarity.RARE, mage.cards.t.TheloniteHermit.class)); cards.add(new SetCardInfo("Terramorphic Expanse", 332, Rarity.COMMON, mage.cards.t.TerramorphicExpanse.class));
cards.add(new SetCardInfo("Thopter Foundry", 237, Rarity.UNCOMMON, mage.cards.t.ThopterFoundry.class)); cards.add(new SetCardInfo("Tezzeret's Gambit", 99, Rarity.UNCOMMON, mage.cards.t.TezzeretsGambit.class));
cards.add(new SetCardInfo("Thornwood Falls", 333, Rarity.COMMON, mage.cards.t.ThornwoodFalls.class)); cards.add(new SetCardInfo("Thelonite Hermit", 171, Rarity.RARE, mage.cards.t.TheloniteHermit.class));
cards.add(new SetCardInfo("Thrummingbird", 100, Rarity.UNCOMMON, mage.cards.t.Thrummingbird.class)); cards.add(new SetCardInfo("Thopter Foundry", 237, Rarity.UNCOMMON, mage.cards.t.ThopterFoundry.class));
cards.add(new SetCardInfo("Thunderfoot Baloth", 172, Rarity.RARE, mage.cards.t.ThunderfootBaloth.class)); cards.add(new SetCardInfo("Thornwood Falls", 333, Rarity.COMMON, mage.cards.t.ThornwoodFalls.class));
cards.add(new SetCardInfo("Trading Post", 278, Rarity.RARE, mage.cards.t.TradingPost.class)); cards.add(new SetCardInfo("Thrummingbird", 100, Rarity.UNCOMMON, mage.cards.t.Thrummingbird.class));
cards.add(new SetCardInfo("Transguild Promenade", 334, Rarity.COMMON, mage.cards.t.TransguildPromenade.class)); cards.add(new SetCardInfo("Thunderfoot Baloth", 172, Rarity.RARE, mage.cards.t.ThunderfootBaloth.class));
cards.add(new SetCardInfo("Trash for Treasure", 136, Rarity.RARE, mage.cards.t.TrashForTreasure.class)); cards.add(new SetCardInfo("Trading Post", 278, Rarity.RARE, mage.cards.t.TradingPost.class));
cards.add(new SetCardInfo("Treasure Cruise", 101, Rarity.COMMON, mage.cards.t.TreasureCruise.class)); cards.add(new SetCardInfo("Transguild Promenade", 334, Rarity.COMMON, mage.cards.t.TransguildPromenade.class));
cards.add(new SetCardInfo("Trial // Error", 239, Rarity.UNCOMMON, mage.cards.t.TrialError.class)); cards.add(new SetCardInfo("Trash for Treasure", 136, Rarity.RARE, mage.cards.t.TrashForTreasure.class));
cards.add(new SetCardInfo("Trinket Mage", 102, Rarity.COMMON, mage.cards.t.TrinketMage.class)); cards.add(new SetCardInfo("Treacherous Terrain", 47, Rarity.UNCOMMON, mage.cards.t.TreacherousTerrain.class));
cards.add(new SetCardInfo("Tuskguard Captain", 173, Rarity.UNCOMMON, mage.cards.t.TuskguardCaptain.class)); cards.add(new SetCardInfo("Treasure Cruise", 101, Rarity.COMMON, mage.cards.t.TreasureCruise.class));
cards.add(new SetCardInfo("Underground River", 335, Rarity.RARE, mage.cards.u.UndergroundRiver.class)); cards.add(new SetCardInfo("Trial // Error", 239, Rarity.UNCOMMON, mage.cards.t.TrialError.class));
cards.add(new SetCardInfo("Utter End", 226, Rarity.RARE, mage.cards.u.UtterEnd.class)); cards.add(new SetCardInfo("Trinket Mage", 102, Rarity.COMMON, mage.cards.t.TrinketMage.class));
cards.add(new SetCardInfo("Vedalken Engineer", 103, Rarity.COMMON, mage.cards.v.VedalkenEngineer.class)); cards.add(new SetCardInfo("Tuskguard Captain", 173, Rarity.UNCOMMON, mage.cards.t.TuskguardCaptain.class));
cards.add(new SetCardInfo("Venser's Journal", 279, Rarity.RARE, mage.cards.v.VensersJournal.class)); cards.add(new SetCardInfo("Underground River", 335, Rarity.RARE, mage.cards.u.UndergroundRiver.class));
cards.add(new SetCardInfo("Veteran Explorer", 174, Rarity.UNCOMMON, mage.cards.v.VeteranExplorer.class)); cards.add(new SetCardInfo("Utter End", 226, Rarity.RARE, mage.cards.u.UtterEnd.class));
cards.add(new SetCardInfo("Vial Smasher the Fierce", 49, Rarity.MYTHIC, mage.cards.v.VialSmasherTheFierce.class)); cards.add(new SetCardInfo("Vedalken Engineer", 103, Rarity.COMMON, mage.cards.v.VedalkenEngineer.class));
cards.add(new SetCardInfo("Volcanic Vision", 137, Rarity.RARE, mage.cards.v.VolcanicVision.class)); cards.add(new SetCardInfo("Venser's Journal", 279, Rarity.RARE, mage.cards.v.VensersJournal.class));
cards.add(new SetCardInfo("Vorel of the Hull Clade", 227, Rarity.RARE, mage.cards.v.VorelOfTheHullClade.class)); cards.add(new SetCardInfo("Veteran Explorer", 174, Rarity.UNCOMMON, mage.cards.v.VeteranExplorer.class));
cards.add(new SetCardInfo("Vulturous Zombie", 228, Rarity.RARE, mage.cards.v.VulturousZombie.class)); cards.add(new SetCardInfo("Vial Smasher the Fierce", 49, Rarity.MYTHIC, mage.cards.v.VialSmasherTheFierce.class));
cards.add(new SetCardInfo("Wall of Blossoms", 175, Rarity.UNCOMMON, mage.cards.w.WallOfBlossoms.class)); cards.add(new SetCardInfo("Volcanic Vision", 137, Rarity.RARE, mage.cards.v.VolcanicVision.class));
cards.add(new SetCardInfo("Waste Not", 117, Rarity.RARE, mage.cards.w.WasteNot.class)); cards.add(new SetCardInfo("Vorel of the Hull Clade", 227, Rarity.RARE, mage.cards.v.VorelOfTheHullClade.class));
cards.add(new SetCardInfo("Wave of Reckoning", 79, Rarity.RARE, mage.cards.w.WaveOfReckoning.class)); cards.add(new SetCardInfo("Vulturous Zombie", 228, Rarity.RARE, mage.cards.v.VulturousZombie.class));
cards.add(new SetCardInfo("Wheel of Fate", 138, Rarity.RARE, mage.cards.w.WheelOfFate.class)); cards.add(new SetCardInfo("Wall of Blossoms", 175, Rarity.UNCOMMON, mage.cards.w.WallOfBlossoms.class));
cards.add(new SetCardInfo("Whims of the Fates", 139, Rarity.RARE, mage.cards.w.WhimsOfTheFates.class)); cards.add(new SetCardInfo("Waste Not", 117, Rarity.RARE, mage.cards.w.WasteNot.class));
cards.add(new SetCardInfo("Whipflare", 140, Rarity.UNCOMMON, mage.cards.w.Whipflare.class)); cards.add(new SetCardInfo("Wave of Reckoning", 79, Rarity.RARE, mage.cards.w.WaveOfReckoning.class));
cards.add(new SetCardInfo("Whispering Madness", 229, Rarity.RARE, mage.cards.w.WhisperingMadness.class)); cards.add(new SetCardInfo("Wheel of Fate", 138, Rarity.RARE, mage.cards.w.WheelOfFate.class));
cards.add(new SetCardInfo("Whispersilk Cloak", 280, Rarity.UNCOMMON, mage.cards.w.WhispersilkCloak.class)); cards.add(new SetCardInfo("Whims of the Fates", 139, Rarity.RARE, mage.cards.w.WhimsOfTheFates.class));
cards.add(new SetCardInfo("Wight of Precinct Six", 118, Rarity.UNCOMMON, mage.cards.w.WightOfPrecinctSix.class)); cards.add(new SetCardInfo("Whipflare", 140, Rarity.UNCOMMON, mage.cards.w.Whipflare.class));
cards.add(new SetCardInfo("Wild Beastmaster", 176, Rarity.RARE, mage.cards.w.WildBeastmaster.class)); cards.add(new SetCardInfo("Whispering Madness", 229, Rarity.RARE, mage.cards.w.WhisperingMadness.class));
cards.add(new SetCardInfo("Wilderness Elemental", 230, Rarity.UNCOMMON, mage.cards.w.WildernessElemental.class)); cards.add(new SetCardInfo("Whispersilk Cloak", 280, Rarity.UNCOMMON, mage.cards.w.WhispersilkCloak.class));
cards.add(new SetCardInfo("Windborn Muse", 80, Rarity.RARE, mage.cards.w.WindbornMuse.class)); cards.add(new SetCardInfo("Wight of Precinct Six", 118, Rarity.UNCOMMON, mage.cards.w.WightOfPrecinctSix.class));
cards.add(new SetCardInfo("Windbrisk Heights", 336, Rarity.RARE, mage.cards.w.WindbriskHeights.class)); cards.add(new SetCardInfo("Wild Beastmaster", 176, Rarity.RARE, mage.cards.w.WildBeastmaster.class));
cards.add(new SetCardInfo("Windfall", 104, Rarity.UNCOMMON, mage.cards.w.Windfall.class)); cards.add(new SetCardInfo("Wilderness Elemental", 230, Rarity.UNCOMMON, mage.cards.w.WildernessElemental.class));
cards.add(new SetCardInfo("Worm Harvest", 238, Rarity.RARE, mage.cards.w.WormHarvest.class)); cards.add(new SetCardInfo("Windborn Muse", 80, Rarity.RARE, mage.cards.w.WindbornMuse.class));
cards.add(new SetCardInfo("Zedruu the Greathearted", 231, Rarity.MYTHIC, mage.cards.z.ZedruuTheGreathearted.class)); cards.add(new SetCardInfo("Windbrisk Heights", 336, Rarity.RARE, mage.cards.w.WindbriskHeights.class));
cards.add(new SetCardInfo("Zhur-Taa Druid", 232, Rarity.COMMON, mage.cards.z.ZhurTaaDruid.class)); cards.add(new SetCardInfo("Windfall", 104, Rarity.UNCOMMON, mage.cards.w.Windfall.class));
} cards.add(new SetCardInfo("Worm Harvest", 238, Rarity.RARE, mage.cards.w.WormHarvest.class));
cards.add(new SetCardInfo("Zedruu the Greathearted", 231, Rarity.MYTHIC, mage.cards.z.ZedruuTheGreathearted.class));
} cards.add(new SetCardInfo("Zhur-Taa Druid", 232, Rarity.COMMON, mage.cards.z.ZhurTaaDruid.class));
}
}

View file

@ -1868,13 +1868,13 @@ public class TestPlayer implements Player {
} }
@Override @Override
public void setCommanderId(UUID commanderId) { public void addCommanderId(UUID commanderId) {
computerPlayer.setCommanderId(commanderId); computerPlayer.addCommanderId(commanderId);
} }
@Override @Override
public UUID getCommanderId() { public Set<UUID> getCommandersIds() {
return computerPlayer.getCommanderId(); return computerPlayer.getCommandersIds();
} }
@Override @Override

View file

@ -1083,12 +1083,12 @@ public class PlayerStub implements Player {
} }
@Override @Override
public void setCommanderId(UUID commanderId) { public void addCommanderId(UUID commanderId) {
} }
@Override @Override
public UUID getCommanderId() { public Set<UUID> getCommandersIds() {
return null; return null;
} }

View file

@ -31,12 +31,9 @@ import java.io.Serializable;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import mage.util.Copyable; import mage.util.Copyable;
import mage.util.ThreadLocalStringBuilder;
public class ObjectColor implements Serializable, Copyable<ObjectColor>, Comparable<ObjectColor> { public class ObjectColor implements Serializable, Copyable<ObjectColor>, Comparable<ObjectColor> {
private static final ThreadLocalStringBuilder threadLocalBuilder = new ThreadLocalStringBuilder(10);
public static final ObjectColor WHITE = new ObjectColor("W"); public static final ObjectColor WHITE = new ObjectColor("W");
public static final ObjectColor BLUE = new ObjectColor("U"); public static final ObjectColor BLUE = new ObjectColor("U");
public static final ObjectColor BLACK = new ObjectColor("B"); public static final ObjectColor BLACK = new ObjectColor("B");
@ -231,7 +228,7 @@ public class ObjectColor implements Serializable, Copyable<ObjectColor>, Compara
@Override @Override
public String toString() { public String toString() {
StringBuilder sb = threadLocalBuilder.get(); StringBuilder sb = new StringBuilder(5);
if (white) { if (white) {
sb.append("W"); sb.append("W");
} }

View file

@ -27,6 +27,7 @@
*/ */
package mage.abilities.condition.common; package mage.abilities.condition.common;
import java.util.UUID;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.condition.Condition; import mage.abilities.condition.Condition;
import mage.game.Game; import mage.game.Game;
@ -56,8 +57,12 @@ public class CommanderInPlayCondition implements Condition {
public boolean apply(Game game, Ability source) { public boolean apply(Game game, Ability source) {
Player controller = game.getPlayer(source.getControllerId()); Player controller = game.getPlayer(source.getControllerId());
if (controller != null) { if (controller != null) {
Permanent commander = game.getPermanent(controller.getCommanderId()); for (UUID commanderId : controller.getCommandersIds()) {
return commander != null && commander.getControllerId().equals(source.getControllerId()); Permanent commander = game.getPermanent(commanderId);
if (commander != null && commander.getControllerId().equals(source.getControllerId())) {
return true;
}
}
} }
return false; return false;
} }

View file

@ -28,6 +28,7 @@
package mage.abilities.mana; package mage.abilities.mana;
import java.util.List; import java.util.List;
import java.util.UUID;
import mage.Mana; import mage.Mana;
import mage.abilities.Ability; import mage.abilities.Ability;
import mage.abilities.costs.Cost; import mage.abilities.costs.Cost;
@ -49,20 +50,16 @@ import mage.util.CardUtil;
*/ */
public class CommanderColorIdentityManaAbility extends ManaAbility { public class CommanderColorIdentityManaAbility extends ManaAbility {
private FilterMana commanderMana;
public CommanderColorIdentityManaAbility() { public CommanderColorIdentityManaAbility() {
super(Zone.BATTLEFIELD, new CommanderIdentityManaEffect(), new TapSourceCost()); super(Zone.BATTLEFIELD, new CommanderIdentityManaEffect(), new TapSourceCost());
} }
public CommanderColorIdentityManaAbility(Cost cost) { public CommanderColorIdentityManaAbility(Cost cost) {
super(Zone.BATTLEFIELD, new CommanderIdentityManaEffect(), cost); super(Zone.BATTLEFIELD, new CommanderIdentityManaEffect(), cost);
commanderMana = null;
} }
public CommanderColorIdentityManaAbility(final CommanderColorIdentityManaAbility ability) { public CommanderColorIdentityManaAbility(final CommanderColorIdentityManaAbility ability) {
super(ability); super(ability);
this.commanderMana = ability.commanderMana;
} }
@Override @Override
@ -75,30 +72,27 @@ public class CommanderColorIdentityManaAbility extends ManaAbility {
if (netMana.isEmpty() && game != null) { if (netMana.isEmpty() && game != null) {
Player controller = game.getPlayer(getControllerId()); Player controller = game.getPlayer(getControllerId());
if (controller != null) { if (controller != null) {
if (commanderMana == null) { for (UUID commanderId : controller.getCommandersIds()) {
Card commander = game.getCard(controller.getCommanderId()); Card commander = game.getCard(commanderId);
if (commander != null) { if (commander != null) {
commanderMana = CardUtil.getColorIdentity(commander); FilterMana commanderMana = CardUtil.getColorIdentity(commander);
} else { if (commanderMana.isBlack()) {
// In formats other than Commander, Command Tower's ability produces no mana. netMana.add(new Mana(ColoredManaSymbol.B));
commanderMana = new FilterMana(); }
if (commanderMana.isBlue()) {
netMana.add(new Mana(ColoredManaSymbol.U));
}
if (commanderMana.isGreen()) {
netMana.add(new Mana(ColoredManaSymbol.G));
}
if (commanderMana.isRed()) {
netMana.add(new Mana(ColoredManaSymbol.R));
}
if (commanderMana.isWhite()) {
netMana.add(new Mana(ColoredManaSymbol.W));
}
} }
} }
if (commanderMana.isBlack()) {
netMana.add(new Mana(ColoredManaSymbol.B));
}
if (commanderMana.isBlue()) {
netMana.add(new Mana(ColoredManaSymbol.U));
}
if (commanderMana.isGreen()) {
netMana.add(new Mana(ColoredManaSymbol.G));
}
if (commanderMana.isRed()) {
netMana.add(new Mana(ColoredManaSymbol.R));
}
if (commanderMana.isWhite()) {
netMana.add(new Mana(ColoredManaSymbol.W));
}
} }
} }
return netMana; return netMana;
@ -113,17 +107,13 @@ public class CommanderColorIdentityManaAbility extends ManaAbility {
class CommanderIdentityManaEffect extends ManaEffect { class CommanderIdentityManaEffect extends ManaEffect {
private FilterMana commanderMana;
public CommanderIdentityManaEffect() { public CommanderIdentityManaEffect() {
super(); super();
this.staticText = "Add to your mana pool one mana of any color in your commander's color identity"; this.staticText = "Add to your mana pool one mana of any color in your commander's color identity";
commanderMana = null;
} }
public CommanderIdentityManaEffect(final CommanderIdentityManaEffect effect) { public CommanderIdentityManaEffect(final CommanderIdentityManaEffect effect) {
super(effect); super(effect);
this.commanderMana = effect.commanderMana;
} }
@Override @Override
@ -135,31 +125,28 @@ class CommanderIdentityManaEffect extends ManaEffect {
public boolean apply(Game game, Ability source) { public boolean apply(Game game, Ability source) {
Player controller = game.getPlayer(source.getControllerId()); Player controller = game.getPlayer(source.getControllerId());
if (controller != null) { if (controller != null) {
if (commanderMana == null) {
Card commander = game.getCard(controller.getCommanderId());
if (commander != null) {
commanderMana = CardUtil.getColorIdentity(commander);
} else {
// In formats other than Commander, Command Tower's ability produces no mana.
commanderMana = new FilterMana();
}
}
Choice choice = new ChoiceImpl(); Choice choice = new ChoiceImpl();
choice.setMessage("Pick a mana color"); choice.setMessage("Pick a mana color");
if (commanderMana.isBlack()) { for (UUID commanderId : controller.getCommandersIds()) {
choice.getChoices().add("Black"); Card commander = game.getCard(commanderId);
} if (commander != null) {
if (commanderMana.isRed()) { FilterMana commanderMana = CardUtil.getColorIdentity(commander);
choice.getChoices().add("Red"); if (commanderMana.isWhite()) {
} choice.getChoices().add("White");
if (commanderMana.isBlue()) { }
choice.getChoices().add("Blue"); if (commanderMana.isBlue()) {
} choice.getChoices().add("Blue");
if (commanderMana.isGreen()) { }
choice.getChoices().add("Green"); if (commanderMana.isBlack()) {
} choice.getChoices().add("Black");
if (commanderMana.isWhite()) { }
choice.getChoices().add("White"); if (commanderMana.isRed()) {
choice.getChoices().add("Red");
}
if (commanderMana.isGreen()) {
choice.getChoices().add("Green");
}
}
} }
if (choice.getChoices().size() > 0) { if (choice.getChoices().size() > 0) {
if (choice.getChoices().size() == 1) { if (choice.getChoices().size() == 1) {

View file

@ -22,7 +22,7 @@ public class CommanderPredicate implements Predicate<Permanent> {
Player owner = game.getPlayer(input.getOwnerId()); Player owner = game.getPlayer(input.getOwnerId());
return input.getCardType().contains(CardType.CREATURE) return input.getCardType().contains(CardType.CREATURE)
&& owner != null && owner != null
&& input.getId().equals(owner.getCommanderId()); && input.getId().equals(owner.getCommandersIds());
} }
@Override @Override

View file

@ -76,16 +76,14 @@ public abstract class GameCommanderImpl extends GameImpl {
for (UUID playerId : state.getPlayerList(startingPlayerId)) { for (UUID playerId : state.getPlayerList(startingPlayerId)) {
Player player = getPlayer(playerId); Player player = getPlayer(playerId);
if (player != null) { if (player != null) {
if (player.getSideboard().size() > 0) { while (player.getSideboard().size() > 0) {
Card commander = getCard((UUID) player.getSideboard().toArray()[0]); Card commander = this.getCard(player.getSideboard().iterator().next());
if (commander != null) { if (commander != null) {
player.setCommanderId(commander.getId()); player.addCommanderId(commander.getId());
commander.moveToZone(Zone.COMMAND, null, this, true); commander.moveToZone(Zone.COMMAND, null, this, true);
commander.getAbilities().setControllerId(player.getId()); commander.getAbilities().setControllerId(player.getId());
ability.addEffect(new CommanderReplacementEffect(commander.getId(), alsoHand, alsoLibrary)); ability.addEffect(new CommanderReplacementEffect(commander.getId(), alsoHand, alsoLibrary));
ability.addEffect(new CommanderCostModification(commander.getId())); ability.addEffect(new CommanderCostModification(commander.getId()));
// Commander rule #4 was removed Jan. 18, 2016
// ability.addEffect(new CommanderManaReplacementEffect(player.getId(), CardUtil.getColorIdentity(commander)));
getState().setValue(commander.getId() + "_castCount", 0); getState().setValue(commander.getId() + "_castCount", 0);
CommanderInfoWatcher watcher = new CommanderInfoWatcher(commander.getId(), CHECK_COMMANDER_DAMAGE); CommanderInfoWatcher watcher = new CommanderInfoWatcher(commander.getId(), CHECK_COMMANDER_DAMAGE);
getState().getWatchers().add(watcher); getState().getWatchers().add(watcher);
@ -93,7 +91,6 @@ public abstract class GameCommanderImpl extends GameImpl {
} }
} }
} }
} }
this.getState().addAbility(ability, null); this.getState().addAbility(ability, null);
super.init(choosingPlayerId); super.init(choosingPlayerId);
@ -189,15 +186,17 @@ public abstract class GameCommanderImpl extends GameImpl {
@Override @Override
protected boolean checkStateBasedActions() { protected boolean checkStateBasedActions() {
for (Player player : getPlayers().values()) { for (Player player : getPlayers().values()) {
CommanderInfoWatcher damageWatcher = (CommanderInfoWatcher) getState().getWatchers().get("CommanderCombatDamageWatcher", player.getCommanderId()); for (UUID commanderId : player.getCommandersIds()) {
if (damageWatcher == null) { CommanderInfoWatcher damageWatcher = (CommanderInfoWatcher) getState().getWatchers().get("CommanderCombatDamageWatcher", commanderId);
continue; if (damageWatcher == null) {
} continue;
for (Map.Entry<UUID, Integer> entrySet : damageWatcher.getDamageToPlayer().entrySet()) { }
if (entrySet.getValue() > 20) { for (Map.Entry<UUID, Integer> entrySet : damageWatcher.getDamageToPlayer().entrySet()) {
Player opponent = getPlayer(entrySet.getKey()); if (entrySet.getValue() > 20) {
if (opponent != null && !opponent.hasLost() && player.isInGame()) { Player opponent = getPlayer(entrySet.getKey());
opponent.lost(this); if (opponent != null && !opponent.hasLost() && player.isInGame()) {
opponent.lost(this);
}
} }
} }
} }

View file

@ -83,7 +83,7 @@ public abstract class GameTinyLeadersImpl extends GameImpl {
Set<Card> cards = new HashSet<>(); Set<Card> cards = new HashSet<>();
cards.add(commander); cards.add(commander);
this.loadCards(cards, playerId); this.loadCards(cards, playerId);
player.setCommanderId(commander.getId()); player.addCommanderId(commander.getId());
commander.moveToZone(Zone.COMMAND, null, this, true); commander.moveToZone(Zone.COMMAND, null, this, true);
ability.addEffect(new CommanderReplacementEffect(commander.getId(), alsoHand, alsoLibrary)); ability.addEffect(new CommanderReplacementEffect(commander.getId(), alsoHand, alsoLibrary));
ability.addEffect(new CommanderCostModification(commander.getId())); ability.addEffect(new CommanderCostModification(commander.getId()));

View file

@ -161,9 +161,6 @@ public interface Permanent extends Card, Controllable {
String getValue(GameState state); String getValue(GameState state);
@Deprecated
void addAbility(Ability ability);
@Deprecated @Deprecated
void addAbility(Ability ability, Game game); void addAbility(Ability ability, Game game);

View file

@ -265,12 +265,6 @@ public abstract class PermanentImpl extends CardImpl implements Permanent {
return abilities; return abilities;
} }
@Override
@Deprecated
public void addAbility(Ability ability) {
throw new UnsupportedOperationException("Unsupported operation: use addAbility(Ability ability, Game game) instead");
}
/** /**
* *
* @param ability * @param ability

View file

@ -645,16 +645,16 @@ public interface Player extends MageItem, Copyable<Player> {
/** /**
* Set the commanderId of the player * Set the commanderId of the player
* *
* @param commanderId * @param commandersIds
*/ */
void setCommanderId(UUID commanderId); void addCommanderId(UUID commanderId);
/** /**
* Get the commanderId of the player * Get the commanderId of the player
* *
* @return * @return
*/ */
UUID getCommanderId(); Set<UUID> getCommandersIds();
/** /**
* Moves cards from one zone to another * Moves cards from one zone to another

View file

@ -105,7 +105,12 @@ import mage.filter.common.FilterCreatureForCombat;
import mage.filter.common.FilterCreatureForCombatBlock; import mage.filter.common.FilterCreatureForCombatBlock;
import mage.filter.predicate.Predicates; import mage.filter.predicate.Predicates;
import mage.filter.predicate.permanent.PermanentIdPredicate; import mage.filter.predicate.permanent.PermanentIdPredicate;
import mage.game.*; import mage.game.ExileZone;
import mage.game.Game;
import mage.game.Graveyard;
import mage.game.Table;
import mage.game.ZoneChangeInfo;
import mage.game.ZonesHandler;
import mage.game.combat.CombatGroup; import mage.game.combat.CombatGroup;
import mage.game.command.CommandObject; import mage.game.command.CommandObject;
import mage.game.events.DamagePlayerEvent; import mage.game.events.DamagePlayerEvent;
@ -153,7 +158,7 @@ public abstract class PlayerImpl implements Player, Serializable {
protected Cards sideboard; protected Cards sideboard;
protected Cards hand; protected Cards hand;
protected Graveyard graveyard; protected Graveyard graveyard;
protected UUID commanderId; protected Set<UUID> commandersIds = new HashSet<>(0);
protected Abilities<Ability> abilities; protected Abilities<Ability> abilities;
protected Counters counters; protected Counters counters;
protected int landsPlayed; protected int landsPlayed;
@ -273,7 +278,7 @@ public abstract class PlayerImpl implements Player, Serializable {
this.sideboard = player.sideboard.copy(); this.sideboard = player.sideboard.copy();
this.hand = player.hand.copy(); this.hand = player.hand.copy();
this.graveyard = player.graveyard.copy(); this.graveyard = player.graveyard.copy();
this.commanderId = player.commanderId; this.commandersIds = player.commandersIds;
this.abilities = player.abilities.copy(); this.abilities = player.abilities.copy();
this.counters = player.counters.copy(); this.counters = player.counters.copy();
@ -359,7 +364,7 @@ public abstract class PlayerImpl implements Player, Serializable {
this.sideboard = player.getSideboard().copy(); this.sideboard = player.getSideboard().copy();
this.hand = player.getHand().copy(); this.hand = player.getHand().copy();
this.graveyard = player.getGraveyard().copy(); this.graveyard = player.getGraveyard().copy();
this.commanderId = player.getCommanderId(); this.commandersIds = player.getCommandersIds();
this.abilities = player.getAbilities().copy(); this.abilities = player.getAbilities().copy();
this.counters = player.getCounters().copy(); this.counters = player.getCounters().copy();
@ -3124,13 +3129,13 @@ public abstract class PlayerImpl implements Player, Serializable {
} }
@Override @Override
public void setCommanderId(UUID commanderId) { public void addCommanderId(UUID commanderId) {
this.commanderId = commanderId; this.commandersIds.add(commanderId);
} }
@Override @Override
public UUID getCommanderId() { public Set<UUID> getCommandersIds() {
return this.commanderId; return this.commandersIds;
} }
@Override @Override