Fixes C4, dirty bombs and nuclear waste (#22945)

changes:
  - bugfix: "Fixes C4 effects not correctly getting their parent item."
  - bugfix: "Fixes C4 not being placed correctly."
  - bugfix: "Fixes Dirty Bombs deleting their own radiation source."
- bugfix: "Fixes Dirty Bomb goop puddles disapearing long before the
radiation does."
  - bugfix: "Fixes drinking radioactive waste not irradiating you."

3 dirty bombs set off. One on a floor, one on a wall one on a machine.
<img width="1191" height="1182" alt="image"
src="https://github.com/user-attachments/assets/584e7572-441c-4937-8e0e-7203010fcd54"
/>

---------

Signed-off-by: FenodyreeAv <fenodyree.av@gmail.com>
This commit is contained in:
FenodyreeAv
2026-07-29 17:29:31 +00:00
committed by GitHub
parent 514bc2346e
commit 2fdf11ca75
5 changed files with 55 additions and 14 deletions
@@ -7,6 +7,7 @@
anchored = TRUE
density = FALSE
mouse_opacity = MOUSE_OPACITY_ICON
layer = ABOVE_DOOR_LAYER
var/obj/item/plastique/parent
/obj/effect/plastic_explosive/feedback_hints(mob/user, distance, is_adjacent)
@@ -16,8 +17,8 @@
/obj/effect/plastic_explosive/Initialize(var/atom/owner_pos, var/atom/target, var/obj/item/plastique/c4)
. = ..()
parent = c4
if(parent)
parent = c4
parent.forceMove(src)
name = parent.name
desc = parent.desc
@@ -46,8 +47,8 @@
/obj/effect/plastic_explosive/attack_hand(mob/living/user)
to_chat(user, SPAN_WARNING("\The [src] is solidly attached, it doesn't budge!"))
/obj/effect/plastic_explosive/attackby(obj/item/attacking_item, mob/user)
return parent.attackby(attacking_item, user)
/obj/effect/plastic_explosive/attackby(obj/item/attacking_item, mob/user, click_parameters)
return parent.attackby(attacking_item, user, click_parameters)
/obj/effect/plastic_explosive/big
name = "bundled plastic explosives"