Files
Aurora.3/code/game/objects/effects/plastic_explosive.dm
Batrachophreno 0c7ab8baa7 Lemurian Sea (#22686)
changes:
  - refactor: "Refactors Gravity Generator UI from HTML to TGUI."
- rscadd: "Adds sector-based modifier var 'overmap_hazards_multiplier'
for generating total overmap hazard count."
  - soundadd: "Adds new Lemurian Sea 'welcome' announcements."
- rscadd: "Added Lemurian Sea gravitic anomalies as overmap hazards and
random events."
  - rscadd: "Adds ADPI/The Voices."
- rscadd: "Adds ADPI Panel for modmins to send ADPI messages to a single
character or all characters from their respective pools, or custom
messages."
- balance: "Vaurca Hivenet communication, the Hivenet Manifest, and
Hivenet Echoes are now disabled while the ship is in Lemurian Sea
sectors."
2026-06-13 16:25:49 +00:00

56 lines
1.7 KiB
Plaintext

/obj/effect/plastic_explosive
name = "plastic explosives"
desc = "Used to put holes in specific areas without too much extra hole."
gender = PLURAL
icon = 'icons/obj/assemblies.dmi'
icon_state = "plastic-explosive2"
anchored = TRUE
density = FALSE
mouse_opacity = MOUSE_OPACITY_ICON
var/obj/item/plastique/parent
/obj/effect/plastic_explosive/feedback_hints(mob/user, distance, is_adjacent)
. += ..()
if(is_adjacent)
. += SPAN_WARNING("It is set to blow in [round((parent.detonate_time - world.time) / 10)] seconds.")
/obj/effect/plastic_explosive/Initialize(var/atom/owner_pos, var/atom/target, var/obj/item/plastique/c4)
. = ..()
if(parent)
parent = c4
parent.forceMove(src)
name = parent.name
desc = parent.desc
set_position(get_dir(src, target))
/obj/effect/plastic_explosive/Destroy()
QDEL_NULL(parent)
return ..()
/obj/effect/plastic_explosive/proc/set_position(var/dir)
var/dir_text = uppertext(dir2text(dir))
var/list/dir_to_pixel = list(
"NORTH" = list(0, 32),
"NORTHEAST" = list(32, 32),
"EAST" = list(32, 0),
"SOUTHEAST" = list(32, -32),
"SOUTH" = list(0, -32),
"SOUTHWEST" = list(-32, -32),
"WEST" = list(-32, 0),
"NORTHWEST" = list(-32, 32)
)
var/list/pixel_shifts = dir_to_pixel[dir_text]
pixel_x = pixel_shifts[1]
pixel_y = pixel_shifts[2]
/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/big
name = "bundled plastic explosives"
desc = "Used to put big holes in specific areas with a lot of extra hole."
icon_state = "plastic-explosive-big2"