"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:
baloh.matevz
2011-09-19 06:12:00 +00:00
parent 089d548825
commit 7e73121ecd
3 changed files with 34 additions and 4 deletions

View File

@@ -73,6 +73,7 @@
// Admin game intrusion // Admin game intrusion
verbs += /client/proc/Getmob verbs += /client/proc/Getmob
verbs += /client/proc/Getkey
verbs += /client/proc/sendmob verbs += /client/proc/sendmob
verbs += /client/proc/Jump verbs += /client/proc/Jump
verbs += /client/proc/jumptokey verbs += /client/proc/jumptokey
@@ -172,6 +173,7 @@
verbs += /client/proc/Debug2 //debug toggle switch verbs += /client/proc/Debug2 //debug toggle switch
verbs += /client/proc/toggle_view_range verbs += /client/proc/toggle_view_range
verbs += /client/proc/Getmob verbs += /client/proc/Getmob
verbs += /client/proc/Getkey
verbs += /client/proc/sendmob verbs += /client/proc/sendmob
verbs += /client/proc/Jump verbs += /client/proc/Jump
verbs += /client/proc/jumptokey verbs += /client/proc/jumptokey
@@ -304,6 +306,7 @@
verbs -= /client/proc/Debug2 //debug toggle switch verbs -= /client/proc/Debug2 //debug toggle switch
verbs -= /client/proc/toggle_view_range verbs -= /client/proc/toggle_view_range
verbs -= /client/proc/Getmob verbs -= /client/proc/Getmob
verbs -= /client/proc/Getkey
verbs -= /client/proc/sendmob verbs -= /client/proc/sendmob
verbs -= /client/proc/Jump verbs -= /client/proc/Jump
verbs -= /client/proc/jumptokey verbs -= /client/proc/jumptokey

View File

@@ -79,6 +79,33 @@
else else
alert("Admin jumping disabled") 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) /client/proc/sendmob(var/mob/M in world, var/area/A in world)
set category = "Admin" set category = "Admin"
set name = "Send Mob" set name = "Send Mob"

View File

@@ -26,7 +26,7 @@
if(!class) if(!class)
return return
if(class == "marked datum ([holder.marked_datum.type])") if(holder.marked_datum && class == "marked datum ([holder.marked_datum.type])")
class = "marked datum" class = "marked datum"
var/var_value = null var/var_value = null
@@ -75,7 +75,7 @@
if(!class) if(!class)
return return
if(class == "marked datum ([holder.marked_datum.type])") if(holder.marked_datum && class == "marked datum ([holder.marked_datum.type])")
class = "marked datum" class = "marked datum"
var/var_value = null var/var_value = null
@@ -211,7 +211,7 @@
if(!class) if(!class)
return return
if(class == "marked datum ([holder.marked_datum.type])") if(holder.marked_datum && class == "marked datum ([holder.marked_datum.type])")
class = "marked datum" class = "marked datum"
switch(class) switch(class)
@@ -428,7 +428,7 @@
else else
original_name = O:name 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" class = "marked datum"
switch(class) switch(class)