mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-22 20:57:23 +01:00
[MIRROR] EMP & Wires refactor (#12658)
Co-authored-by: Guti <32563288+TheCaramelion@users.noreply.github.com> Co-authored-by: Cameron Lennox <killer65311@gmail.com>
This commit is contained in:
co-authored by
Guti
Cameron Lennox
parent
494fc9bea9
commit
b116cc450d
@@ -8,7 +8,7 @@
|
||||
|
||||
/obj/machinery/rnd/production/circuit_imprinter/Initialize(mapload)
|
||||
. = ..()
|
||||
wires = new /datum/wires/circuit_imprinter(src)
|
||||
set_wires(new /datum/wires/circuit_imprinter(src))
|
||||
|
||||
/obj/machinery/rnd/production/circuit_imprinter/compute_efficiency()
|
||||
var/rating = 0
|
||||
|
||||
@@ -8,4 +8,4 @@
|
||||
|
||||
/obj/machinery/rnd/production/protolathe/Initialize(mapload)
|
||||
. = ..()
|
||||
wires = new /datum/wires/protolathe(src)
|
||||
set_wires(new /datum/wires/protolathe(src))
|
||||
|
||||
@@ -15,8 +15,6 @@
|
||||
var/datum/techweb/stored_research
|
||||
///The item loaded inside the machine, used by experimentors and destructive analyzers only.
|
||||
var/datum/weakref/loaded_item
|
||||
/// Wires for hacking, not every rnd machine has this set
|
||||
var/datum/wires/protolathe/wires = null
|
||||
|
||||
/obj/machinery/rnd/Initialize(mapload)
|
||||
. = ..()
|
||||
@@ -24,6 +22,7 @@
|
||||
CONNECT_TO_RND_SERVER_ROUNDSTART(stored_research, src)
|
||||
if(stored_research)
|
||||
on_connected_techweb()
|
||||
set_wires(new /datum/wires/rnd(src))
|
||||
|
||||
/obj/machinery/rnd/Destroy()
|
||||
if(stored_research)
|
||||
|
||||
@@ -53,6 +53,8 @@
|
||||
|
||||
/obj/machinery/rnd/server/emp_act(severity, recursive)
|
||||
. = ..()
|
||||
if (. & EMP_PROTECT_SELF)
|
||||
return
|
||||
stat |= EMPED
|
||||
addtimer(CALLBACK(src, PROC_REF(fix_emp)), 60 SECONDS)
|
||||
refresh_working()
|
||||
|
||||
Reference in New Issue
Block a user