More startup error handling

- Pass minecraft login failure message to AutoRelog bot (suggestion by
doranchak)
- Fix NullReferenceException in McTcpClient caused by SocketException in
ProxyHandler
- Refactor error handling code in Program.InitializeClient()
- More detailed error messages on network errors.
This commit is contained in:
ORelio 2015-04-20 17:26:16 +02:00
parent 791ecba454
commit 6261e7adb7
5 changed files with 48 additions and 58 deletions

View file

@ -62,5 +62,15 @@ namespace MinecraftClient.ChatBots
}
return false;
}
public static bool OnDisconnectStatic(DisconnectReason reason, string message)
{
if (Settings.AutoRelog_Enabled)
{
AutoRelog bot = new AutoRelog(Settings.AutoRelog_Delay, Settings.AutoRelog_Retries);
return bot.OnDisconnect(reason, message);
}
return false;
}
}
}