- When clients in the lobby are kicked at round end, only afk clients actually get kicked.

- The admins now have the ability to kick all or just afk clients from the lobby
- When admins use this action, a list of kicked clients is sent to admins and into the log.
- Added a confirmation message to the admin command.
This commit is contained in:
errorage
2013-08-07 18:09:38 +02:00
parent 134ba32236
commit c32f56e750
5 changed files with 23 additions and 9 deletions

View File

@@ -842,10 +842,17 @@ proc/move_ferry()
else
ferry_location = 1
proc/kick_clients_in_lobby(var/message)
//Kicks all the clients currently in the lobby. The second parameter (kick_only_afk) determins if an is_afk() check is ran, or if all clients are kicked
//defaults to kicking everyone (afk + non afk clients in the lobby)
//returns a list of ckeys of the kicked clients
proc/kick_clients_in_lobby(var/message, var/kick_only_afk = 0)
var/list/kicked_client_names = list()
for(var/client/C in clients)
if(istype(C.mob, /mob/new_player))
if(kick_only_afk && !C.is_afk()) //Ignore clients who are not afk
continue
if(message)
C << message
del(C)
kicked_client_names.Add("[C.ckey]")
del(C)
return kicked_client_names