From 40141cdc0cc5540eed5ec94fae005c79a287c07c Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Mon, 5 Jun 2023 02:28:22 +0200 Subject: [PATCH] [MIRROR] Discourage dumping init shit in the mc [MDB IGNORE] (#21611) * Discourage dumping init shit in the mc (#75826) Way back in the day, MC's init and new code used to contain 300 lines between them. I do not want to go back. * Discourage dumping init shit in the mc --------- Co-authored-by: Kyle Spier-Swenson --- code/game/world.dm | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/code/game/world.dm b/code/game/world.dm index 547a9192224..07fe533b474 100644 --- a/code/game/world.dm +++ b/code/game/world.dm @@ -47,10 +47,15 @@ GLOBAL_VAR(restart_counter) * * GOT IT MEMORIZED? * - Dominion/Cyberboss + * + * Where to put init shit quick guide: + * If you need it to happen before the mc is created: world/Genesis. + * If you need it to happen last: world/New(), + * Otherwise, in a subsystem preinit or init. Subsystems can set an init priority. */ /** - * THIS !!!SINGLE!!! PROC IS WHERE ANY FORM OF INIITIALIZATION THAT CAN'T BE PERFORMED IN MASTER/NEW() IS DONE + * THIS !!!SINGLE!!! PROC IS WHERE ANY FORM OF INIITIALIZATION THAT CAN'T BE PERFORMED IN SUBSYSTEMS OR WORLD/NEW IS DONE * NOWHERE THE FUCK ELSE * I DON'T CARE HOW MANY LAYERS OF DEBUG/PROFILE/TRACE WE HAVE, YOU JUST HAVE TO DEAL WITH THIS PROC EXISTING * I'M NOT EVEN GOING TO TELL YOU WHERE IT'S CALLED FROM BECAUSE I'M DECLARING THAT FORBIDDEN KNOWLEDGE