mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
Bandaid for the TGS4 Linux trusted mode bug (#41668)
* Hack for the TGS4 Linux trusted mode bug * Simpler
This commit is contained in:
committed by
yogstation13-bot
parent
5e7e0ee759
commit
f89bfb448d
@@ -1,6 +1,8 @@
|
|||||||
#define RESTART_COUNTER_PATH "data/round_counter.txt"
|
#define RESTART_COUNTER_PATH "data/round_counter.txt"
|
||||||
|
|
||||||
GLOBAL_VAR(restart_counter)
|
GLOBAL_VAR(restart_counter)
|
||||||
|
//TODO: Replace INFINITY with the version that fixes http://www.byond.com/forum/?post=2407430
|
||||||
|
GLOBAL_VAR_INIT(bypass_tgs_reboot, world.system_type == UNIX && world.byond_build < INFINITY)
|
||||||
|
|
||||||
//This happens after the Master subsystem new(s) (it's a global datum)
|
//This happens after the Master subsystem new(s) (it's a global datum)
|
||||||
//So subsystems globals exist, but are not initialised
|
//So subsystems globals exist, but are not initialised
|
||||||
@@ -14,7 +16,7 @@ GLOBAL_VAR(restart_counter)
|
|||||||
|
|
||||||
make_datum_references_lists() //initialises global lists for referencing frequently used datums (so that we only ever do it once)
|
make_datum_references_lists() //initialises global lists for referencing frequently used datums (so that we only ever do it once)
|
||||||
|
|
||||||
TgsNew(minimum_required_security_level = TGS_SECURITY_TRUSTED)
|
TgsNew(new /datum/tgs_event_handler/tg, minimum_required_security_level = TGS_SECURITY_TRUSTED)
|
||||||
|
|
||||||
GLOB.revdata = new
|
GLOB.revdata = new
|
||||||
|
|
||||||
@@ -205,6 +207,7 @@ GLOBAL_VAR(restart_counter)
|
|||||||
to_chat(world, "<span class='boldannounce'>Rebooting world...</span>")
|
to_chat(world, "<span class='boldannounce'>Rebooting world...</span>")
|
||||||
Master.Shutdown() //run SS shutdowns
|
Master.Shutdown() //run SS shutdowns
|
||||||
|
|
||||||
|
if(!GLOB.bypass_tgs_reboot)
|
||||||
TgsReboot()
|
TgsReboot()
|
||||||
|
|
||||||
if(TEST_RUN_PARAMETER in params)
|
if(TEST_RUN_PARAMETER in params)
|
||||||
|
|||||||
4
code/modules/tgs/event_handler.dm
Normal file
4
code/modules/tgs/event_handler.dm
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
/datum/tgs_event_handler/tg/HandleEvent(event_code, ...)
|
||||||
|
switch(event_code)
|
||||||
|
if(TGS_EVENT_COMPILE_COMPLETE)
|
||||||
|
GLOB.bypass_tgs_reboot = FALSE
|
||||||
@@ -2640,6 +2640,7 @@
|
|||||||
#include "code\modules\surgery\organs\tails.dm"
|
#include "code\modules\surgery\organs\tails.dm"
|
||||||
#include "code\modules\surgery\organs\tongue.dm"
|
#include "code\modules\surgery\organs\tongue.dm"
|
||||||
#include "code\modules\surgery\organs\vocal_cords.dm"
|
#include "code\modules\surgery\organs\vocal_cords.dm"
|
||||||
|
#include "code\modules\tgs\event_handler.dm"
|
||||||
#include "code\modules\tgs\includes.dm"
|
#include "code\modules\tgs\includes.dm"
|
||||||
#include "code\modules\tgui\external.dm"
|
#include "code\modules\tgui\external.dm"
|
||||||
#include "code\modules\tgui\states.dm"
|
#include "code\modules\tgui\states.dm"
|
||||||
|
|||||||
Reference in New Issue
Block a user