diff --git a/code/world.dm b/code/world.dm index 34d61dbbc21..e293058cdf6 100644 --- a/code/world.dm +++ b/code/world.dm @@ -244,6 +244,27 @@ var/world_topic_spam_protect_time = world.timeofday for(var/client/C in clients) to_chat(C, "PR: [input["announce"]]") + else if("kick" in input) + /* + We have a kick request over coms. + Only needed portion is the ckey + */ + if(!key_valid) + return keySpamProtect(addr) + + var/client/C + + for(var/client/K in clients) + if(K.ckey == input["kick"]) + C = K + break + if(!C) + return "No client with that name on server" + + del(C) + + return "Kick Successful" + /proc/keySpamProtect(var/addr) if(world_topic_spam_protect_ip == addr && abs(world_topic_spam_protect_time - world.time) < 50) spawn(50)