mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 10:21:11 +00:00
Fixes as many instances of not using set_volume, set_temperature, and the proper adjust_gas args as I could find.
This commit is contained in:
@@ -173,7 +173,7 @@ Deuterium-tritium fusion: 4.5 x 10^7 K
|
||||
if(mega_energy > 0 && held_plasma_moles)
|
||||
var/heat_capacity = held_plasma.heat_capacity//200 * number of plasma moles
|
||||
if(heat_capacity > 0.0003) //formerly MINIMUM_HEAT_CAPACITY
|
||||
held_plasma.temperature = (heat_capacity + mega_energy * 35000)/heat_capacity
|
||||
held_plasma.set_temperature((heat_capacity + mega_energy * 35000)/heat_capacity)
|
||||
|
||||
//if there is too much plasma in the field, lose some
|
||||
/*if( held_plasma.toxins > (MOLES_CELLSTANDARD * 7) * (50 / field_strength) )
|
||||
@@ -184,11 +184,11 @@ Deuterium-tritium fusion: 4.5 x 10^7 K
|
||||
//world << "lost [loss_ratio*100]% of held plasma"
|
||||
//
|
||||
var/datum/gas_mixture/plasma_lost = new
|
||||
plasma_lost.temperature = held_plasma.temperature
|
||||
plasma_lost.set_temperature(held_plasma.temperature)
|
||||
//
|
||||
plasma_lost.set_gas(PLASMA, held_plasma_moles * loss_ratio, 0)
|
||||
plasma_lost.set_gas(PLASMA, held_plasma_moles * loss_ratio)
|
||||
//plasma_lost.update_values()
|
||||
held_plasma.adjust_gas(PLASMA, -held_plasma_moles * loss_ratio, 0)
|
||||
held_plasma.adjust_gas(PLASMA, -held_plasma_moles * loss_ratio)
|
||||
//held_plasma.update_values()
|
||||
//
|
||||
environment.merge(plasma_lost)
|
||||
|
||||
@@ -230,8 +230,8 @@
|
||||
|
||||
/obj/spacepod/proc/add_cabin()
|
||||
cabin_air = new
|
||||
cabin_air.temperature = T20C
|
||||
cabin_air.volume = 200
|
||||
cabin_air.set_temperature(T20C)
|
||||
cabin_air.set_volume(200)
|
||||
cabin_air.adjust_gas(OXYGEN, O2STANDARD*cabin_air.volume/(R_IDEAL_GAS_EQUATION*cabin_air.temperature))
|
||||
cabin_air.adjust_gas(NITROGEN, N2STANDARD*cabin_air.volume/(R_IDEAL_GAS_EQUATION*cabin_air.temperature))
|
||||
return cabin_air
|
||||
@@ -368,7 +368,7 @@
|
||||
process(var/obj/spacepod/spacepod)
|
||||
if(spacepod.cabin_air && spacepod.cabin_air.volume > 0)
|
||||
var/delta = spacepod.cabin_air.temperature - T20C
|
||||
spacepod.cabin_air.temperature -= max(-10, min(10, round(delta/4,0.1)))
|
||||
spacepod.cabin_air.set_temperature( spacepod.cabin_air.temperature - max(-10, min(10, round(delta/4,0.1))))
|
||||
return
|
||||
|
||||
/datum/global_iterator/pod_tank_give_air
|
||||
|
||||
Reference in New Issue
Block a user