Re-introduce passive vents, mixer sprite fix

This commit is contained in:
Markolie
2015-09-28 05:53:51 +02:00
parent dbbdf90670
commit c004e68ceb
5 changed files with 51 additions and 8 deletions
@@ -0,0 +1,36 @@
/obj/machinery/atmospherics/unary/passive_vent
icon = 'icons/atmos/vent_pump.dmi'
icon_state = "map_vent"
name = "passive vent"
desc = "A large air vent"
can_unwrench = 1
var/volume = 250
/obj/machinery/atmospherics/unary/passive_vent/high_volume
name = "large passive vent"
volume = 1000
/obj/machinery/atmospherics/unary/passive_vent/New()
..()
air_contents.volume = volume
/obj/machinery/atmospherics/unary/passive_vent/process()
..()
if(!node)
return
var/datum/gas_mixture/removed = air_contents.remove(volume)
loc.assume_air(removed)
air_update_turf()
/obj/machinery/atmospherics/unary/passive_vent/update_underlays()
if(..())
underlays.Cut()
var/turf/T = get_turf(src)
if(!istype(T))
return
add_underlay(T, node, dir)
+12 -7
View File
@@ -35,7 +35,8 @@
#define PIPE_INJECTOR 34
#define PIPE_DVALVE 35
#define PIPE_DP_VENT 36
#define PIPE_DTVALVE 37
#define PIPE_PASV_VENT 37
#define PIPE_DTVALVE 38
/obj/item/pipe
name = "pipe"
@@ -142,6 +143,8 @@
src.pipe_type = PIPE_INJECTOR
else if(istype(make_from, /obj/machinery/atmospherics/binary/dp_vent_pump))
src.pipe_type = PIPE_DP_VENT
else if(istype(make_from, /obj/machinery/atmospherics/unary/passive_vent))
src.pipe_type = PIPE_PASV_VENT
else if(istype(make_from, /obj/machinery/atmospherics/omni/mixer))
src.pipe_type = PIPE_OMNI_MIXER
@@ -344,7 +347,7 @@
return dir|flip
if(PIPE_SIMPLE_BENT, PIPE_INSULATED_BENT, PIPE_HE_BENT, PIPE_SUPPLY_BENT, PIPE_SCRUBBERS_BENT)
return dir //dir|acw
if(PIPE_CONNECTOR, PIPE_UVENT, PIPE_SCRUBBER, PIPE_HEAT_EXCHANGE, PIPE_INJECTOR)
if(PIPE_CONNECTOR, PIPE_UVENT, PIPE_PASV_VENT, PIPE_SCRUBBER, PIPE_HEAT_EXCHANGE, PIPE_INJECTOR)
return dir
if(PIPE_MANIFOLD4W, PIPE_SUPPLY_MANIFOLD4W, PIPE_SCRUBBERS_MANIFOLD4W, PIPE_OMNI_MIXER, PIPE_OMNI_FILTER)
return dir|flip|cw|acw
@@ -428,8 +431,6 @@
user << "<span class='warning'>There is already a pipe of the same type at this location.</span>"
return 1
var/obj/machinery/atmospherics/machineReference = null //If somebody wants to overhaul that switch statement below, be my guest. Easier to set a reference here and then transfer logs after the switch statement.
switch(pipe_type) //What kind of heartless person thought of doing this?
if(PIPE_SIMPLE_STRAIGHT, PIPE_SIMPLE_BENT)
var/obj/machinery/atmospherics/pipe/simple/P = new( src.loc )
@@ -574,6 +575,12 @@
if (pipename)
P.name = pipename
P.construction(dir, pipe_dir, color)
if(PIPE_PASV_VENT)
var/obj/machinery/atmospherics/unary/passive_vent/P = new(src.loc)
if (pipename)
P.name = pipename
P.construction(dir, pipe_dir, color)
if(PIPE_OMNI_MIXER)
var/obj/machinery/atmospherics/omni/mixer/P = new(loc)
@@ -588,9 +595,6 @@
"[user] fastens the [src].", \
"\blue You have fastened the [src].", \
"You hear ratchet.")
if(machineReference)
transfer_fingerprints_to(machineReference)
machineReference.add_fingerprint(user)
qdel(src) // remove the pipe item
return
@@ -670,4 +674,5 @@
#undef PIPE_INJECTOR
#undef PIPE_DVALVE
#undef PIPE_DP_VENT
#undef PIPE_PASV_VENT
#undef PIPE_DTVALVE
+2 -1
View File
@@ -20,7 +20,7 @@
<A href='?src=\ref[src];make=20;dir=1'>Pipe Cap</A><BR>
<A href='?src=\ref[src];make=19;dir=1'>4-Way Manifold</A><BR>
<A href='?src=\ref[src];make=18;dir=1'>Manual T-Valve</A><BR>
<A href='?src=\ref[src];make=37;dir=1'>Digital T-Valve</A><BR>
<A href='?src=\ref[src];make=38;dir=1'>Digital T-Valve</A><BR>
<b>Supply pipes:</b><BR>
<A href='?src=\ref[src];make=24;dir=1'>Pipe</A><BR>
<A href='?src=\ref[src];make=25;dir=5'>Bent Pipe</A><BR>
@@ -47,6 +47,7 @@
<A href='?src=\ref[src];make=14;dir=1'>Gas Mixer</A><BR>
<A href='?src=\ref[src];make=34;dir=1'>Air Injector</A><BR>
<A href='?src=\ref[src];make=36;dir=1'>Dual-Port Vent Pump</A><BR>
<A href='?src=\ref[src];make=37;dir=1'>Passive Vent</A><BR>
<b>Heat exchange:</b><BR>
<A href='?src=\ref[src];make=2;dir=1'>Pipe</A><BR>
<A href='?src=\ref[src];make=3;dir=5'>Bent Pipe</A><BR>
Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

After

Width:  |  Height:  |  Size: 32 KiB

+1
View File
@@ -121,6 +121,7 @@
#include "code\ATMOSPHERICS\components\unary_devices\heat_source.dm"
#include "code\ATMOSPHERICS\components\unary_devices\outlet_injector.dm"
#include "code\ATMOSPHERICS\components\unary_devices\oxygen_generator.dm"
#include "code\ATMOSPHERICS\components\unary_devices\passive_vent.dm"
#include "code\ATMOSPHERICS\components\unary_devices\portables_connector.dm"
#include "code\ATMOSPHERICS\components\unary_devices\tank.dm"
#include "code\ATMOSPHERICS\components\unary_devices\thermal_plate.dm"