mirror of
https://github.com/Citadel-Station-13/Citadel-Station-13-RP.git
synced 2026-08-31 12:26:58 +01:00
admin stealth mode now works while deadminned (#6630)
this is admittedly not a usual use of stealth mode but it's nice to not pop on/off the list when deadminned (this is nice for event rounds since you're supposed to deadmin if in a conflict role)
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
//* This file is explicitly licensed under the MIT license. *//
|
||||
//* Copyright (c) 2024 silicons *//
|
||||
|
||||
//* Stealthmin *//
|
||||
|
||||
/**
|
||||
* get effective ckey for render, respecting stealth keys
|
||||
*/
|
||||
/client/proc/get_public_key()
|
||||
return holder?.fakekey || deadmin_holder?.fakekey || key
|
||||
|
||||
/**
|
||||
* gets effective ckey & stealth key for render
|
||||
*/
|
||||
/client/proc/get_revealed_key()
|
||||
if(!(holder?.fakekey || deadmin_holder?.fakekey))
|
||||
return key
|
||||
var/fake_ckey = holder?.fakekey || deadmin_holder?.fakekey || "INVALID-KEY"
|
||||
return "[fake_ckey]/([key])"
|
||||
|
||||
/**
|
||||
* should we be under stealthmin
|
||||
*/
|
||||
/client/proc/is_under_stealthmin()
|
||||
return !!(holder?.fakekey || deadmin_holder?.fakekey)
|
||||
Reference in New Issue
Block a user