mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 03:27:05 +01:00
Gas Mixture Refactor (#13602)
* Gas Mixture Refactor * derp * defined turf types * fixes * cuts turf visuals cost in half * even better equalizing with planetary atmos * remove volatile fuel * comment and documentatino on turf gas vars
This commit is contained in:
@@ -110,6 +110,7 @@
|
||||
var/N2_pp = breath.get_breath_partial_pressure(breath.nitrogen)
|
||||
var/Toxins_pp = breath.get_breath_partial_pressure(breath.toxins)
|
||||
var/CO2_pp = breath.get_breath_partial_pressure(breath.carbon_dioxide)
|
||||
var/SA_pp = breath.get_breath_partial_pressure(breath.sleeping_agent)
|
||||
|
||||
|
||||
//-- OXY --//
|
||||
@@ -230,16 +231,14 @@
|
||||
|
||||
//-- TRACES --//
|
||||
|
||||
if(breath.trace_gases.len) // If there's some other shit in the air lets deal with it here.
|
||||
for(var/datum/gas/sleeping_agent/SA in breath.trace_gases)
|
||||
var/SA_pp = breath.get_breath_partial_pressure(SA.moles)
|
||||
if(SA_pp > SA_para_min)
|
||||
H.Paralyse(3) // 3 gives them one second to wake up and run away a bit!
|
||||
if(SA_pp > SA_sleep_min) // Enough to make us sleep as well
|
||||
H.AdjustSleeping(8, bound_lower = 0, bound_upper = 10)
|
||||
else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning
|
||||
if(prob(20))
|
||||
H.emote(pick("giggle", "laugh"))
|
||||
if(breath.sleeping_agent) // If there's some other shit in the air lets deal with it here.
|
||||
if(SA_pp > SA_para_min)
|
||||
H.Paralyse(3) // 3 gives them one second to wake up and run away a bit!
|
||||
if(SA_pp > SA_sleep_min) // Enough to make us sleep as well
|
||||
H.AdjustSleeping(8, bound_lower = 0, bound_upper = 10)
|
||||
else if(SA_pp > 0.01) // There is sleeping gas in their lungs, but only a little, so give them a bit of a warning
|
||||
if(prob(20))
|
||||
H.emote(pick("giggle", "laugh"))
|
||||
|
||||
handle_breath_temperature(breath, H)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user