mirror of
https://github.com/correl/mage.git
synced 2024-12-25 03:00:15 +00:00
[C14] Some changes for showing token images.
This commit is contained in:
parent
1b80bc3cfb
commit
8b0bd22ce8
12 changed files with 54 additions and 19 deletions
|
@ -54,7 +54,7 @@ public class MoonsilverSpear extends CardImpl {
|
|||
// Equipped creature has first strike.
|
||||
this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(FirstStrikeAbility.getInstance(), AttachmentType.EQUIPMENT)));
|
||||
// Whenever equipped creature attacks, put a 4/4 white Angel creature token with flying onto the battlefield.
|
||||
this.addAbility(new AttacksAttachedTriggeredAbility(new CreateTokenEffect(new AngelToken())));
|
||||
this.addAbility(new AttacksAttachedTriggeredAbility(new CreateTokenEffect(new AngelToken(expansionSetCode))));
|
||||
// Equip {4}
|
||||
this.addAbility(new EquipAbility(Outcome.AddAbility, new GenericManaCost(4)));
|
||||
}
|
||||
|
|
|
@ -44,6 +44,7 @@ import mage.constants.Rarity;
|
|||
import mage.constants.Zone;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.filter.predicate.permanent.AnotherPredicate;
|
||||
import mage.game.permanent.token.Token;
|
||||
import mage.game.permanent.token.ZombieToken;
|
||||
import mage.target.common.TargetControlledCreaturePermanent;
|
||||
|
||||
|
@ -72,7 +73,9 @@ public class GhoulcallerGisa extends CardImpl {
|
|||
|
||||
// {B}, {tap}, Sacrifice another creature: Put X 2/2 black Zombie creature tokens onto the battlefield, where X is the sacrificed creature's power.
|
||||
DynamicValue xValue = new SacrificeCostCreaturesPower();
|
||||
Effect effect = new CreateTokenEffect(new ZombieToken("C14"), xValue);
|
||||
Token zombie = new ZombieToken("C14");
|
||||
zombie.setTokenType(2);
|
||||
Effect effect = new CreateTokenEffect(zombie, xValue);
|
||||
effect.setText("Put X 2/2 black Zombie creature tokens onto the battlefield, where X is the sacrificed creature's power");
|
||||
Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{B}"));
|
||||
ability.addCost(new TapSourceCost());
|
||||
|
|
|
@ -31,13 +31,14 @@ import java.util.UUID;
|
|||
import mage.MageInt;
|
||||
import mage.abilities.common.DiesTriggeredAbility;
|
||||
import mage.abilities.dynamicvalue.common.CardsInControllerGraveyardCount;
|
||||
import mage.abilities.effects.Effect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.abilities.keyword.VigilanceAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Rarity;
|
||||
import static mage.filter.predicate.permanent.ControllerControlsIslandPredicate.filter;
|
||||
import mage.game.permanent.token.SpiritToken;
|
||||
import mage.game.permanent.token.Token;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -58,7 +59,9 @@ public class HallowedSpiritkeeper extends CardImpl {
|
|||
this.addAbility(VigilanceAbility.getInstance());
|
||||
|
||||
// When Hallowed Spiritkeeper dies, put X 1/1 white Spirit creature tokens with flying onto the battlefield, where X is the number of creature cards in your graveyard.
|
||||
this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new SpiritToken(), new CardsInControllerGraveyardCount()), false));
|
||||
Effect effect = new CreateTokenEffect(new HallowedSpiritkeeperSpiritToken(), new CardsInControllerGraveyardCount());
|
||||
effect.setText("put X 1/1 white Spirit creature tokens with flying onto the battlefield, where X is the number of creature cards in your graveyard");
|
||||
this.addAbility(new DiesTriggeredAbility(effect, false));
|
||||
|
||||
}
|
||||
|
||||
|
@ -71,3 +74,19 @@ public class HallowedSpiritkeeper extends CardImpl {
|
|||
return new HallowedSpiritkeeper(this);
|
||||
}
|
||||
}
|
||||
|
||||
class HallowedSpiritkeeperSpiritToken extends Token {
|
||||
|
||||
public HallowedSpiritkeeperSpiritToken() {
|
||||
super("Spirit", "1/1 white Spirit creature token with flying");
|
||||
setOriginalExpansionSetCode("C14");
|
||||
cardType.add(CardType.CREATURE);
|
||||
color.setWhite(true);
|
||||
subtype.add("Spirit");
|
||||
power = new MageInt(1);
|
||||
toughness = new MageInt(1);
|
||||
|
||||
addAbility(FlyingAbility.getInstance());
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
@ -154,6 +154,7 @@ class NahiriTheLithomancerKorSoldierToken extends Token {
|
|||
|
||||
NahiriTheLithomancerKorSoldierToken() {
|
||||
super("Kor Soldier", "1/1 white Kor Soldier creature token");
|
||||
setOriginalExpansionSetCode("C14");
|
||||
cardType.add(CardType.CREATURE);
|
||||
color.setWhite(true);
|
||||
subtype.add("Kor");
|
||||
|
|
|
@ -136,6 +136,7 @@ class ObNixilisDemonToken extends Token {
|
|||
|
||||
ObNixilisDemonToken() {
|
||||
super("Demon", "5/5 black Demon creature token with flying");
|
||||
setTokenType(1);
|
||||
setOriginalExpansionSetCode("C14");
|
||||
cardType.add(CardType.CREATURE);
|
||||
subtype.add("Demon");
|
||||
|
|
|
@ -43,6 +43,7 @@ import mage.filter.common.FilterCreaturePermanent;
|
|||
import mage.filter.predicate.Predicates;
|
||||
import mage.filter.predicate.permanent.ControllerPredicate;
|
||||
import mage.filter.predicate.permanent.TokenPredicate;
|
||||
import mage.game.permanent.token.Token;
|
||||
import mage.game.permanent.token.ZombieToken;
|
||||
import mage.target.common.TargetCreaturePermanent;
|
||||
|
||||
|
@ -75,7 +76,9 @@ public class OverseerOfTheDamned extends CardImpl {
|
|||
ability.addTarget(new TargetCreaturePermanent());
|
||||
this.addAbility(ability);
|
||||
// Whenever a nontoken creature an opponent controls dies, put a 2/2 black Zombie creature token onto the battlefield tapped.
|
||||
this.addAbility(new DiesCreatureTriggeredAbility(new CreateTokenEffect(new ZombieToken("C14"), 1, true, false), false, filter));
|
||||
Token zombie = new ZombieToken("C14");
|
||||
zombie.setTokenType(2);
|
||||
this.addAbility(new DiesCreatureTriggeredAbility(new CreateTokenEffect(zombie, 1, true, false), false, filter));
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -105,7 +105,7 @@ class PromiseOfPowerEffect extends OneShotEffect {
|
|||
public boolean apply(Game game, Ability source) {
|
||||
Player controller = game.getPlayer(source.getControllerId());
|
||||
if (controller != null) {
|
||||
return new CreateTokenEffect(new PromiseOfPowerHorrorToken(controller.getHand().size())).apply(game, source);
|
||||
return new CreateTokenEffect(new PromiseOfPowerDemonToken(controller.getHand().size())).apply(game, source);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
@ -116,14 +116,15 @@ class PromiseOfPowerEffect extends OneShotEffect {
|
|||
}
|
||||
|
||||
}
|
||||
class PromiseOfPowerHorrorToken extends Token {
|
||||
class PromiseOfPowerDemonToken extends Token {
|
||||
|
||||
public PromiseOfPowerHorrorToken(int xValue) {
|
||||
super("Horror", "X/X black Horror creature token with flying");
|
||||
public PromiseOfPowerDemonToken(int xValue) {
|
||||
super("Demon", "X/X black Demon creature token with flying");
|
||||
setOriginalExpansionSetCode("C14");
|
||||
setTokenType(2);
|
||||
cardType.add(CardType.CREATURE);
|
||||
color.setBlack(true);
|
||||
subtype.add("Horror");
|
||||
subtype.add("Demon");
|
||||
power = new MageInt(xValue);
|
||||
toughness = new MageInt(xValue);
|
||||
|
||||
|
|
|
@ -136,6 +136,7 @@ class StitcherGeralfZombieToken extends Token {
|
|||
StitcherGeralfZombieToken(int xValue) {
|
||||
super("Zombie", "an X/X blue Zombie creature token");
|
||||
setOriginalExpansionSetCode("C14");
|
||||
setTokenType(1);
|
||||
cardType.add(CardType.CREATURE);
|
||||
color.setBlue(true);
|
||||
subtype.add("Zombie");
|
||||
|
|
|
@ -53,7 +53,7 @@ public class TuktukTheExplorer extends CardImpl {
|
|||
this.power = new MageInt(1);
|
||||
this.toughness = new MageInt(1);
|
||||
this.addAbility(HasteAbility.getInstance());
|
||||
this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new TuktukTheReturnedToken())));
|
||||
this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new TuktukTheReturnedToken(expansionSetCode))));
|
||||
}
|
||||
|
||||
public TuktukTheExplorer (final TuktukTheExplorer card) {
|
||||
|
@ -68,8 +68,10 @@ public class TuktukTheExplorer extends CardImpl {
|
|||
}
|
||||
|
||||
class TuktukTheReturnedToken extends Token {
|
||||
TuktukTheReturnedToken() {
|
||||
|
||||
TuktukTheReturnedToken(String setCode) {
|
||||
super("Tuktuk the Returned", "a legendary 5/5 colorless Goblin Golem artifact creature token");
|
||||
setOriginalExpansionSetCode(setCode);
|
||||
cardType.add(CardType.ARTIFACT);
|
||||
cardType.add(CardType.CREATURE);
|
||||
supertype.add("Legendary");
|
||||
|
|
|
@ -53,10 +53,12 @@ public class WurmcoilEngine extends CardImpl {
|
|||
this.subtype.add("Wurm");
|
||||
this.power = new MageInt(6);
|
||||
this.toughness = new MageInt(6);
|
||||
|
||||
|
||||
this.addAbility(DeathtouchAbility.getInstance());
|
||||
this.addAbility(LifelinkAbility.getInstance());
|
||||
Ability ability = new DiesTriggeredAbility(new CreateTokenEffect(new Wurm1Token()), false);
|
||||
ability.addEffect(new CreateTokenEffect(new Wurm2Token()));
|
||||
Ability ability = new DiesTriggeredAbility(new CreateTokenEffect(new Wurm1Token(expansionSetCode)), false);
|
||||
ability.addEffect(new CreateTokenEffect(new Wurm2Token(expansionSetCode)));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
|
@ -72,8 +74,9 @@ public class WurmcoilEngine extends CardImpl {
|
|||
}
|
||||
|
||||
class Wurm1Token extends Token {
|
||||
public Wurm1Token() {
|
||||
public Wurm1Token(String setCode) {
|
||||
super("Wurm", "a 3/3 colorless Wurm artifact creature token with deathtouch");
|
||||
setOriginalExpansionSetCode(setCode);
|
||||
cardType.add(CardType.ARTIFACT);
|
||||
cardType.add(CardType.CREATURE);
|
||||
subtype.add("Wurm");
|
||||
|
@ -84,8 +87,9 @@ class Wurm1Token extends Token {
|
|||
}
|
||||
|
||||
class Wurm2Token extends Token {
|
||||
public Wurm2Token() {
|
||||
public Wurm2Token(String setCode) {
|
||||
super("Wurm", "a 3/3 colorless Wurm artifact creature token with lifelink");
|
||||
setOriginalExpansionSetCode(setCode);
|
||||
cardType.add(CardType.ARTIFACT);
|
||||
cardType.add(CardType.CREATURE);
|
||||
subtype.add("Wurm");
|
||||
|
|
|
@ -61,7 +61,7 @@ public class DecreeOfJustice extends CardImpl {
|
|||
this.color.setWhite(true);
|
||||
|
||||
// Put X 4/4 white Angel creature tokens with flying onto the battlefield.
|
||||
this.getSpellAbility().addEffect(new CreateTokenEffect(new AngelToken(), new ManacostVariableValue()));
|
||||
this.getSpellAbility().addEffect(new CreateTokenEffect(new AngelToken("C14"), new ManacostVariableValue()));
|
||||
|
||||
// Cycling {2}{W}
|
||||
this.addAbility(new CyclingAbility(new ManaCostsImpl<>("{2}{W}")));
|
||||
|
|
|
@ -50,7 +50,7 @@ import mage.util.CardUtil;
|
|||
public class Token extends MageObjectImpl {
|
||||
|
||||
protected String description;
|
||||
private ArrayList<UUID> lastAddedTokenIds = new ArrayList<>();
|
||||
private final ArrayList<UUID> lastAddedTokenIds = new ArrayList<>();
|
||||
private UUID lastAddedTokenId;
|
||||
private int tokenType;
|
||||
private int originalCardNumber;
|
||||
|
|
Loading…
Reference in a new issue