* UI: added playable card marks in look-at windows;

This commit is contained in:
Oleg Agafonov 2019-12-18 22:44:42 +04:00
parent ff1299cca9
commit cde9957f54
15 changed files with 200 additions and 122 deletions

View file

@ -142,7 +142,7 @@ public class PlayerPanelExt extends javax.swing.JPanel {
// can play
if (gameView != null && gameView.getCanPlayObjects() != null && !gameView.getCanPlayObjects().isEmpty()) {
for (CardView card : cards) {
if (gameView.getCanPlayObjects().contains(card.getId())) {
if (gameView.getCanPlayObjects().containsKey(card.getId())) {
return true;
}
}
@ -239,7 +239,7 @@ public class PlayerPanelExt extends javax.swing.JPanel {
Color commandColor = Color.BLACK;
for (CommandObjectView com : player.getCommandObjectList()) {
if (game != null && game.getCanPlayObjects() != null && game.getCanPlayObjects().contains(com.getId())) {
if (game != null && game.getCanPlayObjects() != null && game.getCanPlayObjects().containsKey(com.getId())) {
commandColor = activeValueColor;
break;
}
@ -269,7 +269,7 @@ public class PlayerPanelExt extends javax.swing.JPanel {
if (!MageFrame.isLite()) {
int id = player.getUserData().getAvatarId();
if (!(id >= 1000) && (id <= 0 || (id <= MIN_AVATAR_ID && id > MAX_AVATAR_ID))) {
if (!(id > 1000) && (id != 64) && (id < MIN_AVATAR_ID || id > MAX_AVATAR_ID)) {
id = DEFAULT_AVATAR_ID;
}
if (id != avatarId) {