diff --git a/code/__HELPERS/_logging.dm b/code/__HELPERS/_logging.dm index 7fc2bee5074c..0a6f36c7fed8 100644 --- a/code/__HELPERS/_logging.dm +++ b/code/__HELPERS/_logging.dm @@ -183,6 +183,9 @@ GLOBAL_PROTECT(log_end) /proc/log_chat_debug(text) rustg_log_write(GLOB.chat_debug_log, "[text][GLOB.log_end]") +/proc/log_jobs(text) + rustg_log_write(GLOB.jobs_log, "[text][GLOB.log_end]") + // A logging proc that only outputs after setup is done, to // help devs test initialization stuff that happens a lot /proc/log_after_setup(message) diff --git a/code/_globalvars/logging_vars.dm b/code/_globalvars/logging_vars.dm index 1e448d1be029..686a1d140d8d 100644 --- a/code/_globalvars/logging_vars.dm +++ b/code/_globalvars/logging_vars.dm @@ -21,6 +21,8 @@ GLOBAL_VAR(sql_log) GLOBAL_PROTECT(sql_log) GLOBAL_VAR(chat_debug_log) GLOBAL_PROTECT(chat_debug_log) +GLOBAL_VAR(jobs_log) +GLOBAL_PROTECT(jobs_log) GLOBAL_VAR(round_id) GLOBAL_PROTECT(round_id) diff --git a/code/controllers/subsystem/SSjobs.dm b/code/controllers/subsystem/SSjobs.dm index f6d28cbdde64..599f659ce92b 100644 --- a/code/controllers/subsystem/SSjobs.dm +++ b/code/controllers/subsystem/SSjobs.dm @@ -61,6 +61,7 @@ SUBSYSTEM_DEF(jobs) /datum/controller/subsystem/jobs/proc/Debug(text) job_debug.Add(text) + log_jobs(text) /datum/controller/subsystem/jobs/proc/GetJob(rank) if(!length(occupations)) diff --git a/code/game/world.dm b/code/game/world.dm index e934067c0844..482b9a1160a5 100644 --- a/code/game/world.dm +++ b/code/game/world.dm @@ -260,6 +260,7 @@ GLOBAL_LIST_EMPTY(world_topic_handlers) GLOB.http_log = "[GLOB.log_directory]/http.log" GLOB.sql_log = "[GLOB.log_directory]/sql.log" GLOB.chat_debug_log = "[GLOB.log_directory]/chat_debug.log" + GLOB.jobs_log = "[GLOB.log_directory]/jobs_log.log" start_log(GLOB.world_game_log) start_log(GLOB.world_href_log) start_log(GLOB.world_runtime_log) @@ -268,6 +269,7 @@ GLOBAL_LIST_EMPTY(world_topic_handlers) start_log(GLOB.http_log) start_log(GLOB.sql_log) start_log(GLOB.chat_debug_log) + start_log(GLOB.jobs_log) #ifdef REFERENCE_TRACKING GLOB.gc_log = "[GLOB.log_directory]/gc_debug.log"