From 9b008e6635e233995bb6c259f604d14f12fcdbd2 Mon Sep 17 00:00:00 2001 From: Kyep Date: Mon, 2 Jan 2017 03:40:14 -0800 Subject: [PATCH] Improvement --- code/ATMOSPHERICS/atmospherics.dm | 4 ++++ code/ATMOSPHERICS/components/unary_devices/vent_pump.dm | 3 +-- code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm | 3 +-- code/modules/mob/living/carbon/carbon.dm | 3 +-- 4 files changed, 7 insertions(+), 6 deletions(-) diff --git a/code/ATMOSPHERICS/atmospherics.dm b/code/ATMOSPHERICS/atmospherics.dm index fad455ed438..47c5689054c 100644 --- a/code/ATMOSPHERICS/atmospherics.dm +++ b/code/ATMOSPHERICS/atmospherics.dm @@ -66,6 +66,10 @@ Pipelines + Other Objects -> Pipe network /obj/machinery/atmospherics/update_icon() return null +/obj/machinery/atmospherics/proc/update_pipe_image() + pipe_image = image(src, loc, layer = 20, dir = dir) //the 20 puts it above Byond's darkness (not its opacity view) + pipe_image.plane = HUD_PLANE + /obj/machinery/atmospherics/proc/check_icon_cache(var/safety = 0) if(!istype(icon_manager)) if(!safety) //to prevent infinite loops diff --git a/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm b/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm index 7d73e7d7a19..299d0c20e22 100644 --- a/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm +++ b/code/ATMOSPHERICS/components/unary_devices/vent_pump.dm @@ -100,8 +100,7 @@ overlays += icon_manager.get_atmos_icon("device", , , vent_icon) - pipe_image = image(src, loc, layer = 20, dir = dir) //the 20 puts it above Byond's darkness (not its opacity view) - pipe_image.plane = HUD_PLANE + update_pipe_image() /obj/machinery/atmospherics/unary/vent_pump/update_underlays() if(..()) diff --git a/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm b/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm index 92fc9e4d160..5554723c945 100644 --- a/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm +++ b/code/ATMOSPHERICS/components/unary_devices/vent_scrubber.dm @@ -107,8 +107,7 @@ scrubber_icon = "scrubberweld" overlays += icon_manager.get_atmos_icon("device", , , scrubber_icon) - pipe_image = image(src, loc, layer = 20, dir = dir) //the 20 puts it above Byond's darkness (not its opacity view) - pipe_image.plane = HUD_PLANE + update_pipe_image() /obj/machinery/atmospherics/unary/vent_scrubber/update_underlays() if(..()) diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm index a26b5e967af..fed16671887 100644 --- a/code/modules/mob/living/carbon/carbon.dm +++ b/code/modules/mob/living/carbon/carbon.dm @@ -454,8 +454,7 @@ var/list/ventcrawl_machinery = list(/obj/machinery/atmospherics/unary/vent_pump, totalMembers |= pipeline.other_atmosmch for(var/obj/machinery/atmospherics/A in totalMembers) if(!A.pipe_image) - A.pipe_image = image(A, A.loc, layer = 20, dir = A.dir) //the 20 puts it above Byond's darkness (not its opacity view) - A.pipe_image.plane = HUD_PLANE + A.update_pipe_image() pipes_shown += A.pipe_image client.images += A.pipe_image