mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Allow AutoRelog to relog on server login failed
- Add some explanations for adding a custom bot in the app - Remove debug code in ConsoleIO (see previous commit)
This commit is contained in:
parent
a543620a80
commit
09bff17fc2
4 changed files with 15 additions and 12 deletions
|
|
@ -119,7 +119,7 @@ namespace MinecraftClient
|
|||
else
|
||||
{
|
||||
Console.WriteLine("Login failed.");
|
||||
if (!singlecommand) { Program.ReadLineReconnect(); }
|
||||
if (!singlecommand && !handler.OnConnectionLost(ChatBot.DisconnectReason.LoginRejected, "Login failed.")) { Program.ReadLineReconnect(); }
|
||||
}
|
||||
}
|
||||
catch (SocketException)
|
||||
|
|
@ -235,7 +235,7 @@ namespace MinecraftClient
|
|||
if (!handler.HasBeenKicked)
|
||||
{
|
||||
ConsoleIO.WriteLine("Connection has been lost.");
|
||||
if (!handler.OnConnectionLost() && !Program.ReadLineReconnect()) { t_sender.Abort(); }
|
||||
if (!handler.OnConnectionLost(ChatBot.DisconnectReason.ConnectionLost, "Connection has been lost.") && !Program.ReadLineReconnect()) { t_sender.Abort(); }
|
||||
}
|
||||
else if (Program.ReadLineReconnect()) { t_sender.Abort(); }
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue