Merge pull request #3677 from Tastyfish/big-brother-is-watching

Adds verb for super secret administration
This commit is contained in:
Fox McCloud
2016-02-24 03:40:32 -05:00
3 changed files with 36 additions and 1 deletions

View File

@@ -10,6 +10,9 @@
if(check_rights(R_ADMIN,0))
for(var/client/C in clients)
if(C.holder && C.holder.big_brother && !check_rights(R_PERMISSIONS, 0)) // need PERMISSIONS to see BB
continue
var/entry = "\t[C.key]"
if(C.holder && C.holder.fakekey)
entry += " <i>(as [C.holder.fakekey])</i>"
@@ -48,6 +51,9 @@
Lines += entry
else
for(var/client/C in clients)
if(C.holder && C.holder.big_brother) // BB doesn't show up at all
continue
if(C.holder && C.holder.fakekey)
Lines += C.holder.fakekey
else
@@ -73,6 +79,9 @@
if(C.holder.fakekey && !check_rights(R_ADMIN, 0)) //Mentors/Mods can't see stealthmins
continue
if(C.holder.big_brother && !check_rights(R_PERMISSIONS, 0)) // normal admins can't see BB
continue
msg += "\t[C] is a [C.holder.rank]"

View File

@@ -160,7 +160,8 @@ var/list/admin_verbs_possess = list(
)
var/list/admin_verbs_permissions = list(
/client/proc/edit_admin_permissions,
/client/proc/create_poll
/client/proc/create_poll,
/client/proc/big_brother
)
var/list/admin_verbs_rejuv = list(
/client/proc/respawn_character,
@@ -428,6 +429,7 @@ var/list/admin_verbs_proccall = list (
return
if(holder)
holder.big_brother = 0
if(holder.fakekey)
holder.fakekey = null
else
@@ -441,6 +443,29 @@ var/list/admin_verbs_proccall = list (
message_admins("[key_name_admin(usr)] has turned stealth mode [holder.fakekey ? "ON" : "OFF"]", 1)
feedback_add_details("admin_verb","SM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/proc/big_brother()
set category = "Admin"
set name = "Big Brother Mode"
if(!check_rights(R_PERMISSIONS))
return
if(holder)
if(holder.fakekey)
holder.fakekey = null
holder.big_brother = 0
else
var/new_key = ckeyEx(input("Enter your desired display name. Unlike normal stealth mode, this will not appear in Who at all, except for other heads.", "Fake Key", key) as text|null)
if(!new_key)
return
if(length(new_key) >= 26)
new_key = copytext(new_key, 1, 26)
holder.fakekey = new_key
holder.big_brother = 1
createStealthKey()
log_admin("[key_name(usr)] has turned BB mode [holder.fakekey ? "ON" : "OFF"]")
feedback_add_details("admin_verb","BBSM")
#define MAX_WARNS 3
#define AUTOBANTIME 10

View File

@@ -5,6 +5,7 @@ var/list/admin_datums = list()
var/client/owner = null
var/rights = 0
var/fakekey = null
var/big_brother = 0
var/datum/marked_datum