Files
Batrachophreno 4ecb0bc21c Repath obj/machinery to obj/structure/machinery [MDB Ignore] (#22500)
Repaths obj/machinery to obj/structure/machinery. **Note for
reviewers:** the only meaningful changed code exists within
**code/game/objects/structures.dm** and
**code/game/objects/structures/_machinery.dm**, largely concerning
damage procs. With the exception of moving airlock defines to their own
file, ALL OTHER CHANGES ARE STRICTLY PATH CHANGES.

Objects, _categorically_, are largely divided between those you can hold
in your hand/inventory and those you can't. Machinery objects are
already subtypes of Structures behaviorally, this PR just makes their
pathing reflect that, and allows for future work (tool actions, more
health/destruction functionality) to be developed without unnecessary
code duplication.

I have tested this PR by loading up the Horizon and dismantling various
machines and structures with tools, shooting guns of various types
throughout the ship, and detonating a bunch of explosions throughout the
ship.
2026-05-26 19:35:48 +00:00

36 lines
746 B
Plaintext

/datum/wires/iff
proper_name = "IFF Beacon"
holder_type = /obj/structure/machinery/iff_beacon
/datum/wires/iff/New()
wires = list(
WIRE_RESET
)
add_duds(2)
..()
/datum/wires/iff/get_status()
var/obj/structure/machinery/iff_beacon/I = holder
. += ..()
. += "[(I.use_power ? "The beacon is transmitting." : "The beacon is not transmitting.")]"
/datum/wires/iff/interactable(mob/user)
if(!..())
return FALSE
var/obj/structure/machinery/iff_beacon/I = holder
return I.panel_open
/datum/wires/iff/on_cut(wire, mend, source)
var/obj/structure/machinery/iff_beacon/I = holder
switch(wire)
if(WIRE_RESET)
if(!mend)
I.shock(usr, 50)
I.toggle()
I.disable()
else
I.shock(usr, 50)
I.enable()
I.toggle()