mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 10:12:45 +00:00
Standardize MC subsystem initialization boilerplate
* Based on https://github.com/tgstation/tgstation/pull/25386 * Create macro for defining new subsystem types. * Create PreInit proc to handle setup that needs to be done before the map loads * Rename garbage_controller subsystem to garbage so it matches its global SSgarbage variable name.
This commit is contained in:
@@ -27,8 +27,15 @@
|
||||
var/datum/controller/subsystem/queue_next
|
||||
var/datum/controller/subsystem/queue_prev
|
||||
|
||||
// Used to initialize the subsystem BEFORE the map has loaded
|
||||
//Do not override
|
||||
/datum/controller/subsystem/New()
|
||||
return
|
||||
|
||||
// Used to initialize the subsystem BEFORE the map has loaded
|
||||
// Called AFTER Recover if that is called
|
||||
// Prefer to use Initialize if possible
|
||||
/datum/controller/subsystem/proc/PreInit()
|
||||
return
|
||||
|
||||
//This is used so the mc knows when the subsystem sleeps. do not override.
|
||||
/datum/controller/subsystem/proc/ignite(resumed = 0)
|
||||
|
||||
Reference in New Issue
Block a user