0
0
Fork 0
mirror of https://github.com/Sanae6/SmoOnlineServer.git synced 2024-11-25 04:35:18 +00:00

only show connected players in list command

This commit is contained in:
CraftyBoss 2022-04-27 04:43:46 +00:00
parent aea7d4414f
commit ff570a17c7

View file

@ -290,7 +290,7 @@ CommandHandler.RegisterCommand("tag", args => {
}
});
CommandHandler.RegisterCommand("list", _ => $"List: {string.Join("\n\t", server.Clients.Select(x => $"{x.Name} ({x.Id})"))}");
CommandHandler.RegisterCommand("list", _ => $"List: {string.Join("\n\t", server.Clients.Where(x => x.Connected).Select(x => $"{x.Name} ({x.Id})"))}");
CommandHandler.RegisterCommand("flip", args => {
const string optionUsage = "Valid options: \n\tlist\n\tadd <user id>\n\tremove <user id>\n\tset <true/false>\n\tpov <both/self/others>";