From d3ed7c55821142bc4fe0415fcfd06355dfc9f805 Mon Sep 17 00:00:00 2001 From: warriorstar-orion Date: Sat, 5 Apr 2025 07:45:26 -0400 Subject: [PATCH] ensure atoms spawned over chasms fall when appropriate (#28889) * ensure atoms spawned over chasms fall when appropriate * no more sleepy --- code/game/turfs/simulated/floor/chasm.dm | 8 ++++++++ code/modules/mining/equipment/wormhole_jaunter.dm | 4 +++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/code/game/turfs/simulated/floor/chasm.dm b/code/game/turfs/simulated/floor/chasm.dm index a4d2da39fad..6c0896a0ef1 100644 --- a/code/game/turfs/simulated/floor/chasm.dm +++ b/code/game/turfs/simulated/floor/chasm.dm @@ -42,6 +42,14 @@ var/drop_y = 1 var/drop_z = 2 // so that it doesn't send you to CC if something fucks up. +/turf/simulated/floor/chasm/Initialize(mapload) + . = ..() + RegisterSignal(src, COMSIG_ATOM_AFTER_SUCCESSFUL_INITIALIZED_ON, PROC_REF(on_new_atom_at_loc)) + +/turf/simulated/floor/chasm/proc/on_new_atom_at_loc(turf/location, atom/created, init_flags) + SIGNAL_HANDLER // COMSIG_ATOM_AFTER_SUCCESSFUL_INITIALIZED_ON + drop_stuff(created) + /turf/simulated/floor/chasm/Entered(atom/movable/AM) ..() START_PROCESSING(SSprocessing, src) diff --git a/code/modules/mining/equipment/wormhole_jaunter.dm b/code/modules/mining/equipment/wormhole_jaunter.dm index a835cc797ff..9f268d4441b 100644 --- a/code/modules/mining/equipment/wormhole_jaunter.dm +++ b/code/modules/mining/equipment/wormhole_jaunter.dm @@ -360,7 +360,9 @@ GLOBAL_LIST_EMPTY(wormhole_effect) inactive = TRUE menu_open = FALSE - sleep(5 SECONDS) + addtimer(CALLBACK(src, PROC_REF(post_activate)), 5 SECONDS) + +/obj/item/wormhole_jaunter/wormhole_weaver/proc/post_activate() if(emp_inflicted) return