mirror of
https://github.com/magefree/mage.git
synced 2025-12-25 04:52:07 -08:00
Refactoring: replace custom creature tokens with basic class
This commit is contained in:
parent
a65c1f5c3f
commit
483853658b
6 changed files with 45 additions and 96 deletions
|
|
@ -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);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue