From 314151e082ac236aebfd57f688614940f59cc327 Mon Sep 17 00:00:00 2001 From: tgstation-server Date: Mon, 6 Nov 2023 00:48:50 +0000 Subject: [PATCH] Update TGS DMAPI --- code/__DEFINES/tgs.dm | 2 +- code/modules/tgs/core/datum.dm | 9 +++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/code/__DEFINES/tgs.dm b/code/__DEFINES/tgs.dm index d468d6044196..0cc106ec9cf2 100644 --- a/code/__DEFINES/tgs.dm +++ b/code/__DEFINES/tgs.dm @@ -1,6 +1,6 @@ // tgstation-server DMAPI -#define TGS_DMAPI_VERSION "6.6.1" +#define TGS_DMAPI_VERSION "6.6.2" // All functions and datums outside this document are subject to change with any version and should not be relied on. diff --git a/code/modules/tgs/core/datum.dm b/code/modules/tgs/core/datum.dm index de420a2a325a..07ce3b684584 100644 --- a/code/modules/tgs/core/datum.dm +++ b/code/modules/tgs/core/datum.dm @@ -12,8 +12,13 @@ TGS_DEFINE_AND_SET_GLOBAL(tgs, null) src.version = version /datum/tgs_api/proc/TerminateWorld() - del(world) - sleep(1) // https://www.byond.com/forum/post/2894866 + while(TRUE) + TGS_DEBUG_LOG("About to terminate world. Tick: [world.time], sleep_offline: [world.sleep_offline]") + world.sleep_offline = FALSE // https://www.byond.com/forum/post/2894866 + del(world) + world.sleep_offline = FALSE // just in case, this is BYOND after all... + sleep(1) + TGS_DEBUG_LOG("BYOND DIDN'T TERMINATE THE WORLD!!! TICK IS: [world.time], sleep_offline: [world.sleep_offline]") /datum/tgs_api/latest parent_type = /datum/tgs_api/v5