diff --git a/proxy/src/main/java/net/md_5/bungee/ServerConnector.java b/proxy/src/main/java/net/md_5/bungee/ServerConnector.java index 9958d921..e79560ca 100644 --- a/proxy/src/main/java/net/md_5/bungee/ServerConnector.java +++ b/proxy/src/main/java/net/md_5/bungee/ServerConnector.java @@ -55,6 +55,19 @@ public class ServerConnector extends PacketHandler ENCRYPT_REQUEST, ENCRYPT_RESPONSE, LOGIN, FINISHED; } + @Override + public void exception(Throwable t) throws Exception + { + String message = "Exception Connectiong:" + Util.exception( t ); + if ( user.getServer() == null || user.getServer().isForgeWrapper() ) + { + user.disconnect( message ); + } else + { + user.sendMessage( ChatColor.RED + message ); + } + } + @Override public void connected(ChannelWrapper channel) throws Exception {