mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-30 00:29:02 +01:00
[MIRROR] heretic sac room is now lazyloaded [MDB IGNORE] (#23743)
* heretic sac room is now lazyloaded * Update lazy_templates.dm --------- Co-authored-by: jimmyl <70376633+mc-oofert@users.noreply.github.com> Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
This commit is contained in:
co-authored by
jimmyl
Bloop
parent
ab538cb879
commit
cbad5ad545
@@ -2,11 +2,13 @@
|
||||
#define LAZY_TEMPLATE_KEY_WIZARDDEN "LT_WIZARDDEN"
|
||||
#define LAZY_TEMPLATE_KEY_NINJA_HOLDING_FACILITY "LT_NINJAHOLDING"
|
||||
#define LAZY_TEMPLATE_KEY_ABDUCTOR_SHIPS "LT_ABDUCTORSHIPS"
|
||||
#define LAZY_TEMPLATE_KEY_HERETIC_SACRIFICE "LT_HERETICSACRIFICE"
|
||||
|
||||
#define LAZY_TEMPLATE_KEY_LIST_ALL(...) list( \
|
||||
"Nukie Base" = LAZY_TEMPLATE_KEY_NUKIEBASE, \
|
||||
"Wizard Den" = LAZY_TEMPLATE_KEY_WIZARDDEN, \
|
||||
"Ninja Holding" = LAZY_TEMPLATE_KEY_NINJA_HOLDING_FACILITY, \
|
||||
"Abductor Ships" = LAZY_TEMPLATE_KEY_ABDUCTOR_SHIPS, \
|
||||
"Heretic Sacrifice Level" = LAZY_TEMPLATE_KEY_HERETIC_SACRIFICE, \
|
||||
"Outpost of Cogs" = LAZY_TEMPLATE_KEY_OUTPOST_OF_COGS, \
|
||||
) // SKYRAT EDIT ABOVE - OUTPOST OF COGS
|
||||
|
||||
@@ -77,3 +77,7 @@
|
||||
/datum/lazy_template/abductor_ship
|
||||
key = LAZY_TEMPLATE_KEY_ABDUCTOR_SHIPS
|
||||
map_name = "abductor_ships"
|
||||
|
||||
/datum/lazy_template/heretic_sacrifice_room
|
||||
key = LAZY_TEMPLATE_KEY_HERETIC_SACRIFICE
|
||||
map_name = "heretic_sacrifice"
|
||||
|
||||
@@ -226,6 +226,7 @@ GLOBAL_VAR_INIT(revolutionary_win, FALSE)
|
||||
scaling_cost = 9
|
||||
requirements = list(101,101,60,30,30,25,20,15,10,10)
|
||||
antag_cap = list("denominator" = 24)
|
||||
ruleset_lazy_templates = list(LAZY_TEMPLATE_KEY_HERETIC_SACRIFICE)
|
||||
|
||||
|
||||
/datum/dynamic_ruleset/roundstart/heretics/pre_execute(population)
|
||||
|
||||
+5
-6
@@ -40,18 +40,17 @@
|
||||
#ifndef UNIT_TESTS // This is a decently hefty thing to generate while unit testing, so we should skip it.
|
||||
if(!heretic_level_generated)
|
||||
heretic_level_generated = TRUE
|
||||
log_game("Generating z-level for heretic sacrifices...")
|
||||
log_game("Loading heretic lazytemplate for heretic sacrifices...")
|
||||
INVOKE_ASYNC(src, PROC_REF(generate_heretic_z_level))
|
||||
#endif
|
||||
|
||||
/// Generate the sacrifice z-level.
|
||||
/datum/heretic_knowledge/hunt_and_sacrifice/proc/generate_heretic_z_level()
|
||||
var/datum/map_template/heretic_sacrifice_level/new_level = new()
|
||||
if(!new_level.load_new_z())
|
||||
log_game("The heretic sacrifice z-level failed to load.")
|
||||
message_admins("The heretic sacrifice z-level failed to load. Heretic sacrifices won't be teleported to the shadow realm. \
|
||||
if(!SSmapping.lazy_load_template(LAZY_TEMPLATE_KEY_HERETIC_SACRIFICE))
|
||||
log_game("The heretic sacrifice template failed to load.")
|
||||
message_admins("The heretic sacrifice lazy template failed to load. Heretic sacrifices won't be teleported to the shadow realm. \
|
||||
If you want, you can spawn an /obj/effect/landmark/heretic somewhere to stop that from happening.")
|
||||
CRASH("Failed to initialize heretic sacrifice z-level!")
|
||||
CRASH("Failed to lazy load heretic sacrifice template!")
|
||||
|
||||
/datum/heretic_knowledge/hunt_and_sacrifice/recipe_snowflake_check(mob/living/user, list/atoms, list/selected_atoms, turf/loc)
|
||||
var/datum/antagonist/heretic/heretic_datum = IS_HERETIC(user)
|
||||
|
||||
@@ -3,14 +3,6 @@
|
||||
/// A global assoc list of all landmarks that denote a heretic sacrifice location. [string heretic path] = [landmark].
|
||||
GLOBAL_LIST_EMPTY(heretic_sacrifice_landmarks)
|
||||
|
||||
/**
|
||||
* A map template loaded in when heretics are created.
|
||||
* Hereteic sacrifices are sent here when completed.
|
||||
*/
|
||||
/datum/map_template/heretic_sacrifice_level
|
||||
name = "Heretic Sacrifice Level"
|
||||
mappath = "_maps/templates/heretic_sacrifice_template.dmm"
|
||||
|
||||
/// Lardmarks meant to designate where heretic sacrifices are sent.
|
||||
/obj/effect/landmark/heretic
|
||||
name = "default heretic sacrifice landmark"
|
||||
|
||||
Reference in New Issue
Block a user