Fixed that no abilitues were shown for selecting the order of triggered abilities from a dies triggered ability of tokens.

This commit is contained in:
LevelX2 2016-10-02 23:34:06 +02:00
parent 6554102367
commit c4b4804903
2 changed files with 10 additions and 3 deletions

View file

@ -1177,7 +1177,7 @@ public final class GamePanel extends javax.swing.JPanel {
}
}
updateGame(gameView);
Map<String, Serializable> options0 = options == null ? new HashMap<String, Serializable>() : options;
Map<String, Serializable> options0 = options == null ? new HashMap<>() : options;
ShowCardsDialog dialog = null;
if (cardView != null && cardView.size() > 0) {
dialog = showCards(message, cardView, required, options0, popupMenuType);
@ -2346,7 +2346,6 @@ public final class GamePanel extends javax.swing.JPanel {
return gameChatPanel.getText();
}
public Map<String, Card> getLoadedCards() {
return loadedCards;
}

View file

@ -42,6 +42,7 @@ import mage.game.Game;
import mage.game.GameState;
import mage.game.command.Emblem;
import mage.game.permanent.Permanent;
import mage.game.permanent.PermanentToken;
import mage.target.targetpointer.TargetPointer;
import mage.util.GameLog;
@ -86,7 +87,14 @@ public class CardsView extends LinkedHashMap<UUID, CardView> {
if (sourceObject == null) {
sourceObject = game.getPermanent(ability.getSourceId());
}
isCard = true;
if (sourceObject == null) {
sourceObject = game.getObject(ability.getSourceId());
if (sourceObject instanceof PermanentToken) {
isPermanent = true;
}
} else {
isCard = true;
}
break;
case BATTLEFIELD:
sourceObject = game.getPermanent(ability.getSourceId());