diff --git a/Plugins/Mineplex.Core/src/mineplex/core/account/repository/AccountRepository.java b/Plugins/Mineplex.Core/src/mineplex/core/account/repository/AccountRepository.java index daea474e6..e30cabf81 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/account/repository/AccountRepository.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/account/repository/AccountRepository.java @@ -113,8 +113,19 @@ public class AccountRepository extends MinecraftRepository for (ILoginProcessor loginProcessor : loginProcessors) { - loginProcessor.processLoginResultSet(name, uuid, finalId, statement.getResultSet()); - statement.getMoreResults(); + try + { + loginProcessor.processLoginResultSet(name, uuid, finalId, statement.getResultSet()); + } + catch (Throwable t) + { + System.out.println("Error: ILoginProcessor raised an exception"); + t.printStackTrace(System.out); + } + finally + { + statement.getMoreResults(); + } } } diff --git a/Plugins/Mineplex.Core/src/mineplex/core/disguise/playerdisguise/PlayerDisguiseManager.java b/Plugins/Mineplex.Core/src/mineplex/core/disguise/playerdisguise/PlayerDisguiseManager.java index 317d6cc26..4c7e16502 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/disguise/playerdisguise/PlayerDisguiseManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/disguise/playerdisguise/PlayerDisguiseManager.java @@ -300,6 +300,10 @@ public class PlayerDisguiseManager extends MiniPlugin implements IPacketHandler { Player player = Bukkit.getPlayerExact(data.a().getName()); + // Would be null during login, we don't care + // LoginListener -> PlayerList#a(NetworkManager, EntityPlayer) + // -> PlayerList#a(EntityPlayer, EntityPlayer, WorldServer) (Sends this packet) + // -> PlayerList#onPlayerJoin(EntityPlayer, String) (Populates Bukkit.getPlayerExact) if (player != null) { if (isDisguised(player)) @@ -313,10 +317,6 @@ public class PlayerDisguiseManager extends MiniPlugin implements IPacketHandler ((CraftPlayer) player).getHandle().playerConnection.networkManager.handle(custom); } } - else - { - System.out.println("Null player while sending PlayerInfoData: " + data.a().getName()); - } } } } diff --git a/Plugins/Mineplex.Core/src/mineplex/core/mavericks/MavericksApprovedRepository.java b/Plugins/Mineplex.Core/src/mineplex/core/mavericks/MavericksApprovedRepository.java index 02f52eb33..f99c77b8f 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/mavericks/MavericksApprovedRepository.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/mavericks/MavericksApprovedRepository.java @@ -92,9 +92,9 @@ public class MavericksApprovedRepository long approvedDate = set.getLong(2); UUID approvedBy = UUID.fromString(set.getString(3)); boolean display = set.getBoolean(4); - Timestamp stamp = set.getTimestamp(1); + Timestamp stamp = set.getTimestamp(5); Long firstDisplayed = null; - if(!set.wasNull() && stamp != null) stamp.getTime(); + if(!set.wasNull() && stamp != null) firstDisplayed = stamp.getTime(); String theme = set.getString(6); diff --git a/Plugins/Mineplex.Core/src/mineplex/core/playwire/PlayWireManager.java b/Plugins/Mineplex.Core/src/mineplex/core/playwire/PlayWireManager.java index ee2b52741..ad57096a7 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/playwire/PlayWireManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/playwire/PlayWireManager.java @@ -39,7 +39,7 @@ public class PlayWireManager extends MiniDbClientPlugin @Override public String getQuery(int accountId, String uuid, String name) { - return "SELECT `redeemed` FROM `play_wire` WHERE `accountId`=" + accountId + ";"; + return "SELECT `redeemed`, `streak` FROM `play_wire` WHERE `accountId`=" + accountId + ";"; } public boolean canRedeem(Player player) diff --git a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerInfo.java b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerInfo.java index eee657553..8e562b866 100644 --- a/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerInfo.java +++ b/Plugins/Mineplex.Hub/src/mineplex/hub/server/ServerInfo.java @@ -14,7 +14,7 @@ public class ServerInfo public String Game; public Rank HostRank = Rank.ALL; public MinecraftServer Server; - + public int getAvailableSlots() { return MaxPlayers - CurrentPlayers; @@ -22,6 +22,19 @@ public class ServerInfo public boolean isDevServer() { - return Name.contains("-Dev-"); + try + { + int index = Name.lastIndexOf('-'); + if (index != -1) + { + int id = Integer.parseInt(Name.substring(index + 1)); + return id >= 777; + } + } + catch (NumberFormatException ex) + { + return false; + } + return false; } } \ No newline at end of file diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java index 1a6af4347..b03de4b36 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/ArcadeManager.java @@ -437,11 +437,8 @@ public class ArcadeManager extends MiniPlugin implements IRelation _gameLobbyManager.AddPlayerToScoreboards(onlinePlayer, gameTeam); } - System.out.println("Handling player join " + playerName + " " + player.getName() + " " + GetGame()); - if (GetGame() != null) { - System.out.println(GetGame().IsAlive(player)); if (GetGame().IsAlive(player)) { GetGame().GetScoreboard().setPlayerTeam(player, GetGame().GetTeam(player));