From 5d32c2f8d2a7f8717695c529e0003bd0a991f36a Mon Sep 17 00:00:00 2001 From: Contrabang <91113370+Contrabang@users.noreply.github.com> Date: Sat, 8 Feb 2025 13:44:17 -0500 Subject: [PATCH] Improves runtime info during admin proc calls (#28279) --- code/modules/admin/verbs/debug.dm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/code/modules/admin/verbs/debug.dm b/code/modules/admin/verbs/debug.dm index 86f792611c5..92afaef5286 100644 --- a/code/modules/admin/verbs/debug.dm +++ b/code/modules/admin/verbs/debug.dm @@ -121,10 +121,10 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention) CRASH("WrapAdminProcCall with no ckey: [target] [procname] [english_list(arguments)]") if(current_caller && current_caller != ckey) if(!GLOB.AdminProcCallSpamPrevention[ckey]) - to_chat(usr, "Another set of admin called procs are still running, your proc will be run after theirs finish.") + to_chat(usr, "Another set of admin called procs are still running, your proc will be run after theirs finish.") GLOB.AdminProcCallSpamPrevention[ckey] = TRUE UNTIL(!GLOB.AdminProcCaller) - to_chat(usr, "Running your proc") + to_chat(usr, "Running your proc") GLOB.AdminProcCallSpamPrevention -= ckey else UNTIL(!GLOB.AdminProcCaller) @@ -135,8 +135,8 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention) ++GLOB.AdminProcCallCount try . = world.WrapAdminProcCall(target, procname, arguments) - catch - to_chat(usr, "Your proc call failed to execute, likely from runtimes. You should be out of safety mode. If not, god help you.") + catch(var/exception/e) + to_chat(usr, "Your proc call failed to execute, likely from runtimes. You should be out of safety mode. If not, god help you. Runtime Info: [e.file]:[e.line]: [e.name]") if(--GLOB.AdminProcCallCount == 0) GLOB.AdminProcCaller = null