Some changes related to #4893.

This commit is contained in:
LevelX2 2018-05-03 01:33:21 +02:00
parent 9919a3403d
commit cddd81123b
37 changed files with 245 additions and 137 deletions

View file

@ -134,12 +134,15 @@ public final class ZonesHandler {
case STACK:
// There should never be more than one card here.
for (Card card : cards.getCards(game)) {
Spell spell;
if (info instanceof ZoneChangeInfo.Stack && ((ZoneChangeInfo.Stack) info).spell != null) {
game.getStack().push(((ZoneChangeInfo.Stack) info).spell);
spell = ((ZoneChangeInfo.Stack) info).spell;
} else {
game.getStack().push(
new Spell(card, card.getSpellAbility().copy(), card.getOwnerId(), event.getFromZone()));
spell = new Spell(card, card.getSpellAbility().copy(), card.getOwnerId(), event.getFromZone());
}
game.getStack().push(spell);
game.getState().setZone(spell.getId(), Zone.STACK);
game.getState().setZone(card.getId(), Zone.STACK);
}
break;
case BATTLEFIELD: