* Elite Spellbinder - Fixed that the playable check for the exiled card did not check the required mana correctly.

This commit is contained in:
LevelX2 2021-08-03 16:32:59 +02:00
parent 2ecad7423e
commit 2134d004af

View file

@ -1,5 +1,6 @@
package mage.cards.e; package mage.cards.e;
import java.util.UUID;
import mage.MageInt; import mage.MageInt;
import mage.MageObjectReference; import mage.MageObjectReference;
import mage.abilities.Ability; import mage.abilities.Ability;
@ -20,8 +21,6 @@ import mage.target.common.TargetCardInHand;
import mage.target.common.TargetOpponent; import mage.target.common.TargetOpponent;
import mage.util.CardUtil; import mage.util.CardUtil;
import java.util.UUID;
/** /**
* @author TheElk801 * @author TheElk801
*/ */
@ -152,7 +151,13 @@ class EliteSpellbinderCostEffect extends CostModificationEffectImpl {
@Override @Override
public boolean applies(Ability abilityToModify, Ability source, Game game) { public boolean applies(Ability abilityToModify, Ability source, Game game) {
return mor.refersTo(CardUtil.getMainCardId(game, abilityToModify.getSourceId()), game); if (game.inCheckPlayableState()) { // during playable check, the card is still in exile zone, the zcc is one less
UUID cardtoCheckId = CardUtil.getMainCardId(game, abilityToModify.getSourceId());
return mor.getSourceId().equals(cardtoCheckId)
&& mor.getZoneChangeCounter() == game.getState().getZoneChangeCounter(cardtoCheckId) + 1;
} else {
return mor.refersTo(CardUtil.getMainCardId(game, abilityToModify.getSourceId()), game);
}
} }
@Override @Override