refactor cards to use supertype enum

This commit is contained in:
ingmargoudt 2017-03-27 20:36:54 +02:00
parent 84559457d3
commit 0879298e92
6374 changed files with 17783 additions and 14013 deletions

View file

@ -40,6 +40,7 @@ import mage.abilities.keyword.ChangelingAbility;
import mage.abilities.mana.ActivatedManaAbilityImpl;
import mage.cards.FrameStyle;
import mage.constants.CardType;
import mage.constants.SuperType;
import mage.game.Game;
import mage.game.events.ZoneChangeEvent;
import mage.util.CardUtil;
@ -56,7 +57,7 @@ public abstract class MageObjectImpl implements MageObject {
protected FrameStyle frameStyle;
protected EnumSet<CardType> cardType = EnumSet.noneOf(CardType.class);
protected List<String> subtype = new ArrayList<>();
protected List<String> supertype = new ArrayList<>();
protected EnumSet<SuperType> supertype = EnumSet.noneOf(SuperType.class);
protected Abilities<Ability> abilities;
protected String text;
protected MageInt power;
@ -91,7 +92,7 @@ public abstract class MageObjectImpl implements MageObject {
abilities = object.abilities.copy();
this.cardType.addAll(object.cardType);
this.subtype.addAll(object.subtype);
this.supertype.addAll(object.supertype);
supertype.addAll(object.supertype);
this.copy = object.copy;
}
@ -136,7 +137,7 @@ public abstract class MageObjectImpl implements MageObject {
}
@Override
public List<String> getSupertype() {
public EnumSet<SuperType> getSuperType() {
return supertype;
}