Addiction rework (#56923)

Co-authored-by: Krysonism <49783092+Krysonism@users.noreply.github.com>
Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
This commit is contained in:
Qustinnus
2021-02-16 18:20:16 -08:00
committed by GitHub
co-authored by Krysonism Mothblocks
parent e678e8c24a
commit ef80ed1935
44 changed files with 606 additions and 483 deletions
+19
View File
@@ -0,0 +1,19 @@
/*!
This subsystem mostly exists to populate and manage the withdrawal singletons.
*/
SUBSYSTEM_DEF(addiction)
name = "Addiction"
flags = SS_NO_FIRE
///Dictionary of addiction.type || addiction ref
var/list/all_addictions = list()
/datum/controller/subsystem/addiction/Initialize(timeofday)
InitializeAddictions()
return ..()
///Ran on initialize, populates the addiction dictionary
/datum/controller/subsystem/addiction/proc/InitializeAddictions()
for(var/type in subtypesof(/datum/addiction))
var/datum/addiction/ref = new type
all_addictions[type] = ref