mirror of
https://github.com/magefree/mage.git
synced 2025-12-24 12:31:59 -08:00
Fix ReturnToHandAttachedEffect with MDFCs (#10452)
* Add tests for ReturnToHandAttachedEffect * Temporary fix for returning attached MDFC to hand
This commit is contained in:
parent
a6c19c4335
commit
045bbbf04f
2 changed files with 230 additions and 1 deletions
|
|
@ -3,6 +3,7 @@ package mage.abilities.effects.common;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.ModalDoubleFacedCard;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.Zone;
|
||||
import mage.game.Game;
|
||||
|
|
@ -36,7 +37,8 @@ public class ReturnToHandAttachedEffect extends OneShotEffect {
|
|||
return false;
|
||||
}
|
||||
Card card = permanent.getMainCard();
|
||||
if (permanent.getZoneChangeCounter(game) + 1 != card.getZoneChangeCounter(game)) {
|
||||
// TODO: Once MDFC ZCC increments are fixed properly, can remove this special case. For now must allow so effect works.
|
||||
if (permanent.getZoneChangeCounter(game) + 1 != card.getZoneChangeCounter(game) && !(card instanceof ModalDoubleFacedCard)) {
|
||||
return false;
|
||||
}
|
||||
return player.moveCards(card, Zone.HAND, source, game);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue