diff --git a/nsv13/code/__HELPERS/overmap.dm b/nsv13/code/__HELPERS/overmap.dm index 7d260c5f532..4f727dd5d2c 100644 --- a/nsv13/code/__HELPERS/overmap.dm +++ b/nsv13/code/__HELPERS/overmap.dm @@ -119,16 +119,24 @@ Another get_angle that works better with the looping edges of the overmap .+=360 /** - * I am genuinely unsure what this is actually meant to do that normal z add does not do. -* If ANYONE actually knows if there is some important reason the procs I changed used this please tell me ~Delta -**/ + * Loads a new z level and initializes the empty space, which is neccessary outside of initial initializations. + */ /datum/controller/subsystem/mapping/proc/add_new_initialized_zlevel(name, traits = list(), z_type = /datum/space_level, orbital_body_type) add_new_zlevel(name, traits) SSatoms.InitializeAtoms(block(locate(1,1,world.maxz),locate(world.maxx,world.maxy,world.maxz))) setup_map_transitions(z_list[world.maxz]) + /** - * Generates a new z level with behavior specific to overmaps and returns its space level datum. + * Generates a new z level with behavior specific to overmaps and returns its space level datum. Does not init space tiles by itself. */ /datum/controller/subsystem/mapping/proc/add_new_overmap_zlevel() . = add_new_zlevel("Overmap treadmill [length(z_list)+1]", ZTRAITS_OVERMAP) setup_map_transitions(.) + +/** + * Same as add_new_overmap_zlevel, but also initializes space. Should be the one used post initial inits. + */ +/datum/controller/subsystem/mapping/proc/add_new_initialized_overmap_zlevel() + . = add_new_zlevel("Overmap treadmill [length(z_list)+1]", ZTRAITS_OVERMAP) + SSatoms.InitializeAtoms(block(locate(1,1,world.maxz),locate(world.maxx,world.maxy,world.maxz))) + setup_map_transitions(.) diff --git a/nsv13/code/modules/overmap/overmap.dm b/nsv13/code/modules/overmap/overmap.dm index 2c5eba460a9..ab51f1edbb0 100644 --- a/nsv13/code/modules/overmap/overmap.dm +++ b/nsv13/code/modules/overmap/overmap.dm @@ -985,7 +985,7 @@ Proc to spool up a new Z-level for a player ship and assign it a treadmill. return reserved_z if(ftl_drive) if(!free_treadmills?.len) - var/datum/space_level/new_level = SSmapping.add_new_overmap_zlevel() + var/datum/space_level/new_level = SSmapping.add_new_initialized_overmap_zlevel() reserved_z = new_level.z_value else var/_z = pick_n_take(free_treadmills)