Merge pull request #14423 from Putnam3145/mode-chaos

makes the chaos thing actually work (whoops)
This commit is contained in:
Lin
2021-03-12 18:21:40 -06:00
committed by GitHub

View File

@@ -21,6 +21,7 @@
/datum/controller/subsystem/persistence/LoadServerPersistence()
. = ..()
LoadRecentModes()
LoadRecentChaos()
LoadRecentStorytellers()
LoadRecentRulesets()
LoadRecentMaps()
@@ -85,6 +86,15 @@
return
saved_modes = json["data"]
/datum/controller/subsystem/persistence/proc/LoadRecentChaos()
var/json_file = file("data/RecentChaos.json")
if(!fexists(json_file))
return
var/list/json = json_decode(file2text(json_file))
if(!json)
return
saved_chaos = json["data"]
/datum/controller/subsystem/persistence/proc/LoadRecentRulesets()
var/json_file = file("data/RecentRulesets.json")
if(!fexists(json_file))