From 0e44baa921ea7b636b8e5ebbe65f4eacb1c5776e Mon Sep 17 00:00:00 2001 From: MrMelbert <51863163+MrMelbert@users.noreply.github.com> Date: Thu, 16 Jan 2025 02:28:43 -0600 Subject: [PATCH] Fix big smoke on cigarette exhale (and tram smashing apparently) (#88951) --- code/game/objects/effects/particle_holder.dm | 4 ++++ code/modules/transport/transport_module.dm | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/code/game/objects/effects/particle_holder.dm b/code/game/objects/effects/particle_holder.dm index 00a99ea967c..4b3d3585ce1 100644 --- a/code/game/objects/effects/particle_holder.dm +++ b/code/game/objects/effects/particle_holder.dm @@ -19,6 +19,10 @@ if(!loc) stack_trace("particle holder was created with no loc!") return INITIALIZE_HINT_QDEL + + if(PLANE_TO_TRUE(loc.plane) == FLOOR_PLANE) + vis_flags &= ~VIS_INHERIT_PLANE // don't yoink the floor plane. we'll just sit on game plane, it's fine + // We nullspace ourselves because some objects use their contents (e.g. storage) and some items may drop everything in their contents on deconstruct. parent = loc loc = null diff --git a/code/modules/transport/transport_module.dm b/code/modules/transport/transport_module.dm index d1384067a0d..2c02b507bf2 100644 --- a/code/modules/transport/transport_module.dm +++ b/code/modules/transport/transport_module.dm @@ -386,7 +386,7 @@ if(QDELING(victim_structure)) continue if(!is_type_in_typecache(victim_structure, transport_controller_datum.ignored_smashthroughs)) - if((victim_structure.plane == FLOOR_PLANE && victim_structure.layer > TRAM_RAIL_LAYER) || (victim_structure.plane == GAME_PLANE && victim_structure.layer > LOW_OBJ_LAYER) ) + if((PLANE_TO_TRUE(victim_structure.plane) == FLOOR_PLANE && victim_structure.layer > TRAM_RAIL_LAYER) || (PLANE_TO_TRUE(victim_structure.plane) == GAME_PLANE && victim_structure.layer > LOW_OBJ_LAYER) ) if(victim_structure.anchored && initial(victim_structure.anchored) == TRUE) visible_message(span_danger("[src] smashes through [victim_structure]!")) victim_structure.deconstruct(FALSE)