From 0dcfbad8d3027ce368d948dd8e52666391b42529 Mon Sep 17 00:00:00 2001 From: SteelSlayer Date: Mon, 21 Sep 2020 23:17:51 -0500 Subject: [PATCH] gets rid of `:` usage --- .../unary_devices/outlet_injector.dm | 1 - .../components/unary_devices/unary_base.dm | 2 +- .../components/unary_devices/vent_pump.dm | 1 - .../components/unary_devices/vent_scrubber.dm | 2 +- code/game/machinery/atmo_control.dm | 34 +++++++++++-------- 5 files changed, 21 insertions(+), 19 deletions(-) diff --git a/code/ATMOSPHERICS/components/unary_devices/outlet_injector.dm b/code/ATMOSPHERICS/components/unary_devices/outlet_injector.dm index d9f6f569b32..1dbbac528f3 100644 --- a/code/ATMOSPHERICS/components/unary_devices/outlet_injector.dm +++ b/code/ATMOSPHERICS/components/unary_devices/outlet_injector.dm @@ -20,7 +20,6 @@ var/frequency = 0 var/id - var/id_tag = null var/datum/radio_frequency/radio_connection Mtoollink = 1 settagwhitelist = list("id_tag") diff --git a/code/ATMOSPHERICS/components/unary_devices/unary_base.dm b/code/ATMOSPHERICS/components/unary_devices/unary_base.dm index 14c93dd0490..08af292d62e 100644 --- a/code/ATMOSPHERICS/components/unary_devices/unary_base.dm +++ b/code/ATMOSPHERICS/components/unary_devices/unary_base.dm @@ -2,7 +2,7 @@ dir = SOUTH initialize_directions = SOUTH layer = TURF_LAYER+0.1 - + var/id_tag var/datum/gas_mixture/air_contents var/obj/machinery/atmospherics/node diff --git a/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm b/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm index 57afb59d2b6..d4cb9dac136 100644 --- a/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm +++ b/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm @@ -17,7 +17,6 @@ var/area/initial_loc var/area_uid - var/id_tag = null req_one_access_txt = "24;10" diff --git a/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm b/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm index aac8b8a2399..5eab07ccd9f 100644 --- a/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm +++ b/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm @@ -15,7 +15,7 @@ can_unwrench = 1 var/area/initial_loc - var/id_tag = null + var/frequency = ATMOS_VENTSCRUB var/datum/radio_frequency/radio_connection diff --git a/code/game/machinery/atmo_control.dm b/code/game/machinery/atmo_control.dm index 442d1fac8a0..635ee31c34d 100644 --- a/code/game/machinery/atmo_control.dm +++ b/code/game/machinery/atmo_control.dm @@ -405,25 +405,29 @@ return dat -/obj/machinery/computer/general_air_control/large_tank_control/linkWith(mob/user, obj/O, list/context) - if(context["slot"]=="input" && is_type_in_list(O,input_linkable)) - input_tag = O:id_tag +/obj/machinery/computer/general_air_control/large_tank_control/linkWith(mob/user, obj/machinery/atmospherics/unary/O, list/context) + if(!is_type_in_list(O, input_linkable)) + return FALSE + + if(context["slot"] == "input") + input_tag = O.id_tag input_info = null - if(istype(O,/obj/machinery/atmospherics/unary/vent_pump)) - send_signal(list("tag"=input_tag, - "direction"=1, // Release - "checks" =0 // No pressure checks. + if(istype(O, /obj/machinery/atmospherics/unary/vent_pump)) + send_signal(list("tag" = input_tag, + "direction" = 1, // Release + "checks" = 0 // No pressure checks. )) - return 1 - if(context["slot"]=="output" && is_type_in_list(O,output_linkable)) - output_tag = O:id_tag + return TRUE + + if(context["slot"] == "output") + output_tag = O.id_tag output_info = null - if(istype(O,/obj/machinery/atmospherics/unary/vent_pump)) - send_signal(list("tag"=output_tag, - "direction"=0, // Siphon - "checks" =2 // Internal pressure checks. + if(istype(O, /obj/machinery/atmospherics/unary/vent_pump)) + send_signal(list("tag" = output_tag, + "direction" = 0, // Siphon + "checks" = 2 // Internal pressure checks. )) - return 1 + return TRUE /obj/machinery/computer/general_air_control/large_tank_control/unlinkFrom(mob/user, obj/O) if("id_tag" in O.vars)