diff --git a/Mage.Sets/src/mage/cards/b/BeckonApparition.java b/Mage.Sets/src/mage/cards/b/BeckonApparition.java index 523332f22d..0f22b77c30 100644 --- a/Mage.Sets/src/mage/cards/b/BeckonApparition.java +++ b/Mage.Sets/src/mage/cards/b/BeckonApparition.java @@ -6,7 +6,7 @@ import mage.abilities.effects.common.ExileTargetEffect; import mage.cards.CardImpl; import mage.cards.CardSetInfo; import mage.constants.CardType; -import mage.game.permanent.token.BeckonApparitionToken; +import mage.game.permanent.token.WhiteBlackSpiritToken; import mage.target.common.TargetCardInGraveyard; import java.util.UUID; @@ -22,7 +22,7 @@ public final class BeckonApparition extends CardImpl { // Exile target card from a graveyard. Create a 1/1 white and black Spirit creature token with flying. this.getSpellAbility().addEffect(new ExileTargetEffect()); this.getSpellAbility().addTarget(new TargetCardInGraveyard()); - this.getSpellAbility().addEffect(new CreateTokenEffect(new BeckonApparitionToken(), 1)); + this.getSpellAbility().addEffect(new CreateTokenEffect(new WhiteBlackSpiritToken(), 1)); } public BeckonApparition(final BeckonApparition card) { diff --git a/Mage.Sets/src/mage/cards/t/TeysaEnvoyOfGhosts.java b/Mage.Sets/src/mage/cards/t/TeysaEnvoyOfGhosts.java index af3b6a7f7e..a5591d5c56 100644 --- a/Mage.Sets/src/mage/cards/t/TeysaEnvoyOfGhosts.java +++ b/Mage.Sets/src/mage/cards/t/TeysaEnvoyOfGhosts.java @@ -1,7 +1,6 @@ package mage.cards.t; -import java.util.UUID; import mage.MageInt; import mage.abilities.TriggeredAbilityImpl; import mage.abilities.effects.common.CreateTokenEffect; @@ -14,16 +13,18 @@ import mage.constants.CardType; import mage.constants.SubType; import mage.constants.SuperType; import mage.constants.Zone; -import static mage.filter.StaticFilters.FILTER_PERMANENT_CREATURES; import mage.game.Game; import mage.game.events.DamagedPlayerEvent; import mage.game.events.GameEvent; import mage.game.permanent.Permanent; -import mage.game.permanent.token.TeysaEnvoyOfGhostsToken; +import mage.game.permanent.token.WhiteBlackSpiritToken; import mage.target.targetpointer.FixedTarget; +import java.util.UUID; + +import static mage.filter.StaticFilters.FILTER_PERMANENT_CREATURES; + /** - * * @author LevelX2 */ public final class TeysaEnvoyOfGhosts extends CardImpl { @@ -60,7 +61,7 @@ class TeysaEnvoyOfGhostsTriggeredAbility extends TriggeredAbilityImpl { public TeysaEnvoyOfGhostsTriggeredAbility() { super(Zone.BATTLEFIELD, new DestroyTargetEffect()); - this.addEffect(new CreateTokenEffect(new TeysaEnvoyOfGhostsToken(), 1)); + this.addEffect(new CreateTokenEffect(new WhiteBlackSpiritToken(), 1)); } diff --git a/Mage.Sets/src/mage/sets/RavnicaAllegiance.java b/Mage.Sets/src/mage/sets/RavnicaAllegiance.java index 3ba99a79fb..cbd956a096 100644 --- a/Mage.Sets/src/mage/sets/RavnicaAllegiance.java +++ b/Mage.Sets/src/mage/sets/RavnicaAllegiance.java @@ -23,7 +23,7 @@ public final class RavnicaAllegiance extends ExpansionSet { super("Ravnica Allegiance", "RNA", ExpansionSet.buildDate(2019, 1, 25), SetType.EXPANSION); this.blockName = "Guilds of Ravnica"; this.hasBoosters = true; - this.hasBasicLands = false; // this is temporary until the actual basics have been spoiled to prevent a test fail + this.hasBasicLands = false; // this is temporary until the actual basics have been spoiled to prevent a test fail this.numBoosterSpecial = 1; this.numBoosterLands = 0; this.numBoosterCommon = 10; diff --git a/Mage/src/main/java/mage/abilities/keyword/AfterlifeAbility.java b/Mage/src/main/java/mage/abilities/keyword/AfterlifeAbility.java new file mode 100644 index 0000000000..ba71038869 --- /dev/null +++ b/Mage/src/main/java/mage/abilities/keyword/AfterlifeAbility.java @@ -0,0 +1,34 @@ +package mage.abilities.keyword; + +import mage.abilities.common.DiesTriggeredAbility; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.game.permanent.token.WhiteBlackSpiritToken; +import mage.util.CardUtil; + +public class AfterlifeAbility extends DiesTriggeredAbility { + private final int tokenCount; + + public AfterlifeAbility(int tokenCount) { + super(new CreateTokenEffect(new WhiteBlackSpiritToken(), tokenCount), false); + this.tokenCount = tokenCount; + } + + public AfterlifeAbility(final AfterlifeAbility ability) { + super(ability); + this.tokenCount = ability.tokenCount; + } + + @Override + public String getRule() { + return "Afterlife " + tokenCount + " (When this creature dies, create " + + CardUtil.numberToText(tokenCount, "a") + + " white and black Spirit creature token" + + (tokenCount > 1 ? "s" : "") + + " with flying)"; + } + + @Override + public AfterlifeAbility copy() { + return new AfterlifeAbility(this); + } +} diff --git a/Mage/src/main/java/mage/game/permanent/token/BeckonApparitionToken.java b/Mage/src/main/java/mage/game/permanent/token/BeckonApparitionToken.java deleted file mode 100644 index 199457fcc2..0000000000 --- a/Mage/src/main/java/mage/game/permanent/token/BeckonApparitionToken.java +++ /dev/null @@ -1,34 +0,0 @@ - - -package mage.game.permanent.token; -import mage.constants.CardType; -import mage.constants.SubType; -import mage.MageInt; -import mage.abilities.keyword.FlyingAbility; - -/** - * - * @author spjspj - */ -public final class BeckonApparitionToken extends TokenImpl { - - public BeckonApparitionToken() { - super("Spirit", "1/1 white and black Spirit creature token with flying"); - this.setOriginalExpansionSetCode("GTC"); - cardType.add(CardType.CREATURE); - color.setWhite(true); - color.setBlack(true); - subtype.add(SubType.SPIRIT); - power = new MageInt(1); - toughness = new MageInt(1); - this.addAbility(FlyingAbility.getInstance()); - } - public BeckonApparitionToken(final BeckonApparitionToken token) { - super(token); - } - - public BeckonApparitionToken copy() { - return new BeckonApparitionToken(this); - } - -} diff --git a/Mage/src/main/java/mage/game/permanent/token/TeysaEnvoyOfGhostsToken.java b/Mage/src/main/java/mage/game/permanent/token/WhiteBlackSpiritToken.java similarity index 67% rename from Mage/src/main/java/mage/game/permanent/token/TeysaEnvoyOfGhostsToken.java rename to Mage/src/main/java/mage/game/permanent/token/WhiteBlackSpiritToken.java index 19ccedcc36..7bf6156883 100644 --- a/Mage/src/main/java/mage/game/permanent/token/TeysaEnvoyOfGhostsToken.java +++ b/Mage/src/main/java/mage/game/permanent/token/WhiteBlackSpiritToken.java @@ -1,18 +1,18 @@ package mage.game.permanent.token; -import mage.constants.CardType; -import mage.constants.SubType; + import mage.MageInt; import mage.abilities.keyword.FlyingAbility; +import mage.constants.CardType; +import mage.constants.SubType; /** - * * @author spjspj */ -public final class TeysaEnvoyOfGhostsToken extends TokenImpl { +public final class WhiteBlackSpiritToken extends TokenImpl { - public TeysaEnvoyOfGhostsToken() { + public WhiteBlackSpiritToken() { super("Spirit", "1/1 white and black Spirit creature token with flying"); cardType.add(CardType.CREATURE); color.setWhite(true); @@ -23,11 +23,11 @@ public final class TeysaEnvoyOfGhostsToken extends TokenImpl { this.addAbility(FlyingAbility.getInstance()); } - public TeysaEnvoyOfGhostsToken(final TeysaEnvoyOfGhostsToken token) { + public WhiteBlackSpiritToken(final WhiteBlackSpiritToken token) { super(token); } - public TeysaEnvoyOfGhostsToken copy() { - return new TeysaEnvoyOfGhostsToken(this); + public WhiteBlackSpiritToken copy() { + return new WhiteBlackSpiritToken(this); } } diff --git a/Utils/keywords.txt b/Utils/keywords.txt index b965d6b3ae..c108ac7d90 100644 --- a/Utils/keywords.txt +++ b/Utils/keywords.txt @@ -1,4 +1,5 @@ Afflict|number| +Afterlife|number| Annihilator|number| Ascend|new| Assist|new|