mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
Adds admin verbs for debugging process controllers
* Adds a verb for debugging any of the running process controllers. Unlike the old debug controller verb, this one is not hard coded, so any present and future processes will be included. Requires R_DEBUG (and R_ADMIN if in paranoid mode) * Adds a verb for debugging the process scheduler itself. This is hidden by default until debug verbs are shown. Requires R_DEBUG (and R_ADMIN if in paranoid mode)
This commit is contained in:
@@ -100,3 +100,26 @@
|
||||
feedback_add_details("admin_verb", "DXenobio")
|
||||
message_admins("Admin [key_name_admin(usr)] is debugging the [controller] controller.")
|
||||
return
|
||||
|
||||
/client/proc/debug_process_scheduler()
|
||||
set category = "Debug"
|
||||
set name = "Debug Process Scheduler"
|
||||
set desc = "Debug the process scheduler itself. For vulpine use only."
|
||||
|
||||
if(!check_rights(R_DEBUG)) return
|
||||
if(config.debugparanoid && !check_rights(R_ADMIN)) return
|
||||
debug_variables(processScheduler)
|
||||
feedback_add_details("admin_verb", "DProcSchd")
|
||||
message_admins("Admin [key_name_admin(usr)] is debugging the process scheduler.")
|
||||
|
||||
/client/proc/debug_process(controller in processScheduler.nameToProcessMap)
|
||||
set category = "Debug"
|
||||
set name = "Debug Process Controller"
|
||||
set desc = "Debug one of the periodic loop background task controllers for the game (be careful!)"
|
||||
|
||||
if(!check_rights(R_DEBUG)) return
|
||||
if(config.debugparanoid && !check_rights(R_ADMIN)) return
|
||||
var/datum/controller/process/P = processScheduler.nameToProcessMap[controller]
|
||||
debug_variables(P)
|
||||
feedback_add_details("admin_verb", "DProcCtrl")
|
||||
message_admins("Admin [key_name_admin(usr)] is debugging the [controller] controller.")
|
||||
|
||||
Reference in New Issue
Block a user