Skip to content

Commit

Permalink
Merge pull request #3408 from PsyCommando/generate_turbolifts_last
Browse files Browse the repository at this point in the history
Build turbolifts last
  • Loading branch information
MistakeNot4892 authored Oct 4, 2023
2 parents 89173eb + b64b5d8 commit 0da3898
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions code/controllers/subsystems/mapping.dm
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,6 @@ SUBSYSTEM_DEF(mapping)
for(var/datum/map_template/MT as anything in get_all_template_instances())
register_map_template(MT)

// Generate turbolifts.
for(var/obj/abstract/turbolift_spawner/turbolift as anything in turbolifts_to_initialize)
turbolift.build_turbolift()

// Populate overmap.
if(length(global.using_map.overmap_ids))
for(var/overmap_id in global.using_map.overmap_ids)
Expand All @@ -99,9 +95,13 @@ SUBSYSTEM_DEF(mapping)
PRINT_STACK_TRACE("Missing z-level data object for z[num2text(z)]!")
level.setup_level_data()

// Generate turbolifts last, since away sites may have elevators to generate too.
for(var/obj/abstract/turbolift_spawner/turbolift as anything in turbolifts_to_initialize)
turbolift.build_turbolift()

// Initialize z-level objects.
#ifdef UNIT_TEST
config.roundstart_level_generation = FALSE
config.roundstart_level_generation = FALSE //#FIXME: Shouldn't this be set before running level_data/setup_level_data()?
#endif

// Resize the world to the max template size to fix a BYOND bug with world resizing breaking events.
Expand Down

0 comments on commit 0da3898

Please sign in to comment.