[refactor] moved enums from Constants class

This commit is contained in:
North 2013-06-16 12:28:10 +03:00
parent 4d16535709
commit 0bb110be45
7372 changed files with 28700 additions and 27583 deletions

View file

@ -34,7 +34,7 @@
package mage.client.cards;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.cards.CardDimensions;
import mage.cards.MagePermanent;
import mage.cards.TextPopup;
@ -264,7 +264,7 @@ public class Card extends MagePermanent implements MouseMotionListener, MouseLis
sbType.append(superType).append(" ");
}
for (mage.Constants.CardType cardType: card.getCardTypes()) {
for (CardType cardType: card.getCardTypes()) {
sbType.append(cardType.toString()).append(" ");
}

View file

@ -47,7 +47,7 @@ import java.util.List;
import java.util.UUID;
import javax.swing.*;
import javax.swing.table.DefaultTableCellRenderer;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.cards.MageCard;
import mage.client.constants.Constants.SortBy;
import mage.client.deckeditor.table.TableModel;

View file

@ -51,7 +51,7 @@ import java.util.UUID;
import javax.swing.PopupFactory;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.cards.CardDimensions;
import mage.cards.MagePermanent;
import mage.client.util.Config;

View file

@ -1,7 +1,7 @@
package mage.client.deck.generator;
import mage.Constants.CardType;
import mage.Constants.ColoredManaSymbol;
import mage.constants.CardType;
import mage.constants.ColoredManaSymbol;
import mage.Mana;
import mage.cards.Card;
import mage.cards.decks.Deck;
@ -11,6 +11,7 @@ import mage.cards.repository.CardRepository;
import mage.client.MageFrame;
import mage.client.util.gui.ColorsChooser;
import mage.client.util.sets.ConstructedFormats;
import mage.constants.Rarity;
import mage.interfaces.rate.RateCallback;
import mage.cards.Sets;
import mage.utils.DeckBuilder;
@ -26,7 +27,7 @@ import java.util.LinkedList;
import java.util.List;
import java.util.Random;
import java.util.UUID;
import mage.Constants;
import mage.cards.ExpansionSet;
/**
@ -369,7 +370,7 @@ public class DeckGenerator {
if (!landSets.isEmpty()) {
criteria.setCodes(landSets.toArray(new String[landSets.size()]));
}
criteria.rarities(Constants.Rarity.LAND).name(cardName);
criteria.rarities(Rarity.LAND).name(cardName);
List<CardInfo> cards = CardRepository.instance.findCards(criteria);
if (cards.isEmpty() && !setsToUse.isEmpty()) {

View file

@ -34,7 +34,7 @@
package mage.client.deckeditor;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.MageObject;
import mage.ObjectColor;
import mage.cards.Card;

View file

@ -45,6 +45,7 @@ import mage.client.util.Config;
import mage.client.util.ImageHelper;
import mage.client.util.sets.ConstructedFormats;
import mage.components.ImagePanel;
import mage.constants.Rarity;
import mage.view.CardView;
import org.apache.log4j.Logger;
import org.mage.card.arcane.GlowText;
@ -254,7 +255,7 @@ public class MageBook extends JComponent {
cardImg.update(card);
cardImg.setCardBounds(rectangle.x, rectangle.y, cardDimensions.frameWidth, cardDimensions.frameHeight);
boolean implemented = !card.getRarity().equals(mage.Constants.Rarity.NA);
boolean implemented = !card.getRarity().equals(Rarity.NA);
GlowText label = new GlowText();
label.setGlow(implemented ? Color.green : NOT_IMPLEMENTED, 12, 0.0f);

View file

@ -28,7 +28,7 @@
package mage.client.deckeditor.table;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.cards.MageCard;
import mage.view.CardView;

View file

@ -28,7 +28,6 @@
package mage.client.deckeditor.table;
import mage.Constants;
import mage.client.MageFrame;
import mage.client.cards.BigCard;
import mage.client.cards.CardEventSource;
@ -40,6 +39,7 @@ import mage.client.util.Event;
import mage.client.util.ImageHelper;
import mage.client.util.Listener;
import mage.client.util.gui.GuiDisplayUtil;
import mage.constants.CardType;
import mage.view.CardView;
import mage.view.CardsView;
import org.apache.log4j.Logger;
@ -93,9 +93,9 @@ public class TableModel extends AbstractTableModel implements ICardGrid {
addCard(card, bigCard, gameId);
}
if (updateCountsCallback != null) {
if (card.getCardTypes().contains(Constants.CardType.LAND))
if (card.getCardTypes().contains(CardType.LAND))
landCount++;
if (card.getCardTypes().contains(Constants.CardType.CREATURE))
if (card.getCardTypes().contains(CardType.CREATURE))
creatureCount++;
}
}

View file

@ -38,7 +38,7 @@ import java.util.List;
import java.util.Random;
import java.util.Set;
import javax.swing.JLayeredPane;
import mage.Constants;
import mage.cards.Card;
import mage.cards.Sets;
import mage.cards.decks.Deck;
@ -46,6 +46,7 @@ import mage.cards.repository.CardCriteria;
import mage.cards.repository.CardInfo;
import mage.cards.repository.CardRepository;
import mage.client.MageFrame;
import mage.constants.Rarity;
/**
*
@ -76,7 +77,7 @@ public class AddLandDialog extends MageDialog {
if (!setCodesland.isEmpty()) {
criteria.setCodes(setCodesland.toArray(new String[setCodesland.size()]));
}
criteria.rarities(Constants.Rarity.LAND).name(landName);
criteria.rarities(Rarity.LAND).name(landName);
List<CardInfo> cards = CardRepository.instance.findCards(criteria);
if (cards.isEmpty()) {
return;

View file

@ -34,8 +34,8 @@ import java.util.ArrayList;
import java.util.List;
import java.util.UUID;
import javax.swing.*;
import mage.Constants.MultiplayerAttackOption;
import mage.Constants.RangeOfInfluence;
import mage.constants.MultiplayerAttackOption;
import mage.constants.RangeOfInfluence;
import mage.cards.decks.importer.DeckImporterUtil;
import mage.client.MageFrame;
import mage.client.components.MageComponents;

View file

@ -41,8 +41,8 @@ import javax.swing.DefaultComboBoxModel;
import javax.swing.JComboBox;
import javax.swing.JOptionPane;
import javax.swing.SpinnerNumberModel;
import mage.Constants.MultiplayerAttackOption;
import mage.Constants.RangeOfInfluence;
import mage.constants.MultiplayerAttackOption;
import mage.constants.RangeOfInfluence;
import mage.cards.ExpansionSet;
import mage.cards.Sets;
import mage.client.MageFrame;

View file

@ -34,13 +34,13 @@
package mage.client.game;
import mage.Constants;
import mage.cards.MagePermanent;
import mage.client.cards.BigCard;
import mage.client.cards.Permanent;
import mage.client.plugins.impl.Plugins;
import mage.client.util.AudioManager;
import mage.client.util.Config;
import mage.constants.CardType;
import mage.view.PermanentView;
import javax.swing.*;
@ -209,9 +209,9 @@ public class BattlefieldPanel extends javax.swing.JLayeredPane {
}*/
}
if (permanent.getCardTypes().contains(Constants.CardType.ARTIFACT)) {
if (permanent.getCardTypes().contains(CardType.ARTIFACT)) {
addedArtifact = true;
} else if (permanent.getCardTypes().contains(Constants.CardType.CREATURE)) {
} else if (permanent.getCardTypes().contains(CardType.CREATURE)) {
addedCreature = true;
} else {
addedPermanent = true;
@ -274,7 +274,7 @@ public class BattlefieldPanel extends javax.swing.JLayeredPane {
});
t.start();
}
if (((MagePermanent)comp).getOriginal().getCardTypes().contains(Constants.CardType.CREATURE)) {
if (((MagePermanent)comp).getOriginal().getCardTypes().contains(CardType.CREATURE)) {
removedCreature = true;
}
}

View file

@ -27,7 +27,6 @@
*/
package mage.client.game;
import mage.Constants;
import mage.cards.action.ActionCallback;
import mage.client.MageFrame;
import mage.client.cards.BigCard;
@ -45,6 +44,7 @@ import mage.client.util.Config;
import mage.client.util.GameManager;
import mage.client.util.PhaseManager;
import mage.client.util.gui.ArrowBuilder;
import mage.constants.PhaseStep;
import mage.remote.Session;
import mage.view.*;
import org.apache.log4j.Logger;
@ -504,7 +504,7 @@ public final class GamePanel extends javax.swing.JPanel {
/**
* Update phase buttons\labels.
*/
private void updatePhases(Constants.PhaseStep step) {
private void updatePhases(PhaseStep step) {
if (step == null) {
logger.warn("step is null");
return;

View file

@ -1,10 +1,10 @@
package mage.client.game;
import mage.Constants;
import mage.client.MageFrame;
import mage.client.cards.BigCard;
import mage.client.dialog.PreferencesDialog;
import mage.client.util.Config;
import mage.constants.Zone;
import mage.view.SimpleCardsView;
import javax.swing.*;
@ -55,7 +55,7 @@ public class HandPanel extends JPanel {
hand.setBackgroundColor(new Color(0, 0, 0, 100));
hand.setVisibleIfEmpty(false);
hand.setBorder(emptyBorder);
hand.setZone(Constants.Zone.HAND.toString());
hand.setZone(Zone.HAND.toString());
}
public void loadCards(SimpleCardsView cards, BigCard bigCard, UUID gameId) {

View file

@ -1,6 +1,5 @@
package mage.client.plugins.adapters;
import mage.Constants;
import mage.cards.MageCard;
import mage.cards.MagePermanent;
import mage.cards.action.ActionCallback;
@ -17,6 +16,7 @@ import mage.client.util.ImageHelper;
import mage.client.util.gui.ArrowBuilder;
import mage.client.util.gui.GuiDisplayUtil;
import mage.components.CardInfoPane;
import mage.constants.Rarity;
import mage.remote.Session;
import mage.utils.ThreadUtils;
import mage.view.CardView;
@ -195,7 +195,7 @@ public class MageActionCallback implements ActionCallback {
private void showPopup(final TransferData data, final Component parentComponent, final Point parentPoint) {
// skip popup for not implemented cards (they have Rarity.NA)
if (data.card.getRarity().equals(Constants.Rarity.NA)) {
if (data.card.getRarity().equals(Rarity.NA)) {
return;
}

View file

@ -46,8 +46,8 @@ import java.util.concurrent.CancellationException;
import java.util.concurrent.ExecutionException;
import javax.swing.*;
import javax.swing.table.AbstractTableModel;
import mage.Constants.MultiplayerAttackOption;
import mage.Constants.RangeOfInfluence;
import mage.constants.MultiplayerAttackOption;
import mage.constants.RangeOfInfluence;
import mage.cards.decks.importer.DeckImporterUtil;
import mage.client.MageFrame;
import mage.client.chat.ChatPanel;

View file

@ -6,7 +6,7 @@ import javax.swing.JButton;
import javax.swing.JLabel;
import javax.swing.SwingConstants;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.utils.CardUtil;
import mage.view.CardView;

View file

@ -1,6 +1,6 @@
package org.mage.card.arcane;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.cards.MagePermanent;
import mage.cards.TextPopup;
import mage.cards.action.ActionCallback;
@ -751,7 +751,7 @@ public class CardPanel extends MagePermanent implements MouseListener, MouseMoti
sbType.append(superType).append(" ");
}
for (mage.Constants.CardType cardType : card.getCardTypes()) {
for (CardType cardType : card.getCardTypes()) {
sbType.append(cardType.toString()).append(" ");
}

View file

@ -2,6 +2,7 @@ package org.mage.plugins.card;
import mage.cards.MagePermanent;
import mage.cards.action.ActionCallback;
import mage.constants.Rarity;
import mage.interfaces.plugin.CardPlugin;
import mage.utils.CardUtil;
import mage.view.CardView;
@ -80,7 +81,7 @@ public class CardPluginImpl implements CardPlugin {
boolean foil = canBeFoil && (new Random()).nextInt(5) == 0;
CardPanel cardPanel = new CardPanel(permanent, gameId, loadImage, callback, foil);
cardPanel.setCardBounds(0, 0, dimension.width, dimension.height);
boolean implemented = !permanent.getRarity().equals(mage.Constants.Rarity.NA);
boolean implemented = !permanent.getRarity().equals(Rarity.NA);
cardPanel.setShowCastingCost(implemented);
return cardPanel;
}
@ -90,7 +91,7 @@ public class CardPluginImpl implements CardPlugin {
boolean foil = canBeFoil && (new Random()).nextInt(5) == 0;
CardPanel cardPanel = new CardPanel(permanent, gameId, loadImage, callback, foil);
cardPanel.setCardBounds(0, 0, dimension.width, dimension.height);
boolean implemented = !permanent.getRarity().equals(mage.Constants.Rarity.NA);
boolean implemented = !permanent.getRarity().equals(Rarity.NA);
cardPanel.setShowCastingCost(implemented);
return cardPanel;
}

View file

@ -1,7 +1,7 @@
package org.mage.plugins.card.info;
import mage.Constants;
import mage.components.CardInfoPane;
import mage.constants.CardType;
import mage.utils.CardUtil;
import mage.utils.ThreadUtils;
import mage.view.CardView;
@ -14,7 +14,6 @@ import javax.swing.*;
import java.awt.*;
import java.util.ArrayList;
import java.util.List;
import mage.abilities.SpellAbility;
/**
* Card info pane for displaying card rules.
@ -263,7 +262,7 @@ public class CardInfoPaneImpl extends JEditorPane implements CardInfoPane {
for (String superType : card.getSuperTypes()) {
types += superType + " ";
}
for (Constants.CardType cardType : card.getCardTypes()) {
for (CardType cardType : card.getCardTypes()) {
types += cardType.toString() + " ";
}
if (card.getSubTypes().size() > 0) {

View file

@ -1,8 +1,9 @@
package mage.interfaces.rate;
import java.util.List;
import mage.Constants;
import mage.cards.Card;
import mage.constants.ColoredManaSymbol;
/**
* Interface for the class responsible for rating cards.
@ -11,5 +12,5 @@ import mage.cards.Card;
*/
public interface RateCallback {
int rateCard(Card card);
Card getBestBasicLand(Constants.ColoredManaSymbol color, List<String> setsToUse);
Card getBestBasicLand(ColoredManaSymbol color, List<String> setsToUse);
}

View file

@ -1,6 +1,6 @@
package mage.utils;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.cards.Card;
import mage.cards.MagePermanent;
import mage.view.CardView;

View file

@ -1,7 +1,7 @@
package mage.utils;
import mage.Constants;
import mage.Constants.ColoredManaSymbol;
import mage.constants.CardType;
import mage.constants.ColoredManaSymbol;
import mage.Mana;
import mage.cards.Card;
import mage.cards.decks.Deck;
@ -210,13 +210,13 @@ public class DeckBuilder {
this.card = card;
int type = 0;
if (card.getCardType().contains(Constants.CardType.CREATURE)) {
if (card.getCardType().contains(CardType.CREATURE)) {
type = 10;
} else if (card.getSubtype().contains("Equipment")) {
type = 8;
} else if (card.getSubtype().contains("Aura")) {
type = 5;
} else if (card.getCardType().contains(Constants.CardType.INSTANT)) {
} else if (card.getCardType().contains(CardType.INSTANT)) {
type = 7;
} else {
type = 6;

View file

@ -29,7 +29,7 @@
package mage.view;
import java.util.ArrayList;
import mage.Constants.CardType;
import mage.constants.CardType;
import mage.ObjectColor;
import mage.abilities.Ability;

View file

@ -28,12 +28,13 @@
package mage.view;
import mage.Constants;
import mage.Constants.CardType;
import mage.Constants.Rarity;
import mage.constants.CardType;
import mage.constants.Rarity;
import mage.MageObject;
import mage.ObjectColor;
import mage.cards.Card;
import mage.constants.SpellAbilityType;
import mage.constants.Zone;
import mage.counters.CounterType;
import mage.game.permanent.Permanent;
import mage.game.permanent.PermanentToken;
@ -112,7 +113,7 @@ public class CardView extends SimpleCardView {
if (card.isSplitCard()) {
splitCard = (SplitCard) card;
} else {
if (card instanceof Spell && ((Spell) card).getSpellAbility().getSpellAbilityType().equals(Constants.SpellAbilityType.SPLIT_FUSED)) {
if (card instanceof Spell && ((Spell) card).getSpellAbility().getSpellAbilityType().equals(SpellAbilityType.SPLIT_FUSED)) {
splitCard = (SplitCard) ((Spell) card).getCard();
}
}
@ -217,7 +218,7 @@ public class CardView extends SimpleCardView {
this.rarity = Rarity.NA;
this.rules = new ArrayList<String>();
this.rules.add(stackAbility.getRule());
if (stackAbility.getZone().equals(Constants.Zone.COMMAND)) {
if (stackAbility.getZone().equals(Zone.COMMAND)) {
this.expansionSetCode = stackAbility.getExpansionSetCode();
}
}

View file

@ -28,7 +28,7 @@
package mage.view;
import mage.Constants.Zone;
import mage.constants.Zone;
import mage.MageObject;
import mage.abilities.Ability;
import mage.abilities.effects.Effect;
@ -39,7 +39,6 @@ import mage.game.permanent.Permanent;
import mage.target.targetpointer.TargetPointer;
import java.util.*;
import static mage.Constants.Zone.STACK;
/**
*

View file

@ -28,12 +28,12 @@
package mage.view;
import mage.Constants;
import mage.Constants.PhaseStep;
import mage.Constants.TurnPhase;
import mage.constants.PhaseStep;
import mage.constants.TurnPhase;
import mage.MageObject;
import mage.abilities.costs.Cost;
import mage.cards.Card;
import mage.constants.Zone;
import mage.game.ExileZone;
import mage.game.Game;
import mage.game.GameState;
@ -176,7 +176,7 @@ public class GameView implements Serializable {
}
Permanent permanent = game.getPermanent(card.getId());
if (permanent == null) {
permanent = (Permanent)game.getLastKnownInformation(card.getId(), Constants.Zone.BATTLEFIELD);
permanent = (Permanent)game.getLastKnownInformation(card.getId(), Zone.BATTLEFIELD);
}
if (permanent != null) {
if (permanent.isTransformed()) {

View file

@ -33,7 +33,7 @@ import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.UUID;
import mage.Constants.TableState;
import mage.constants.TableState;
import mage.game.Game;
import mage.game.Seat;
import mage.game.Table;

View file

@ -33,10 +33,11 @@ import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import mage.Constants;
import mage.cards.Card;
import mage.cards.decks.Deck;
import mage.cards.decks.DeckValidatorImpl;
import mage.constants.CardType;
import mage.filter.FilterMana;
/**
@ -133,7 +134,7 @@ public class Commander extends DeckValidatorImpl {
if(deck.getSideboard().size() == 1){
Card commander = (Card)deck.getSideboard().toArray()[0];
if(commander != null && commander.getCardType().contains(Constants.CardType.CREATURE) && commander.getSupertype().contains("Legendary")){
if(commander != null && commander.getCardType().contains(CardType.CREATURE) && commander.getSupertype().contains("Legendary")){
FilterMana color = getColorIdentity(commander);
for(Card card : deck.getCards()){
if(!cardHasValideColor(color, card)){

View file

@ -30,7 +30,7 @@ package mage.deck;
import java.util.Calendar;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
import mage.cards.decks.Constructed;
import mage.cards.Sets;

View file

@ -28,7 +28,7 @@
package mage.deck;
import java.util.Date;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
import mage.cards.Sets;
import mage.cards.decks.Constructed;

View file

@ -30,7 +30,7 @@ package mage.deck;
import java.util.Calendar;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
import mage.cards.decks.Constructed;
import mage.cards.Sets;

View file

@ -31,9 +31,9 @@ package mage.game;
import java.util.HashSet;
import java.util.Set;
import java.util.UUID;
import mage.Constants.MultiplayerAttackOption;
import mage.Constants.PhaseStep;
import mage.Constants.RangeOfInfluence;
import mage.constants.MultiplayerAttackOption;
import mage.constants.PhaseStep;
import mage.constants.RangeOfInfluence;
import mage.game.match.MatchType;
import mage.game.turn.TurnMod;

View file

@ -31,8 +31,8 @@ package mage.game;
import java.util.HashSet;
import java.util.Set;
import java.util.UUID;
import mage.Constants.MultiplayerAttackOption;
import mage.Constants.RangeOfInfluence;
import mage.constants.MultiplayerAttackOption;
import mage.constants.RangeOfInfluence;
import mage.game.match.MatchType;
/**

View file

@ -31,9 +31,9 @@ package mage.game;
import java.util.HashSet;
import java.util.Set;
import java.util.UUID;
import mage.Constants.MultiplayerAttackOption;
import mage.Constants.PhaseStep;
import mage.Constants.RangeOfInfluence;
import mage.constants.MultiplayerAttackOption;
import mage.constants.PhaseStep;
import mage.constants.RangeOfInfluence;
import mage.game.match.MatchType;
import mage.game.turn.TurnMod;

View file

@ -28,7 +28,7 @@
package mage.player.ai;
import mage.Constants.RangeOfInfluence;
import mage.constants.RangeOfInfluence;
import mage.game.Game;
import mage.players.Player;

View file

@ -27,9 +27,9 @@
*/
package mage.player.ai;
import mage.Constants.Outcome;
import mage.Constants.PhaseStep;
import mage.Constants.RangeOfInfluence;
import mage.constants.Outcome;
import mage.constants.PhaseStep;
import mage.constants.RangeOfInfluence;
import mage.abilities.Ability;
import mage.abilities.ActivatedAbility;
import mage.abilities.SpellAbility;

View file

@ -28,8 +28,8 @@
package mage.player.ai;
import mage.Constants;
import mage.Constants.RangeOfInfluence;
import mage.constants.PhaseStep;
import mage.constants.RangeOfInfluence;
import mage.abilities.Ability;
import mage.game.Game;
import mage.game.combat.Combat;
@ -306,7 +306,7 @@ public class ComputerPlayer7 extends ComputerPlayer6 implements Player {
logger.debug("interrupted");
return GameStateEvaluator2.evaluate(playerId, game);
}
if (game.getTurn().getStepType() != Constants.PhaseStep.DECLARE_BLOCKERS) {
if (game.getTurn().getStepType() != PhaseStep.DECLARE_BLOCKERS) {
game.getTurn().setPhase(new CombatPhase());
if (game.getPhase().beginPhase(game, game.getActivePlayerId())) {
simulateStep(game, new BeginCombatStep());

View file

@ -1,15 +1,15 @@
package mage.player.ai.ma;
import mage.Constants;
import mage.abilities.Ability;
import mage.abilities.keyword.HasteAbility;
import mage.cards.Card;
import mage.constants.CardType;
import mage.counters.CounterType;
import mage.game.Game;
import mage.game.permanent.Permanent;
import java.util.UUID;
import mage.Constants.Outcome;
import mage.constants.Outcome;
import mage.abilities.effects.Effect;
/**
@ -28,7 +28,7 @@ public class ArtificialScoringSystem {
public static int getCardDefinitionScore(final Game game, final Card card) {
int value = 3; //TODO: add new rating system card value
if (card.getCardType().contains(Constants.CardType.LAND)) {
if (card.getCardType().contains(CardType.LAND)) {
int score = (int) ((value / 2.0f) * 50);
//TODO: check this for "any color" lands
//TODO: check this for dual and filter lands
@ -40,7 +40,7 @@ public class ArtificialScoringSystem {
}
final int score = value * 100 - card.getManaCost().convertedManaCost() * 20;
if (card.getCardType().contains(Constants.CardType.CREATURE)) {
if (card.getCardType().contains(CardType.CREATURE)) {
return score + (card.getPower().getValue() + card.getToughness().getValue()) * 10;
} else {
return score + (/*card.getRemoval()*50*/ +card.getRarity().getRating() * 30);
@ -50,7 +50,7 @@ public class ArtificialScoringSystem {
public static int getFixedPermanentScore(final Game game, final Permanent permanent) {
//TODO: cache it inside Card
int score = getCardDefinitionScore(game, permanent);
if (permanent.getCardType().contains(Constants.CardType.CREATURE)) {
if (permanent.getCardType().contains(CardType.CREATURE)) {
// TODO: implement in the mage core
//score + =cardDefinition.getActivations().size()*50;
//score += cardDefinition.getManaActivations().size()*80;
@ -71,7 +71,7 @@ public class ArtificialScoringSystem {
if (!canTap(permanent)) {
score += getTappedScore(permanent);
}
if (permanent.getCardType().contains(Constants.CardType.CREATURE)) {
if (permanent.getCardType().contains(CardType.CREATURE)) {
final int power = permanent.getPower().getValue();
final int toughness = permanent.getToughness().getValue();
int abilityScore = 0;
@ -86,7 +86,7 @@ public class ArtificialScoringSystem {
for (UUID uuid : permanent.getAttachments()) {
Card card = game.getCard(uuid);
if (card != null) {
if (card.getCardType().contains(Constants.CardType.ENCHANTMENT)) {
if (card.getCardType().contains(CardType.ENCHANTMENT)) {
Effect effect = card.getSpellAbility().getEffects().get(0);
if (effect != null) {
Outcome outcome = effect.getOutcome();
@ -117,7 +117,7 @@ public class ArtificialScoringSystem {
private static boolean canTap(Permanent permanent) {
return !permanent.isTapped()
&&(!permanent.hasSummoningSickness()
||!permanent.getCardType().contains(Constants.CardType.CREATURE)
||!permanent.getCardType().contains(CardType.CREATURE)
||permanent.getAbilities().contains(HasteAbility.getInstance()));
}
@ -126,9 +126,9 @@ public class ArtificialScoringSystem {
}
public static int getTappedScore(final Permanent permanent) {
if (permanent.getCardType().contains(Constants.CardType.CREATURE)) {
if (permanent.getCardType().contains(CardType.CREATURE)) {
return -100;
} else if (permanent.getCardType().contains(Constants.CardType.LAND)) {
} else if (permanent.getCardType().contains(CardType.LAND)) {
return -1;
} else {
return -2;

View file

@ -28,7 +28,6 @@
package mage.player.ai;
import mage.Constants.*;
import mage.MageObject;
import mage.Mana;
import mage.abilities.*;
@ -50,6 +49,7 @@ import mage.cards.repository.CardCriteria;
import mage.cards.repository.CardInfo;
import mage.cards.repository.CardRepository;
import mage.choices.Choice;
import mage.constants.*;
import mage.filter.FilterPermanent;
import mage.filter.common.*;
import mage.game.Game;
@ -80,10 +80,6 @@ import java.io.IOException;
import java.io.Serializable;
import java.util.*;
import java.util.Map.Entry;
import static mage.Constants.SpellAbilityType.SPLIT;
import static mage.Constants.SpellAbilityType.SPLIT_FUSED;
/**

View file

@ -31,8 +31,8 @@ package mage.player.ai;
import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
import mage.Constants.CardType;
import mage.Constants.Zone;
import mage.constants.CardType;
import mage.constants.Zone;
import mage.game.Game;
import mage.game.permanent.Permanent;

View file

@ -1,10 +1,12 @@
package mage.player.ai.utils;
import mage.Constants;
import mage.abilities.Ability;
import mage.abilities.effects.Effect;
import mage.abilities.effects.common.DamageTargetEffect;
import mage.cards.Card;
import mage.constants.CardType;
import mage.constants.ColoredManaSymbol;
import mage.constants.Outcome;
import mage.target.Target;
import mage.target.common.TargetCreatureOrPlayer;
import mage.target.common.TargetCreaturePermanent;
@ -47,20 +49,20 @@ public class RateCard {
* @param card
* @return
*/
public static int rateCard(Card card, List<Constants.ColoredManaSymbol> allowedColors) {
public static int rateCard(Card card, List<ColoredManaSymbol> allowedColors) {
if (allowedColors == null && rated.containsKey(card.getName())) {
return rated.get(card.getName());
}
int type = 0;
if (card.getCardType().contains(Constants.CardType.PLANESWALKER)) {
if (card.getCardType().contains(CardType.PLANESWALKER)) {
type = 15;
} if (card.getCardType().contains(Constants.CardType.CREATURE)) {
} if (card.getCardType().contains(CardType.CREATURE)) {
type = 10;
} else if (card.getSubtype().contains("Equipment")) {
type = 8;
} else if (card.getSubtype().contains("Aura")) {
type = 5;
} else if (card.getCardType().contains(Constants.CardType.INSTANT)) {
} else if (card.getCardType().contains(CardType.INSTANT)) {
type = 7;
} else {
type = 6;
@ -73,16 +75,16 @@ public class RateCard {
}
private static int isRemoval(Card card) {
if (card.getSubtype().contains("Aura") || card.getCardType().contains(Constants.CardType.INSTANT)
|| card.getCardType().contains(Constants.CardType.SORCERY)) {
if (card.getSubtype().contains("Aura") || card.getCardType().contains(CardType.INSTANT)
|| card.getCardType().contains(CardType.SORCERY)) {
for (Ability ability : card.getAbilities()) {
for (Effect effect : ability.getEffects()) {
if (effect.getOutcome().equals(Constants.Outcome.Removal)) {
if (effect.getOutcome().equals(Outcome.Removal)) {
log.debug("Found removal: " + card.getName());
return 1;
}
if (effect.getOutcome().equals(Constants.Outcome.Damage)) {
if (effect.getOutcome().equals(Outcome.Damage)) {
if (effect instanceof DamageTargetEffect) {
DamageTargetEffect damageEffect = (DamageTargetEffect) effect;
if (damageEffect.getAmount() > 1) {
@ -95,7 +97,7 @@ public class RateCard {
}
}
}
if (effect.getOutcome().equals(Constants.Outcome.DestroyPermanent)) {
if (effect.getOutcome().equals(Outcome.DestroyPermanent)) {
for (Target target : ability.getTargets()) {
if (target instanceof TargetCreaturePermanent) {
log.info("Found destroyer: " + card.getName());
@ -175,7 +177,7 @@ public class RateCard {
* @param allowedColors Can be null.
* @return
*/
private static int getManaCostScore(Card card, List<Constants.ColoredManaSymbol> allowedColors) {
private static int getManaCostScore(Card card, List<ColoredManaSymbol> allowedColors) {
int converted = card.getManaCost().convertedManaCost();
if (allowedColors == null) {
int colorPenalty = 0;
@ -192,7 +194,7 @@ public class RateCard {
int count = 0;
symbol = symbol.replace("{", "").replace("}", "");
if (isColoredMana(symbol)) {
for (Constants.ColoredManaSymbol allowed : allowedColors) {
for (ColoredManaSymbol allowed : allowedColors) {
if (allowed.toString().equals(symbol)) {
count++;
}

View file

@ -27,9 +27,9 @@
*/
package mage.player.ai;
import mage.Constants.PhaseStep;
import mage.Constants.RangeOfInfluence;
import mage.Constants.Zone;
import mage.constants.PhaseStep;
import mage.constants.RangeOfInfluence;
import mage.constants.Zone;
import mage.abilities.Ability;
import mage.abilities.ActivatedAbility;
import mage.abilities.common.PassAbility;

View file

@ -31,8 +31,8 @@ import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.List;
import java.util.UUID;
import mage.Constants.PhaseStep;
import mage.Constants.Zone;
import mage.constants.PhaseStep;
import mage.constants.Zone;
import mage.abilities.Ability;
import mage.abilities.ActivatedAbility;
import mage.abilities.PlayLandAbility;

View file

@ -27,7 +27,7 @@
*/
package mage.player.ai;
import mage.Constants.Outcome;
import mage.constants.Outcome;
import mage.abilities.*;
import mage.abilities.common.PassAbility;
import mage.abilities.costs.mana.GenericManaCost;

View file

@ -28,9 +28,9 @@
package mage.player.ai;
import mage.Constants.Outcome;
import mage.Constants.PhaseStep;
import mage.Constants.RangeOfInfluence;
import mage.constants.Outcome;
import mage.constants.PhaseStep;
import mage.constants.RangeOfInfluence;
import mage.abilities.Ability;
import mage.abilities.ActivatedAbility;
import mage.abilities.common.PassAbility;

View file

@ -28,8 +28,8 @@
package mage.player.ai;
import mage.Constants.PhaseStep;
import mage.Constants.RangeOfInfluence;
import mage.constants.PhaseStep;
import mage.constants.RangeOfInfluence;
import mage.abilities.Ability;
import mage.game.Game;
import mage.game.combat.Combat;

View file

@ -29,8 +29,8 @@
package mage.player.ai;
import java.util.UUID;
import mage.Constants.CardType;
import mage.Constants.Zone;
import mage.constants.CardType;
import mage.constants.Zone;
import mage.abilities.ActivatedAbility;
import mage.abilities.keyword.DoubleStrikeAbility;
import mage.abilities.keyword.FirstStrikeAbility;

View file

@ -30,11 +30,9 @@ package mage.player.human;
import java.io.Serializable;
import java.util.*;
import mage.Constants.Outcome;
import mage.Constants.RangeOfInfluence;
import static mage.Constants.SpellAbilityType.SPLIT;
import static mage.Constants.SpellAbilityType.SPLIT_FUSED;
import mage.Constants.Zone;
import mage.constants.Outcome;
import mage.constants.RangeOfInfluence;
import mage.constants.Zone;
import mage.MageObject;
import mage.abilities.*;
import mage.abilities.costs.common.SacrificeSourceCost;

View file

@ -34,8 +34,8 @@ import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.ScheduledFuture;
import java.util.concurrent.TimeUnit;
import mage.Constants.RangeOfInfluence;
import mage.Constants.TableState;
import mage.constants.RangeOfInfluence;
import mage.constants.TableState;
import mage.MageException;
import mage.cards.decks.Deck;
import mage.cards.decks.DeckCardLists;

View file

@ -33,10 +33,11 @@ import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;
import mage.Constants;
import mage.MageException;
import mage.cards.decks.Deck;
import mage.cards.decks.DeckCardLists;
import mage.constants.TableState;
import mage.game.GameException;
import mage.game.Table;
import mage.game.draft.Draft;
@ -303,7 +304,7 @@ public class TableManager {
Date now = new Date();
List<UUID> toRemove = new ArrayList<UUID>();
for (Table table : tables.values()) {
if (!table.getState().equals(Constants.TableState.FINISHED)) {
if (!table.getState().equals(TableState.FINISHED)) {
// remove all tables created more than expire_time ago
long diff = (now.getTime() - table.getCreateTime().getTime()) / EXPIRE_TIME_UNIT_VALUE;
if (diff >= EXPIRE_TIME) {

View file

@ -3,7 +3,8 @@ package mage.server.challenge;
import java.util.HashMap;
import java.util.Map;
import java.util.UUID;
import mage.Constants;
import mage.constants.Zone;
import mage.game.match.Match;
/**
@ -19,8 +20,8 @@ public class ChallengeManager {
}
public void prepareChallenge(UUID playerId, Match match) {
Map<Constants.Zone, String> commands = new HashMap<Constants.Zone, String>();
commands.put(Constants.Zone.OUTSIDE, "life:3");
Map<Zone, String> commands = new HashMap<Zone, String>();
commands.put(Zone.OUTSIDE, "life:3");
match.getGame().cheat(playerId, commands);
}
}

View file

@ -28,7 +28,7 @@
package mage.server.game;
import mage.Constants.Zone;
import mage.constants.Zone;
import mage.MageException;
import mage.abilities.Ability;
import mage.cards.Card;

View file

@ -38,7 +38,7 @@ import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.Executors;
import java.util.concurrent.ScheduledExecutorService;
import java.util.concurrent.TimeUnit;
import mage.Constants.TableState;
import mage.constants.TableState;
import mage.MageException;
import mage.cards.decks.DeckCardLists;
import mage.game.GameException;

View file

@ -32,7 +32,7 @@ import java.lang.reflect.Constructor;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.Set;
import mage.Constants.RangeOfInfluence;
import mage.constants.RangeOfInfluence;
import mage.players.Player;
import org.apache.log4j.Logger;

View file

@ -1,9 +1,9 @@
package mage.server.util;
import mage.Constants;
import mage.cards.Card;
import mage.cards.repository.CardInfo;
import mage.cards.repository.CardRepository;
import mage.constants.Zone;
import mage.game.Game;
import mage.players.Player;
@ -70,15 +70,15 @@ public class SystemUtil {
continue;
}
Constants.Zone gameZone;
Zone gameZone;
if ("hand".equalsIgnoreCase(zone)) {
gameZone = Constants.Zone.HAND;
gameZone = Zone.HAND;
} else if ("battlefield".equalsIgnoreCase(zone)) {
gameZone = Constants.Zone.BATTLEFIELD;
gameZone = Zone.BATTLEFIELD;
} else if ("graveyard".equalsIgnoreCase(zone)) {
gameZone = Constants.Zone.GRAVEYARD;
gameZone = Zone.GRAVEYARD;
} else if ("library".equalsIgnoreCase(zone)) {
gameZone = Constants.Zone.LIBRARY;
gameZone = Zone.LIBRARY;
} else {
continue; // go parse next line
}
@ -121,11 +121,11 @@ public class SystemUtil {
* @param game
* @param card Card to put to player's hand
*/
private static void swapWithAnyCard(Game game, Player player, Card card, Constants.Zone zone) {
if (zone.equals(Constants.Zone.BATTLEFIELD)) {
card.putOntoBattlefield(game, Constants.Zone.OUTSIDE, null, player.getId());
} else if (zone.equals(Constants.Zone.LIBRARY)) {
game.setZone(card.getId(), Constants.Zone.LIBRARY);
private static void swapWithAnyCard(Game game, Player player, Card card, Zone zone) {
if (zone.equals(Zone.BATTLEFIELD)) {
card.putOntoBattlefield(game, Zone.OUTSIDE, null, player.getId());
} else if (zone.equals(Zone.LIBRARY)) {
game.setZone(card.getId(), Zone.LIBRARY);
player.getLibrary().putOnTop(card, game);
} else {
card.moveToZone(zone, null, game, false);

View file

@ -29,7 +29,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -1,7 +1,7 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -13,7 +13,7 @@ public class Alliances extends ExpansionSet {
}
private Alliances() {
super("Alliances", "ALL", "mage.sets.alliances", new GregorianCalendar(1996, 6, 10).getTime(), Constants.SetType.EXPANSION);
super("Alliances", "ALL", "mage.sets.alliances", new GregorianCalendar(1996, 6, 10).getTime(), SetType.EXPANSION);
this.blockName = "Ice Age";
this.parentSet = IceAge.getInstance();
this.hasBasicLands = false;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class Antiquities extends ExpansionSet {
}
private Antiquities() {
super("Antiquities", "ATQ", "mage.sets.antiquities", new GregorianCalendar(1994, 2, 1).getTime(), Constants.SetType.EXPANSION);
super("Antiquities", "ATQ", "mage.sets.antiquities", new GregorianCalendar(1994, 2, 1).getTime(), SetType.EXPANSION);
this.hasBasicLands = false;
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -1,8 +1,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
public class Apocalypse extends ExpansionSet {
@ -13,7 +14,7 @@ public class Apocalypse extends ExpansionSet {
}
private Apocalypse() {
super("Apocalypse", "APC", "mage.sets.apocalypse", new GregorianCalendar(2001, 5, 1).getTime(), Constants.SetType.EXPANSION);
super("Apocalypse", "APC", "mage.sets.apocalypse", new GregorianCalendar(2001, 5, 1).getTime(), SetType.EXPANSION);
this.blockName = "Invasion";
this.parentSet = Invasion.getInstance();
this.hasBasicLands = false;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class ArabianNights extends ExpansionSet {
}
private ArabianNights() {
super("Arabian Nights", "ARN", "mage.sets.arabiannights", new GregorianCalendar(1993, 11, 1).getTime(), Constants.SetType.EXPANSION);
super("Arabian Nights", "ARN", "mage.sets.arabiannights", new GregorianCalendar(1993, 11, 1).getTime(), SetType.EXPANSION);
this.hasBasicLands = false;
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -1,7 +1,7 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -13,7 +13,7 @@ public class ChampionsOfKamigawa extends ExpansionSet {
}
private ChampionsOfKamigawa() {
super("Champions of Kamigawa", "CHK", "mage.sets.championsofkamigawa", new GregorianCalendar(2004, 9, 1).getTime(), Constants.SetType.EXPANSION);
super("Champions of Kamigawa", "CHK", "mage.sets.championsofkamigawa", new GregorianCalendar(2004, 9, 1).getTime(), SetType.EXPANSION);
this.blockName = "Kamigawa";
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class Coldsnap extends ExpansionSet {
}
private Coldsnap() {
super("Coldsnap", "CSP", "mage.sets.coldsnap", new GregorianCalendar(2006, 6, 21).getTime(), Constants.SetType.EXPANSION);
super("Coldsnap", "CSP", "mage.sets.coldsnap", new GregorianCalendar(2006, 6, 21).getTime(), SetType.EXPANSION);
this.blockName = "Ice Age";
this.hasBoosters = true;
this.numBoosterLands = 0;

View file

@ -29,7 +29,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -29,7 +29,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -1,7 +1,7 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -14,7 +14,7 @@ public class Darksteel extends ExpansionSet {
}
public Darksteel() {
super("Darksteel", "DST", "mage.sets.darksteel", new GregorianCalendar(2004, 1, 6).getTime(), Constants.SetType.EXPANSION);
super("Darksteel", "DST", "mage.sets.darksteel", new GregorianCalendar(2004, 1, 6).getTime(), SetType.EXPANSION);
this.blockName = "Mirrodin";
this.parentSet = Mirrodin.getInstance();
this.hasBasicLands = false;

View file

@ -27,8 +27,8 @@
*/
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -47,7 +47,7 @@ public class Dissension extends ExpansionSet {
}
private Dissension() {
super("Dissension", "DIS", "mage.sets.dissension", new GregorianCalendar(2006, 4, 5).getTime(), Constants.SetType.EXPANSION);
super("Dissension", "DIS", "mage.sets.dissension", new GregorianCalendar(2006, 4, 5).getTime(), SetType.EXPANSION);
this.blockName = "Ravnika";
this.parentSet = RavnicaCityOfGuilds.getInstance();
this.hasBasicLands = false;

View file

@ -31,13 +31,14 @@ package mage.sets;
import java.util.ArrayList;
import java.util.GregorianCalendar;
import java.util.List;
import mage.Constants;
import mage.Constants.CardType;
import mage.Constants.Rarity;
import mage.constants.CardType;
import mage.constants.Rarity;
import mage.cards.ExpansionSet;
import mage.cards.repository.CardCriteria;
import mage.cards.repository.CardInfo;
import mage.cards.repository.CardRepository;
import mage.constants.SetType;
/**
*
@ -54,7 +55,7 @@ public class DragonsMaze extends ExpansionSet {
}
private DragonsMaze() {
super("Dragon's Maze", "DGM", "mage.sets.dragonsmaze", new GregorianCalendar(2013, 5, 03).getTime(), Constants.SetType.EXPANSION);
super("Dragon's Maze", "DGM", "mage.sets.dragonsmaze", new GregorianCalendar(2013, 5, 03).getTime(), SetType.EXPANSION);
this.blockName = "Return to Ravnica";
this.hasBoosters = true;
this.numBoosterSpecial = 1;
@ -121,7 +122,7 @@ public class DragonsMaze extends ExpansionSet {
@Override
public List<CardInfo> getSpecialMythic() {
CardCriteria criteria = new CardCriteria();
criteria.rarities(Rarity.MYTHIC).setCodes(this.code).types(Constants.CardType.LAND);
criteria.rarities(Rarity.MYTHIC).setCodes(this.code).types(CardType.LAND);
return CardRepository.instance.findCards(criteria);
}

View file

@ -1,7 +1,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
public class EighthEdition extends ExpansionSet {

View file

@ -1,7 +1,7 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -13,6 +13,6 @@ public class ElspethvsTezzeret extends ExpansionSet {
}
private ElspethvsTezzeret() {
super("Duel Decks: Elspeth vs. Tezzeret", "DDF", "mage.sets.elspethvstezzeret", new GregorianCalendar(2010, 8, 3).getTime(), Constants.SetType.REPRINT);
super("Duel Decks: Elspeth vs. Tezzeret", "DDF", "mage.sets.elspethvstezzeret", new GregorianCalendar(2010, 8, 3).getTime(), SetType.REPRINT);
}
}

View file

@ -1,7 +1,7 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -13,7 +13,7 @@ public class Eventide extends ExpansionSet {
}
private Eventide() {
super("Eventide", "EVE", "mage.sets.eventide", new GregorianCalendar(2008, 6, 25).getTime(), Constants.SetType.EXPANSION);
super("Eventide", "EVE", "mage.sets.eventide", new GregorianCalendar(2008, 6, 25).getTime(), SetType.EXPANSION);
this.blockName = "Shadowmoor";
this.parentSet = Shadowmoor.getInstance();
this.hasBasicLands = false;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class Exodus extends ExpansionSet {
}
private Exodus() {
super("Exodus", "EXO", "mage.sets.exodus", new GregorianCalendar(1998, 5, 6).getTime(), Constants.SetType.EXPANSION);
super("Exodus", "EXO", "mage.sets.exodus", new GregorianCalendar(1998, 5, 6).getTime(), SetType.EXPANSION);
this.blockName = "Tempest";
this.parentSet = Tempest.getInstance();
this.hasBasicLands = false;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class FallenEmpires extends ExpansionSet {
}
private FallenEmpires() {
super("Fallen Empires", "FEM", "mage.sets.fallenempires", new GregorianCalendar(1994, 10, 1).getTime(), Constants.SetType.EXPANSION);
super("Fallen Empires", "FEM", "mage.sets.fallenempires", new GregorianCalendar(1994, 10, 1).getTime(), SetType.EXPANSION);
this.hasBasicLands = false;
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -1,7 +1,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
public class FifthEdition extends ExpansionSet {

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class FourthEdition extends ExpansionSet {
}
private FourthEdition() {
super("Fourth Edition", "4ED", "mage.sets.fourthedition", new GregorianCalendar(1995, 3, 1).getTime(), Constants.SetType.CORE);
super("Fourth Edition", "4ED", "mage.sets.fourthedition", new GregorianCalendar(1995, 3, 1).getTime(), SetType.CORE);
this.hasBoosters = true;
this.numBoosterLands = 1;
this.numBoosterCommon = 10;

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,8 +28,8 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -47,7 +47,7 @@ public class Guildpact extends ExpansionSet {
}
private Guildpact() {
super("Guildpact", "GPT", "mage.sets.guildpact", new GregorianCalendar(2006, 1, 3).getTime(), Constants.SetType.EXPANSION);
super("Guildpact", "GPT", "mage.sets.guildpact", new GregorianCalendar(2006, 1, 3).getTime(), SetType.EXPANSION);
this.blockName = "Ravnika";
this.parentSet = RavnicaCityOfGuilds.getInstance();
this.hasBasicLands = false;

View file

@ -1,7 +1,7 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -14,6 +14,6 @@ public class Guru extends ExpansionSet {
private Guru() {
//TODO find correct release date, wiki don't known anything about this expansion
super("Guru", "GUR", "mage.sets.guru", new GregorianCalendar(1990, 1, 2).getTime(), Constants.SetType.REPRINT);
super("Guru", "GUR", "mage.sets.guru", new GregorianCalendar(1990, 1, 2).getTime(), SetType.REPRINT);
}
}

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class Homelands extends ExpansionSet {
}
private Homelands() {
super("Homelands", "HML", "mage.sets.homelands", new GregorianCalendar(1995, 9, 1).getTime(), Constants.SetType.EXPANSION);
super("Homelands", "HML", "mage.sets.homelands", new GregorianCalendar(1995, 9, 1).getTime(), SetType.EXPANSION);
this.hasBasicLands = false;
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class IceAge extends ExpansionSet {
}
private IceAge() {
super("Ice Age", "ICE", "mage.sets.iceage", new GregorianCalendar(1995, 5, 1).getTime(), Constants.SetType.EXPANSION);
super("Ice Age", "ICE", "mage.sets.iceage", new GregorianCalendar(1995, 5, 1).getTime(), SetType.EXPANSION);
this.blockName = "Ice Age";
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -28,7 +28,7 @@
package mage.sets;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
import java.util.GregorianCalendar;

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class Legends extends ExpansionSet {
}
private Legends() {
super("Legends", "LEG", "mage.sets.legends", new GregorianCalendar(1994, 5, 1).getTime(), Constants.SetType.EXPANSION);
super("Legends", "LEG", "mage.sets.legends", new GregorianCalendar(1994, 5, 1).getTime(), SetType.EXPANSION);
this.hasBasicLands = false;
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class Legions extends ExpansionSet {
}
private Legions() {
super("Legions", "LGN", "mage.sets.legions", new GregorianCalendar(2003, 0, 25).getTime(), Constants.SetType.EXPANSION);
super("Legions", "LGN", "mage.sets.legions", new GregorianCalendar(2003, 0, 25).getTime(), SetType.EXPANSION);
this.blockName = "Onslaught";
this.parentSet = Onslaught.getInstance();
this.hasBasicLands = false;

View file

@ -1,8 +1,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -17,7 +18,7 @@ public class LimitedEditionAlpha extends ExpansionSet {
}
private LimitedEditionAlpha() {
super("Limited Edition Alpha", "LEA", "mage.sets.limitedalpha", new GregorianCalendar(1993, 7, 1).getTime(), Constants.SetType.CORE);
super("Limited Edition Alpha", "LEA", "mage.sets.limitedalpha", new GregorianCalendar(1993, 7, 1).getTime(), SetType.CORE);
this.hasBoosters = true;
this.numBoosterLands = 1;
this.numBoosterCommon = 10;

View file

@ -1,8 +1,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -17,7 +18,7 @@ public class LimitedEditionBeta extends ExpansionSet {
}
private LimitedEditionBeta() {
super("Limited Edition Beta", "LEB", "mage.sets.limitedbeta", new GregorianCalendar(1993, 9, 1).getTime(), Constants.SetType.CORE);
super("Limited Edition Beta", "LEB", "mage.sets.limitedbeta", new GregorianCalendar(1993, 9, 1).getTime(), SetType.CORE);
this.hasBoosters = true;
this.numBoosterLands = 1;
this.numBoosterCommon = 10;

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -29,7 +29,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -29,7 +29,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -28,7 +28,7 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants.SetType;
import mage.constants.SetType;
import mage.cards.ExpansionSet;
/**

View file

@ -1,7 +1,7 @@
package mage.sets;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
import java.util.GregorianCalendar;
@ -13,7 +13,7 @@ public class MagicPlayerRewards extends ExpansionSet {
}
private MagicPlayerRewards() {
super("Magic Player Rewards", "MPR", "mage.sets.playerrewards", new GregorianCalendar(1990, 1, 1).getTime(), Constants.SetType.EXPANSION);
super("Magic Player Rewards", "MPR", "mage.sets.playerrewards", new GregorianCalendar(1990, 1, 1).getTime(), SetType.EXPANSION);
this.hasBoosters = false;
}
}

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -44,7 +45,7 @@ public class MercadianMasques extends ExpansionSet {
}
private MercadianMasques() {
super("Mercadian Masques", "MMQ", "mage.sets.mercadianmasques", new GregorianCalendar(1999, 8, 25).getTime(), Constants.SetType.EXPANSION);
super("Mercadian Masques", "MMQ", "mage.sets.mercadianmasques", new GregorianCalendar(1999, 8, 25).getTime(), SetType.EXPANSION);
this.blockName = "Masques";
this.hasBoosters = true;
this.numBoosterLands = 1;

View file

@ -28,8 +28,9 @@
package mage.sets;
import java.util.GregorianCalendar;
import mage.Constants;
import mage.cards.ExpansionSet;
import mage.constants.SetType;
/**
*
@ -43,7 +44,7 @@ public class Mirage extends ExpansionSet {
}
private Mirage() {
super("Mirage", "MIR", "mage.sets.mirage", new GregorianCalendar(1996, 8, 21).getTime(), Constants.SetType.EXPANSION);
super("Mirage", "MIR", "mage.sets.mirage", new GregorianCalendar(1996, 8, 21).getTime(), SetType.EXPANSION);
this.blockName = "Mirage";
this.hasBoosters = true;
this.numBoosterLands = 1;

Some files were not shown because too many files have changed in this diff Show more