From f92e827d3bd6213ee5d6730a6c1b9bca2b1fabdf Mon Sep 17 00:00:00 2001 From: LevelX2 Date: Sun, 9 Oct 2016 00:13:01 +0200 Subject: [PATCH] Xmage 1.4.16v2 --- Mage.Common/src/mage/remote/SessionImpl.java | 24 +++++++++++++------- Mage.Common/src/mage/utils/MageVersion.java | 2 +- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/Mage.Common/src/mage/remote/SessionImpl.java b/Mage.Common/src/mage/remote/SessionImpl.java index 3107855de32..ef1a1d40a8e 100644 --- a/Mage.Common/src/mage/remote/SessionImpl.java +++ b/Mage.Common/src/mage/remote/SessionImpl.java @@ -676,8 +676,10 @@ public class SessionImpl implements Session { try { if (isConnected()) { // Workaround to fix Can't join table problem - deckList.setCardLayout(null); - deckList.setSideboardLayout(null); + if (deckList != null) { + deckList.setCardLayout(null); + deckList.setSideboardLayout(null); + } return server.joinTable(sessionId, roomId, tableId, playerName, playerType, skill, deckList, password); } } catch (InvalidDeckException iex) { @@ -697,8 +699,10 @@ public class SessionImpl implements Session { try { if (isConnected()) { // Workaround to fix Can't join table problem - deckList.setCardLayout(null); - deckList.setSideboardLayout(null); + if (deckList != null) { + deckList.setCardLayout(null); + deckList.setSideboardLayout(null); + } return server.joinTournamentTable(sessionId, roomId, tableId, playerName, playerType, skill, deckList, password); } } catch (GameException ex) { @@ -1182,8 +1186,10 @@ public class SessionImpl implements Session { try { if (isConnected()) { // Workaround to fix Can't join table problem - deck.setCardLayout(null); - deck.setSideboardLayout(null); + if (deck != null) { + deck.setCardLayout(null); + deck.setSideboardLayout(null); + } return server.submitDeck(sessionId, tableId, deck); } } catch (GameException ex) { @@ -1200,8 +1206,10 @@ public class SessionImpl implements Session { public boolean updateDeck(UUID tableId, DeckCardLists deck) { try { if (isConnected()) { - deck.setCardLayout(null); - deck.setSideboardLayout(null); + if (deck != null) { + deck.setCardLayout(null); + deck.setSideboardLayout(null); + } server.updateDeck(sessionId, tableId, deck); return true; } diff --git a/Mage.Common/src/mage/utils/MageVersion.java b/Mage.Common/src/mage/utils/MageVersion.java index 378d61319f1..097568e5d41 100644 --- a/Mage.Common/src/mage/utils/MageVersion.java +++ b/Mage.Common/src/mage/utils/MageVersion.java @@ -41,7 +41,7 @@ public class MageVersion implements Serializable, Comparable { public final static int MAGE_VERSION_MAJOR = 1; public final static int MAGE_VERSION_MINOR = 4; public final static int MAGE_VERSION_PATCH = 16; - public final static String MAGE_VERSION_MINOR_PATCH = "v1"; + public final static String MAGE_VERSION_MINOR_PATCH = "v2"; public final static String MAGE_VERSION_INFO = ""; private final int major;