Skip to content

Commit

Permalink
Moar fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Drulikar committed Feb 24, 2024
1 parent 81d98ce commit 8b19da6
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 1,489 deletions.
1 change: 1 addition & 0 deletions code/_globalvars/lists/mapping_globals.dm
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ GLOBAL_LIST_EMPTY(teleporter_landmarks)

GLOBAL_LIST_INIT(cardinals, list(NORTH, SOUTH, EAST, WEST))
GLOBAL_LIST_EMPTY(nightmare_landmarks)
GLOBAL_LIST_EMPTY(nightmare_landmark_tags_removed)

GLOBAL_LIST_EMPTY(ship_areas)

Expand Down
8 changes: 5 additions & 3 deletions code/game/objects/effects/landmarks/landmarks.dm
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,11 @@
return
GLOB.nightmare_landmarks[insert_tag] = get_turf(src)
/obj/effect/landmark/nightmare/Destroy()
if(insert_tag && autoremove \
&& GLOB.nightmare_landmarks[insert_tag] == get_turf(src))
GLOB.nightmare_landmarks.Remove(insert_tag)
if(insert_tag)
var/turf/turf = get_turf(src)
if(autoremove && GLOB.nightmare_landmarks[insert_tag] == turf)
GLOB.nightmare_landmarks.Remove(insert_tag)
GLOB.nightmare_landmark_tags_removed += insert_tag
return ..()

/obj/effect/landmark/ert_spawns/distress
Expand Down
6 changes: 5 additions & 1 deletion code/modules/nightmare/nmtasks/mapload.dm
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,11 @@
UNTIL(!Master.map_loading)
target_turf = GLOB.nightmare_landmarks[landmark]
if(!target_turf?.z)
CRASH("Nightmare Mapload: Could not find landmark: [landmark]")
if(landmark in GLOB.nightmare_landmark_tags_removed)
log_debug("Nightmare Mapload: Could not find landmark: [landmark] because it was deleted")
return
else
CRASH("Nightmare Mapload: Could not find landmark: [landmark]")
var/result = parsed.load(target_turf.x, target_turf.y, target_turf.z, crop_map = TRUE, no_changeturf = FALSE, place_on_top = FALSE, delete = replace)
if(!result || !parsed.bounds)
CRASH("Nightmare Mapload: Map insertion failed unexpectedly for file: [filepath]")
Expand Down
325 changes: 0 additions & 325 deletions maps/map_files/BigRed/sprinkles/25.containerroom_xenos.dmm

This file was deleted.

Loading

0 comments on commit 8b19da6

Please sign in to comment.