mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 02:16:05 +00:00
"get key" verb for admins
Also fixed runtime errors related to the new 'mark object' thing. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2227 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -73,6 +73,7 @@
|
||||
|
||||
// Admin game intrusion
|
||||
verbs += /client/proc/Getmob
|
||||
verbs += /client/proc/Getkey
|
||||
verbs += /client/proc/sendmob
|
||||
verbs += /client/proc/Jump
|
||||
verbs += /client/proc/jumptokey
|
||||
@@ -172,6 +173,7 @@
|
||||
verbs += /client/proc/Debug2 //debug toggle switch
|
||||
verbs += /client/proc/toggle_view_range
|
||||
verbs += /client/proc/Getmob
|
||||
verbs += /client/proc/Getkey
|
||||
verbs += /client/proc/sendmob
|
||||
verbs += /client/proc/Jump
|
||||
verbs += /client/proc/jumptokey
|
||||
@@ -304,6 +306,7 @@
|
||||
verbs -= /client/proc/Debug2 //debug toggle switch
|
||||
verbs -= /client/proc/toggle_view_range
|
||||
verbs -= /client/proc/Getmob
|
||||
verbs -= /client/proc/Getkey
|
||||
verbs -= /client/proc/sendmob
|
||||
verbs -= /client/proc/Jump
|
||||
verbs -= /client/proc/jumptokey
|
||||
|
||||
@@ -79,6 +79,33 @@
|
||||
else
|
||||
alert("Admin jumping disabled")
|
||||
|
||||
/client/proc/Getkey()
|
||||
set category = "Admin"
|
||||
set name = "Get Key"
|
||||
set desc = "Key to teleport"
|
||||
|
||||
if(!src.authenticated || !src.holder)
|
||||
src << "Only administrators may use this command."
|
||||
return
|
||||
|
||||
if(config.allow_admin_jump)
|
||||
var/list/keys = list()
|
||||
for(var/mob/M in world)
|
||||
keys += M.client
|
||||
var/selection = input("Please, select a player!", "Admin Jumping", null, null) as null|anything in keys
|
||||
if(!selection)
|
||||
return
|
||||
var/mob/M = selection:mob
|
||||
|
||||
if(!M)
|
||||
return
|
||||
log_admin("[key_name(usr)] teleported [key_name(M)]")
|
||||
message_admins("[key_name_admin(usr)] teleported [key_name(M)]", 1)
|
||||
if(M)
|
||||
M.loc = get_turf(usr)
|
||||
else
|
||||
alert("Admin jumping disabled")
|
||||
|
||||
/client/proc/sendmob(var/mob/M in world, var/area/A in world)
|
||||
set category = "Admin"
|
||||
set name = "Send Mob"
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
if(!class)
|
||||
return
|
||||
|
||||
if(class == "marked datum ([holder.marked_datum.type])")
|
||||
if(holder.marked_datum && class == "marked datum ([holder.marked_datum.type])")
|
||||
class = "marked datum"
|
||||
|
||||
var/var_value = null
|
||||
@@ -75,7 +75,7 @@
|
||||
if(!class)
|
||||
return
|
||||
|
||||
if(class == "marked datum ([holder.marked_datum.type])")
|
||||
if(holder.marked_datum && class == "marked datum ([holder.marked_datum.type])")
|
||||
class = "marked datum"
|
||||
|
||||
var/var_value = null
|
||||
@@ -211,7 +211,7 @@
|
||||
if(!class)
|
||||
return
|
||||
|
||||
if(class == "marked datum ([holder.marked_datum.type])")
|
||||
if(holder.marked_datum && class == "marked datum ([holder.marked_datum.type])")
|
||||
class = "marked datum"
|
||||
|
||||
switch(class)
|
||||
@@ -428,7 +428,7 @@
|
||||
else
|
||||
original_name = O:name
|
||||
|
||||
if(class == "marked datum ([holder.marked_datum.type])")
|
||||
if(holder.marked_datum && class == "marked datum ([holder.marked_datum.type])")
|
||||
class = "marked datum"
|
||||
|
||||
switch(class)
|
||||
|
||||
Reference in New Issue
Block a user