[MIRROR] Operating computers no longer link to stasis beds. (#3775)

* Operating computers no longer link to stasis beds. (#57306)

* Operating computers no longer link to stasis beds.

Co-authored-by: Cimika/Lessie/KathyRyals <65850818+KathyRyals@users.noreply.github.com>
This commit is contained in:
SkyratBot
2021-03-03 02:00:30 +00:00
committed by GitHub
co-authored by Cimika/Lessie/KathyRyals
parent 38f5faf0a7
commit 1cfa918513
3 changed files with 3 additions and 37 deletions
+3 -20
View File
@@ -3,14 +3,13 @@
/obj/machinery/computer/operating
name = "operating computer"
desc = "Monitors patient vitals and displays surgery steps. Can be loaded with surgery disks to perform experimental procedures. Automatically syncs to stasis beds within its line of sight for surgical tech advancement."
desc = "Monitors patient vitals and displays surgery steps. Can be loaded with surgery disks to perform experimental procedures. Automatically syncs to operating tables within its line of sight for surgical tech advancement."
icon_screen = "crew"
icon_keyboard = "med_key"
circuit = /obj/item/circuitboard/computer/operating
var/mob/living/carbon/human/patient
var/obj/structure/table/optable/table
var/obj/machinery/stasis/sbed
var/list/advanced_surgeries = list()
var/datum/techweb/linked_techweb
light_color = LIGHT_COLOR_BLUE
@@ -25,10 +24,6 @@
table = locate(/obj/structure/table/optable) in get_step(src, direction)
if(table && table.computer == src)
table.computer = null
else
sbed = locate(/obj/machinery/stasis) in get_step(src, direction)
if(sbed && sbed.op_computer == src)
sbed.op_computer = null
. = ..()
/obj/machinery/computer/operating/attackby(obj/item/O, mob/user, params)
@@ -55,11 +50,6 @@
if(table)
table.computer = src
break
else
sbed = locate(/obj/machinery/stasis) in get_step(src, direction)
if(sbed)
sbed.op_computer = src
break
/obj/machinery/computer/operating/ui_state(mob/user)
return GLOB.not_incapacitated_state
@@ -93,15 +83,8 @@
data["patient"] = list()
patient = table.patient
else
if(sbed)
data["table"] = sbed
if(!ishuman(sbed.occupant))
return data
data["patient"] = list()
patient = sbed.occupant
else
data["patient"] = null
return data
data["patient"] = null
return data
switch(patient.stat)
if(CONSCIOUS)
data["patient"]["stat"] = "Conscious"
-12
View File
@@ -18,25 +18,13 @@
var/stasis_can_toggle = 0
var/mattress_state = "stasis_on"
var/obj/effect/overlay/vis/mattress_on
var/obj/machinery/computer/operating/op_computer
/obj/machinery/stasis/Initialize()
. = ..()
for(var/direction in GLOB.alldirs)
op_computer = locate(/obj/machinery/computer/operating) in get_step(src, direction)
if(op_computer)
op_computer.sbed = src
break
/obj/machinery/stasis/Destroy()
. = ..()
if(op_computer && op_computer.sbed == src)
op_computer.sbed = null
/obj/machinery/stasis/examine(mob/user)
. = ..()
. += "<span class='notice'>Alt-click to [stasis_enabled ? "turn off" : "turn on"] the machine.</span>"
. += "<span class='notice'>\The [src] is [op_computer ? "linked" : "<b>NOT</b> linked"] to a nearby operating computer.</span>"
/obj/machinery/stasis/proc/play_power_sound()
var/_running = stasis_running()
-5
View File
@@ -79,11 +79,6 @@
var/obj/structure/table/optable/table = locate(/obj/structure/table/optable, T)
if(table?.computer)
opcomputer = table.computer
else
var/obj/machinery/stasis/the_stasis_bed = locate(/obj/machinery/stasis, T)
if(the_stasis_bed?.op_computer)
opcomputer = the_stasis_bed.op_computer
if(!opcomputer)
return
if(opcomputer.machine_stat & (NOPOWER|BROKEN))