mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-14 08:34:16 +01:00
Reduces Round-start Atmos Processing: Full Charge Disposals
This commit is contained in:
@@ -29,18 +29,21 @@
|
||||
// find the attached trunk (if present) and init gas resvr.
|
||||
/obj/machinery/disposal/New()
|
||||
..()
|
||||
spawn(5)
|
||||
trunk = locate() in src.loc
|
||||
if(!trunk)
|
||||
mode = 0
|
||||
flush = 0
|
||||
else
|
||||
trunk.linked = src // link the pipe trunk to self
|
||||
trunk_check()
|
||||
|
||||
air_contents = new/datum/gas_mixture()
|
||||
//gas.volume = 1.05 * CELLSTANDARD
|
||||
update()
|
||||
air_contents = new/datum/gas_mixture()
|
||||
//gas.volume = 1.05 * CELLSTANDARD
|
||||
update()
|
||||
|
||||
/obj/machinery/disposal/proc/trunk_check()
|
||||
trunk = locate() in src.loc
|
||||
if(!trunk)
|
||||
mode = 0
|
||||
flush = 0
|
||||
else
|
||||
mode = initial(mode)
|
||||
flush = initial(flush)
|
||||
trunk.linked = src // link the pipe trunk to self
|
||||
|
||||
/obj/machinery/disposal/Destroy()
|
||||
eject()
|
||||
@@ -48,6 +51,15 @@
|
||||
trunk.linked = null
|
||||
return ..()
|
||||
|
||||
/obj/machinery/disposal/initialize()
|
||||
// this will get a copy of the air turf and take a SEND PRESSURE amount of air from it
|
||||
var/atom/L = loc
|
||||
var/datum/gas_mixture/env = new
|
||||
env.copy_from(L.return_air())
|
||||
var/datum/gas_mixture/removed = env.remove(SEND_PRESSURE + 1)
|
||||
air_contents.merge(removed)
|
||||
trunk_check()
|
||||
|
||||
// attack by item places it in to disposal
|
||||
/obj/machinery/disposal/attackby(var/obj/item/I, var/mob/user, params)
|
||||
if(stat & BROKEN || !I || !user || ((I.flags & NODROP) && !istype(I, /obj/item/weapon/storage/bag/trash/cyborg)))
|
||||
|
||||
Reference in New Issue
Block a user