Fix halloweens races (#70874)

* Fixes halloween races.
- Fixes a race condition involve checking for holidays befores SSevents is instantiated. Now, holiday checking is done through a helper, which will ensure the holidays list is created and filled before checked.
This commit is contained in:
MrMelbert
2022-10-31 10:01:31 -05:00
committed by GitHub
parent ed55e9ba01
commit a1ab0201ff
35 changed files with 106 additions and 89 deletions
+1 -1
View File
@@ -261,7 +261,7 @@
/obj/item/mod/module/springlock/bite_of_87/on_suit_activation()
..()
if(SSevents.holidays && SSevents.holidays[APRIL_FOOLS] || prob(1))
if(check_holidays(APRIL_FOOLS) || prob(1))
mod.set_mod_color("#b17f00")
mod.wearer.remove_atom_colour(WASHABLE_COLOUR_PRIORITY) // turns purple guy purple
mod.wearer.add_atom_colour("#704b96", FIXED_COLOUR_PRIORITY)