mirror of
https://github.com/SPLURT-Station/S.P.L.U.R.T-Station-13.git
synced 2025-12-10 01:49:19 +00:00
Deadmin tweaks: Admins without +AUTOLOGIN start deadmined. AUTOLOGIN defaults to on.
This commit is contained in:
committed by
CitadelStationBot
parent
b11d1c024e
commit
55247e9bdf
@@ -638,12 +638,7 @@ GLOBAL_LIST_INIT(admin_verbs_hideable, list(
|
||||
if(has_antag_hud())
|
||||
toggle_antag_hud()
|
||||
|
||||
holder.disassociate()
|
||||
qdel(holder)
|
||||
|
||||
GLOB.deadmins += ckey
|
||||
GLOB.admin_datums -= ckey
|
||||
verbs += /client/proc/readmin
|
||||
holder.deactivate()
|
||||
|
||||
to_chat(src, "<span class='interface'>You are now a normal player.</span>")
|
||||
log_admin("[src] deadmined themself.")
|
||||
@@ -655,13 +650,20 @@ GLOBAL_LIST_INIT(admin_verbs_hideable, list(
|
||||
set category = "Admin"
|
||||
set desc = "Regain your admin powers."
|
||||
|
||||
load_admins(ckey)
|
||||
var/datum/admins/A = GLOB.deadmins[ckey]
|
||||
|
||||
if(!holder) // Something went wrong...
|
||||
return
|
||||
if(!A)
|
||||
A = GLOB.admin_datums[ckey]
|
||||
if (!A)
|
||||
var/msg = " is trying to readmin but they have no deadmin entry"
|
||||
message_admins("[key_name_admin(src)][msg]")
|
||||
log_admin_private("[key_name(src)][msg]")
|
||||
return
|
||||
|
||||
GLOB.deadmins -= ckey
|
||||
verbs -= /client/proc/readmin
|
||||
A.associate(src)
|
||||
|
||||
if (!holder)
|
||||
return //This can happen if an admin attempts to vv themself into somebody elses's deadmin datum by getting ref via brute force
|
||||
|
||||
to_chat(src, "<span class='interface'>You are now an admin.</span>")
|
||||
message_admins("[src] re-adminned themselves.")
|
||||
|
||||
Reference in New Issue
Block a user