From dd72e078b51d1099610fc9904f7611b0a95516cd Mon Sep 17 00:00:00 2001 From: Oleg Agafonov Date: Sat, 5 Feb 2022 14:26:28 +0400 Subject: [PATCH] [VOW] Dorothea's Retribution - fixed wrong token --- .../mage/cards/d/DorotheasRetribution.java | 4 +- .../DorotheasRetributionSpiritToken.java | 45 +++++++++++++++++++ 2 files changed, 47 insertions(+), 2 deletions(-) create mode 100644 Mage/src/main/java/mage/game/permanent/token/DorotheasRetributionSpiritToken.java diff --git a/Mage.Sets/src/mage/cards/d/DorotheasRetribution.java b/Mage.Sets/src/mage/cards/d/DorotheasRetribution.java index 9e0daae471..8a83731516 100644 --- a/Mage.Sets/src/mage/cards/d/DorotheasRetribution.java +++ b/Mage.Sets/src/mage/cards/d/DorotheasRetribution.java @@ -18,7 +18,7 @@ import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.SubType; import mage.game.Game; -import mage.game.permanent.token.AngelToken; +import mage.game.permanent.token.DorotheasRetributionSpiritToken; import mage.game.permanent.token.Token; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -86,7 +86,7 @@ class DorotheasRetributionEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Token token = new AngelToken(); + Token token = new DorotheasRetributionSpiritToken(); token.putOntoBattlefield(1, game, source, source.getControllerId(), true, true); game.addDelayedTriggeredAbility(new AtTheEndOfCombatDelayedTriggeredAbility( new SacrificeTargetEffect() diff --git a/Mage/src/main/java/mage/game/permanent/token/DorotheasRetributionSpiritToken.java b/Mage/src/main/java/mage/game/permanent/token/DorotheasRetributionSpiritToken.java new file mode 100644 index 0000000000..de468ca1d1 --- /dev/null +++ b/Mage/src/main/java/mage/game/permanent/token/DorotheasRetributionSpiritToken.java @@ -0,0 +1,45 @@ +package mage.game.permanent.token; + +import mage.MageInt; +import mage.abilities.keyword.FlyingAbility; +import mage.constants.CardType; +import mage.constants.SubType; + +import java.util.Arrays; + +/** + * @author JayDi85 + */ +public final class DorotheasRetributionSpiritToken extends TokenImpl { + + public DorotheasRetributionSpiritToken() { + super("Spirit", "4/4 white Spirit creature token with flying"); + cardType.add(CardType.CREATURE); + subtype.add(SubType.SPIRIT); + color.setWhite(true); + power = new MageInt(4); + toughness = new MageInt(4); + + this.addAbility(FlyingAbility.getInstance()); + + availableImageSetCodes = Arrays.asList("VOW"); + } + + @Override + public void setExpansionSetCodeForImage(String code) { + super.setExpansionSetCodeForImage(code); + + if (getOriginalExpansionSetCode() != null && getOriginalExpansionSetCode().equals("VOW")) { + setTokenType(2); + } + } + + public DorotheasRetributionSpiritToken(final DorotheasRetributionSpiritToken token) { + super(token); + } + + @Override + public DorotheasRetributionSpiritToken copy() { + return new DorotheasRetributionSpiritToken(this); + } +}