Refactoring: replace custom creature tokens with basic class

This commit is contained in:
Oleg Agafonov 2018-05-05 14:37:24 +04:00
parent a65c1f5c3f
commit 483853658b
6 changed files with 45 additions and 96 deletions

View file

@ -0,0 +1,31 @@
package mage.game.permanent.token.custom;
import mage.MageInt;
import mage.constants.CardType;
import mage.game.permanent.token.TokenImpl;
/**
*
* @author JayDi85
*/
public class CreatureToken extends TokenImpl {
public CreatureToken() {
this(0, 0);
}
public CreatureToken(int power, int toughness) {
super("", String.format("%d/%d creature", power, toughness));
this.cardType.add(CardType.CREATURE);
this.power = new MageInt(power);
this.toughness = new MageInt(toughness);
}
public CreatureToken(final CreatureToken token) {
super(token);
}
public CreatureToken copy() {
return new CreatureToken(this);
}
}