mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Add /list support in Protocol16
Removed fallback to server /list command
This commit is contained in:
parent
8d16f1ec89
commit
8e458f7ab9
2 changed files with 7 additions and 9 deletions
|
|
@ -12,14 +12,7 @@ namespace MinecraftClient.Commands
|
|||
|
||||
public override string Run(McTcpClient handler, string command)
|
||||
{
|
||||
string[] onlinePlayers = handler.getOnlinePlayers();
|
||||
if (onlinePlayers.Length == 0) //Not properly handled by Protocol handler?
|
||||
{
|
||||
//Fallback to server /list command
|
||||
handler.SendText("/list");
|
||||
return "";
|
||||
}
|
||||
else return "PlayerList: " + String.Join(", ", onlinePlayers);
|
||||
return "PlayerList: " + String.Join(", ", handler.getOnlinePlayers());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue