Files
VOREStation/code/modules/admin/ckey_vr.dm
Kashargul 4879a52633 Server maint subsystem (#16518)
* upports server maint subsystem

* fix runtime in admin z narrate

* .

* sorts them verbs

* .

* .

* Update code/controllers/subsystems/statpanel.dm

Co-authored-by: Selis <12716288+ItsSelis@users.noreply.github.com>

* Update code/controllers/subsystems/server_maint.dm

Co-authored-by: Selis <12716288+ItsSelis@users.noreply.github.com>

---------

Co-authored-by: Selis <12716288+ItsSelis@users.noreply.github.com>
2024-11-04 11:44:44 +01:00

21 lines
832 B
Plaintext

// Command to set the ckey of a mob without requiring VV permission
/client/proc/SetCKey(var/mob/M in mob_list)
set category = "Admin.Game"
set name = "Set CKey"
set desc = "Mob to teleport"
if(!src.holder)
to_chat(src, "Only administrators may use this command.")
return
var/list/keys = list()
for(var/mob/playerMob in player_list)
keys += playerMob.client
var/client/selection = tgui_input_list(usr, "Please, select a player!", "Set CKey", sortKey(keys))
if(!selection || !istype(selection))
return
log_admin("[key_name(usr)] set ckey of [key_name(M)] to [selection]")
message_admins("[key_name_admin(usr)] set ckey of [key_name_admin(M)] to [selection]", 1)
M.ckey = selection.ckey
feedback_add_details("admin_verb","SCK") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!