mirror of
https://github.com/CHOMPstation/CHOMPstation.git
synced 2026-07-20 19:42:34 +01:00
Removed Inflatable Trait
It's now being migrated to the vore panel.
This commit is contained in:
@@ -1,37 +1,38 @@
|
||||
/mob
|
||||
var/datum/gas_mixture/air_contents = new
|
||||
|
||||
var/obj/machinery/atmospherics/portables_connector/connected_port
|
||||
var/obj/item/weapon/tank/holding
|
||||
|
||||
var/volume = 1000
|
||||
var/destroyed = 0
|
||||
|
||||
var/start_pressure = ONE_ATMOSPHERE
|
||||
var/maximum_pressure = 90 * ONE_ATMOSPHERE
|
||||
var/inflatable = 1
|
||||
|
||||
/mob/living
|
||||
inflatable= 0
|
||||
|
||||
/mob/New()
|
||||
..()
|
||||
|
||||
air_contents.volume = volume
|
||||
air_contents.temperature = T20C
|
||||
|
||||
return 1
|
||||
|
||||
/mob/Destroy()
|
||||
qdel_null(air_contents)
|
||||
qdel_null(holding)
|
||||
. = ..()
|
||||
|
||||
/mob/Life()
|
||||
if(!connected_port) //only react when pipe_network will ont it do it for you
|
||||
//Allow for reactions
|
||||
air_contents.react()
|
||||
. = ..()
|
||||
|
||||
/mob/proc/StandardAirMix()
|
||||
return list(
|
||||
"oxygen" = O2STANDARD * MolesForPressure(),
|
||||
"nitrogen" = N2STANDARD * MolesForPressure())
|
||||
|
||||
/mob/proc/MolesForPressure(var/target_pressure = start_pressure)
|
||||
return (target_pressure * air_contents.volume) / (R_IDEAL_GAS_EQUATION * air_contents.temperature)
|
||||
|
||||
@@ -48,7 +49,7 @@
|
||||
connected_port = new_port
|
||||
connected_port.connected_device = src
|
||||
connected_port.on = 1 //Activate port updates
|
||||
|
||||
buckled = 1
|
||||
anchored = 1 //Prevent movement
|
||||
|
||||
//Actually enforce the air sharing
|
||||
@@ -56,28 +57,22 @@
|
||||
if(network && !network.gases.Find(air_contents))
|
||||
network.gases += air_contents
|
||||
network.update = 1
|
||||
|
||||
return 1
|
||||
|
||||
/mob/proc/disconnect()
|
||||
if(!connected_port)
|
||||
return 0
|
||||
|
||||
var/datum/pipe_network/network = connected_port.return_network(src)
|
||||
if(network)
|
||||
network.gases -= air_contents
|
||||
|
||||
anchored = 0
|
||||
|
||||
connected_port.connected_device = null
|
||||
connected_port = null
|
||||
|
||||
return 1
|
||||
|
||||
/mob/proc/update_connected_network()
|
||||
if(!connected_port)
|
||||
return
|
||||
|
||||
var/datum/pipe_network/network = connected_port.return_network(src)
|
||||
if (network)
|
||||
network.update = 1
|
||||
@@ -112,12 +107,4 @@
|
||||
return 0
|
||||
|
||||
/mob/proc/atmosanalyze(var/mob/user)
|
||||
return atmosanalyzer_scan(src, src.air_contents, user)
|
||||
|
||||
/datum/trait/inflatable
|
||||
name = "Inflatable"
|
||||
desc = "You were born with an unusual ability to store air like a portable canister"
|
||||
cost = 0
|
||||
/datum/trait/inflatable/apply(var/datum/species/S,var/mob/living/carbon/human/H)
|
||||
H.inflatable = 1
|
||||
..(S,H)
|
||||
return atmosanalyzer_scan(src, src.air_contents, user)
|
||||
Reference in New Issue
Block a user