mirror of
https://github.com/SPLURT-Station/S.P.L.U.R.T-Station-13.git
synced 2025-12-11 10:22:13 +00:00
Adds random seed feedback (#33708)
* Master now sets rand_seed * Blackbox now records Master.random_seed
This commit is contained in:
committed by
CitadelStationBot
parent
6205268f7e
commit
08b2224007
@@ -53,6 +53,8 @@ GLOBAL_REAL(Master, /datum/controller/master) = new
|
|||||||
var/static/restart_clear = 0
|
var/static/restart_clear = 0
|
||||||
var/static/restart_timeout = 0
|
var/static/restart_timeout = 0
|
||||||
var/static/restart_count = 0
|
var/static/restart_count = 0
|
||||||
|
|
||||||
|
var/static/random_seed
|
||||||
|
|
||||||
//current tick limit, assigned before running a subsystem.
|
//current tick limit, assigned before running a subsystem.
|
||||||
//used by CHECK_TICK as well so that the procs subsystems call can obey that SS's tick limits
|
//used by CHECK_TICK as well so that the procs subsystems call can obey that SS's tick limits
|
||||||
@@ -60,6 +62,11 @@ GLOBAL_REAL(Master, /datum/controller/master) = new
|
|||||||
|
|
||||||
/datum/controller/master/New()
|
/datum/controller/master/New()
|
||||||
// Highlander-style: there can only be one! Kill off the old and replace it with the new.
|
// Highlander-style: there can only be one! Kill off the old and replace it with the new.
|
||||||
|
|
||||||
|
if(!random_seed)
|
||||||
|
random_seed = rand(1, 1e9)
|
||||||
|
rand_seed(random_seed)
|
||||||
|
|
||||||
var/list/_subsystems = list()
|
var/list/_subsystems = list()
|
||||||
subsystems = _subsystems
|
subsystems = _subsystems
|
||||||
if (Master != src)
|
if (Master != src)
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ SUBSYSTEM_DEF(blackbox)
|
|||||||
|
|
||||||
/datum/controller/subsystem/blackbox/Initialize()
|
/datum/controller/subsystem/blackbox/Initialize()
|
||||||
triggertime = world.time
|
triggertime = world.time
|
||||||
|
record_feedback("amount", "random_seed", Master.random_seed)
|
||||||
. = ..()
|
. = ..()
|
||||||
|
|
||||||
//poll population
|
//poll population
|
||||||
|
|||||||
Reference in New Issue
Block a user