Added three utilities for admins & developers

- There is a new option in the player panel labeled "Send back to
   Lobby", which will send a given player back to the lobby.
 - The player panel also has a shortcut to the "Spawn Character" verb.
 - Finally, there's a new config option that disables the warning
   message about multikeying if two mobs with the same CID are found;
   this option should NOT be enabled if multikeying is prohibited by the
   server rules. It is simply a developer tool, as multikeying is
   sometimes necessary to test new features that require two clients
   interacting.
This commit is contained in:
ShadowLarkens
2020-03-27 15:22:17 -07:00
parent dfda8ea952
commit 777f56e86c
6 changed files with 54 additions and 4 deletions

View File

@@ -1035,6 +1035,29 @@
log_admin("[key_name(usr)] sent [key_name(M)] to the prison station.")
message_admins("<font color='blue'>[key_name_admin(usr)] sent [key_name_admin(M)] to the prison station.</font>", 1)
else if(href_list["sendbacktolobby"])
if(!check_rights(R_ADMIN))
return
var/mob/M = locate(href_list["sendbacktolobby"])
if(!isobserver(M))
to_chat(usr, "<span class='notice'>You can only send ghost players back to the Lobby.</span>")
return
if(!M.client)
to_chat(usr, "<span class='warning'>[M] doesn't seem to have an active client.</span>")
return
if(alert(usr, "Send [key_name(M)] back to Lobby?", "Message", "Yes", "No") != "Yes")
return
log_admin("[key_name(usr)] has sent [key_name(M)] back to the Lobby.")
message_admins("[key_name(usr)] has sent [key_name(M)] back to the Lobby.")
var/mob/new_player/NP = new()
NP.ckey = M.ckey
qdel(M)
else if(href_list["tdome1"])
if(!check_rights(R_FUN)) return
@@ -1193,6 +1216,15 @@
usr.client.cmd_admin_animalize(M)
else if(href_list["respawn"])
if(!check_rights(R_SPAWN))
return
var/client/C = locate(href_list["respawn"])
if(!istype(C))
return
usr.client.respawn_character_proper(C)
else if(href_list["togmutate"])
if(!check_rights(R_SPAWN)) return