initial
This commit is contained in:
@@ -71,8 +71,6 @@
|
||||
|
||||
/turf/proc/set_sleeping(should_sleep)
|
||||
|
||||
/turf/proc/__update_auxtools_turf_adjacency_info()
|
||||
|
||||
//returns a list of adjacent turfs that can share air with this one.
|
||||
//alldir includes adjacent diagonal tiles that can share
|
||||
// air with both of the related adjacent cardinal tiles
|
||||
|
||||
@@ -45,9 +45,6 @@
|
||||
QDEL_NULL(active_hotspot)
|
||||
return ..()
|
||||
|
||||
/// Function for Extools Atmos
|
||||
/turf/proc/update_air_ref()
|
||||
|
||||
/////////////////GAS MIXTURE PROCS///////////////////
|
||||
|
||||
/turf/open/assume_air(datum/gas_mixture/giver) //use this for machines to adjust air
|
||||
|
||||
@@ -12,8 +12,6 @@ GLOBAL_LIST_INIT(nonreactive_gases, typecacheof(list(GAS_O2, GAS_N2, GAS_CO2, GA
|
||||
|
||||
// Also allows you to add new gases at runtime
|
||||
|
||||
/proc/_auxtools_register_gas(datum/gas/gas) // makes sure auxtools knows stuff about this gas
|
||||
|
||||
/datum/auxgm
|
||||
var/done_initializing = FALSE
|
||||
var/list/datums = list()
|
||||
@@ -148,8 +146,6 @@ GLOBAL_LIST_INIT(nonreactive_gases, typecacheof(list(GAS_O2, GAS_N2, GAS_CO2, GA
|
||||
SSair.auxtools_update_reactions()
|
||||
SEND_GLOBAL_SIGNAL(COMSIG_GLOB_NEW_GAS, g)
|
||||
|
||||
/proc/finalize_gas_refs()
|
||||
|
||||
/datum/auxgm/New()
|
||||
src.supermatter[HEAT_PENALTY] = list()
|
||||
src.supermatter[TRANSMIT_MODIFIER] = list()
|
||||
|
||||
@@ -16,13 +16,10 @@ What are the archived variables for?
|
||||
|
||||
GLOBAL_LIST_INIT(auxtools_atmos_initialized,FALSE)
|
||||
|
||||
/proc/auxtools_atmos_init()
|
||||
|
||||
/datum/gas_mixture/New(volume)
|
||||
if (!isnull(volume))
|
||||
initial_volume = volume
|
||||
AUXTOOLS_CHECK(AUXMOS)
|
||||
if(!GLOB.auxtools_atmos_initialized && auxtools_atmos_init())
|
||||
if(!GLOB.auxtools_atmos_initialized && auxtools_atmos_init(GLOB.gas_data))
|
||||
GLOB.auxtools_atmos_initialized = TRUE
|
||||
__gasmixture_register()
|
||||
reaction_results = new
|
||||
@@ -111,9 +108,6 @@ we use a hook instead
|
||||
. = ..()
|
||||
*/
|
||||
|
||||
/datum/gas_mixture/proc/__gasmixture_unregister()
|
||||
/datum/gas_mixture/proc/__gasmixture_register()
|
||||
|
||||
/proc/gas_types()
|
||||
var/list/L = subtypesof(/datum/gas)
|
||||
for(var/gt in L)
|
||||
@@ -121,22 +115,6 @@ we use a hook instead
|
||||
L[gt] = initial(G.specific_heat)
|
||||
return L
|
||||
|
||||
/datum/gas_mixture/proc/heat_capacity() //joules per kelvin
|
||||
|
||||
/datum/gas_mixture/proc/partial_heat_capacity(gas_type)
|
||||
|
||||
/datum/gas_mixture/proc/total_moles()
|
||||
|
||||
/datum/gas_mixture/proc/return_pressure() //kilopascals
|
||||
|
||||
/datum/gas_mixture/proc/return_temperature() //kelvins
|
||||
|
||||
/datum/gas_mixture/proc/set_min_heat_capacity(n)
|
||||
/datum/gas_mixture/proc/set_temperature(new_temp)
|
||||
/datum/gas_mixture/proc/set_volume(new_volume)
|
||||
/datum/gas_mixture/proc/get_moles(gas_type)
|
||||
/datum/gas_mixture/proc/get_by_flag(flag)
|
||||
/datum/gas_mixture/proc/set_moles(gas_type, moles)
|
||||
|
||||
// VV WRAPPERS - EXTOOLS HOOKED PROCS DO NOT TAKE ARGUMENTS FROM CALL() FOR SOME REASON.
|
||||
/datum/gas_mixture/proc/vv_set_moles(gas_type, moles)
|
||||
@@ -150,34 +128,12 @@ we use a hook instead
|
||||
/datum/gas_mixture/proc/vv_react(datum/holder)
|
||||
return react(holder)
|
||||
|
||||
/datum/gas_mixture/proc/scrub_into(datum/gas_mixture/target, ratio, list/gases)
|
||||
/datum/gas_mixture/proc/mark_immutable()
|
||||
/datum/gas_mixture/proc/get_gases()
|
||||
/datum/gas_mixture/proc/add(amt)
|
||||
/datum/gas_mixture/proc/subtract(amt)
|
||||
/datum/gas_mixture/proc/multiply(factor)
|
||||
/datum/gas_mixture/proc/divide(factor)
|
||||
/datum/gas_mixture/proc/get_last_share()
|
||||
/datum/gas_mixture/proc/clear()
|
||||
|
||||
/datum/gas_mixture/proc/adjust_moles(gas_type, amt = 0)
|
||||
set_moles(gas_type, clamp(get_moles(gas_type) + amt,0,INFINITY))
|
||||
|
||||
/datum/gas_mixture/proc/adjust_moles_temp(gas_type, amt, temperature)
|
||||
|
||||
/datum/gas_mixture/proc/adjust_multi()
|
||||
|
||||
/datum/gas_mixture/proc/return_volume() //liters
|
||||
|
||||
/datum/gas_mixture/proc/thermal_energy() //joules
|
||||
|
||||
/datum/gas_mixture/proc/archive()
|
||||
//Update archived versions of variables
|
||||
//Returns: 1 in all cases
|
||||
|
||||
/datum/gas_mixture/proc/merge(datum/gas_mixture/giver)
|
||||
//Merges all air from giver into self. giver is untouched.
|
||||
//Returns: 1 if we are mutable, 0 otherwise
|
||||
|
||||
/datum/gas_mixture/proc/remove(amount)
|
||||
//Removes amount of gas from the gas_mixture
|
||||
@@ -187,12 +143,6 @@ we use a hook instead
|
||||
//Removes amount of gas from the gas mixture by flag
|
||||
//Returns: gas_mixture with gases that match the flag removed
|
||||
|
||||
/datum/gas_mixture/proc/transfer_to(datum/gas_mixture/target, amount)
|
||||
//Transfers amount of gas to target. Equivalent to target.merge(remove(amount)) but faster.
|
||||
|
||||
/datum/gas_mixture/proc/transfer_ratio_to(datum/gas_mixture/target, ratio)
|
||||
//Transfers ratio of gas to target. Equivalent to target.merge(remove_ratio(amount)) but faster.
|
||||
|
||||
/datum/gas_mixture/proc/remove_ratio(ratio)
|
||||
//Proportionally removes amount of gas from the gas_mixture
|
||||
//Returns: gas_mixture with the gases removed
|
||||
@@ -201,10 +151,6 @@ we use a hook instead
|
||||
//Creates new, identical gas mixture
|
||||
//Returns: duplicate gas mixture
|
||||
|
||||
/datum/gas_mixture/proc/copy_from(datum/gas_mixture/sample)
|
||||
//Copies variables from sample
|
||||
//Returns: 1 if we are mutable, 0 otherwise
|
||||
|
||||
/datum/gas_mixture/proc/copy_from_turf(turf/model)
|
||||
//Copies all gas info from the turf into the gas list along with temperature
|
||||
//Returns: 1 if we are mutable, 0 otherwise
|
||||
@@ -217,52 +163,18 @@ we use a hook instead
|
||||
//Performs air sharing calculations between two gas_mixtures assuming only 1 boundary length
|
||||
//Returns: amount of gas exchanged (+ if sharer received)
|
||||
|
||||
/datum/gas_mixture/proc/temperature_share(datum/gas_mixture/sharer, conduction_coefficient,temperature=null,heat_capacity=null)
|
||||
//Performs temperature sharing calculations (via conduction) between two gas_mixtures assuming only 1 boundary length
|
||||
//Returns: new temperature of the sharer
|
||||
|
||||
/datum/gas_mixture/proc/compare(datum/gas_mixture/sample)
|
||||
//Compares sample to self to see if within acceptable ranges that group processing may be enabled
|
||||
//Returns: a string indicating what check failed, or "" if check passes
|
||||
|
||||
/datum/gas_mixture/proc/react(datum/holder)
|
||||
//Performs various reactions such as combustion or fusion (LOL)
|
||||
//Returns: 1 if any reaction took place; 0 otherwise
|
||||
|
||||
/datum/gas_mixture/proc/adjust_heat(amt)
|
||||
//Adjusts the thermal energy of the gas mixture, rather than having to do the full calculation.
|
||||
//Returns: null
|
||||
|
||||
/datum/gas_mixture/proc/equalize_with(datum/gas_mixture/giver)
|
||||
//Makes this mix have the same temperature and gas ratios as the giver, but with the same pressure, accounting for volume.
|
||||
//Returns: null
|
||||
|
||||
/datum/gas_mixture/proc/get_oxidation_power(temp)
|
||||
//Gets how much oxidation this gas can do, optionally at a given temperature.
|
||||
|
||||
/datum/gas_mixture/proc/get_fuel_amount(temp)
|
||||
//Gets how much fuel for fires (not counting trit/plasma!) this gas has, optionally at a given temperature.
|
||||
|
||||
/proc/equalize_all_gases_in_list(list/L)
|
||||
//Makes every gas in the given list have the same pressure, temperature and gas proportions.
|
||||
//Returns: null
|
||||
|
||||
/datum/gas_mixture/proc/__remove_by_flag()
|
||||
|
||||
/datum/gas_mixture/remove_by_flag(flag, amount)
|
||||
var/datum/gas_mixture/removed = new type
|
||||
__remove_by_flag(removed, flag, amount)
|
||||
|
||||
return removed
|
||||
|
||||
/datum/gas_mixture/proc/__remove()
|
||||
/datum/gas_mixture/remove(amount)
|
||||
var/datum/gas_mixture/removed = new type
|
||||
__remove(removed, amount)
|
||||
|
||||
return removed
|
||||
|
||||
/datum/gas_mixture/proc/__remove_ratio()
|
||||
/datum/gas_mixture/remove_ratio(ratio)
|
||||
var/datum/gas_mixture/removed = new type
|
||||
__remove_ratio(removed, ratio)
|
||||
@@ -280,8 +192,6 @@ we use a hook instead
|
||||
parse_gas_string(model.initial_gas_mix)
|
||||
return TRUE
|
||||
|
||||
/datum/gas_mixture/proc/__auxtools_parse_gas_string(gas_string)
|
||||
|
||||
/datum/gas_mixture/parse_gas_string(gas_string)
|
||||
gas_string = SSair.preprocess_gas_string(gas_string)
|
||||
return __auxtools_parse_gas_string(gas_string)
|
||||
|
||||
@@ -72,14 +72,15 @@
|
||||
armor = list(MELEE = 25, BULLET = 10, LASER = 10, ENERGY = 100, BOMB = 0, BIO = 100, RAD = 100, FIRE = 100, ACID = 70)
|
||||
..()
|
||||
if(process)
|
||||
SSair.atmos_machinery += src
|
||||
SSair.start_processing_machine(src)
|
||||
SetInitDirections()
|
||||
|
||||
/obj/machinery/atmospherics/Destroy()
|
||||
for(var/i in 1 to device_type)
|
||||
nullifyNode(i)
|
||||
|
||||
SSair.atmos_machinery -= src
|
||||
|
||||
SSair.stop_processing_machine(src)
|
||||
SSair.pipenets_needing_rebuilt -= src
|
||||
|
||||
dropContents()
|
||||
|
||||
@@ -27,14 +27,14 @@
|
||||
id_tag = ATMOS_GAS_MONITOR_LOOP_DISTRIBUTION
|
||||
|
||||
/obj/machinery/meter/Destroy()
|
||||
SSair.atmos_machinery -= src
|
||||
SSair.stop_processing_machine(src)
|
||||
target = null
|
||||
return ..()
|
||||
|
||||
/obj/machinery/meter/Initialize(mapload, new_piping_layer)
|
||||
if(!isnull(new_piping_layer))
|
||||
target_layer = new_piping_layer
|
||||
SSair.atmos_machinery += src
|
||||
SSair.start_processing_machine(src)
|
||||
if(!target)
|
||||
reattach_to_layer()
|
||||
return ..()
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
/obj/machinery/portable_atmospherics/New()
|
||||
..()
|
||||
SSair.atmos_machinery += src
|
||||
SSair.start_processing_machine(src)
|
||||
|
||||
air_contents = new(volume)
|
||||
air_contents.set_temperature(T20C)
|
||||
@@ -24,8 +24,7 @@
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/portable_atmospherics/Destroy()
|
||||
SSair.atmos_machinery -= src
|
||||
|
||||
SSair.stop_processing_machine(src)
|
||||
disconnect()
|
||||
qdel(air_contents)
|
||||
air_contents = null
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
. = ..()
|
||||
find_circs()
|
||||
connect_to_network()
|
||||
SSair.atmos_machinery += src
|
||||
SSair.start_processing_machine(src)
|
||||
update_icon()
|
||||
component_parts = list(new /obj/item/circuitboard/machine/generator)
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
/obj/machinery/power/generator/Destroy()
|
||||
kill_circs()
|
||||
SSair.atmos_machinery -= src
|
||||
SSair.stop_processing_machine(src)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/power/generator/update_overlays()
|
||||
|
||||
@@ -444,7 +444,7 @@ The reactor CHEWS through moderator. It does not do this slowly. Be very careful
|
||||
//Results: Engineering becomes unusable and your engine irreparable
|
||||
/obj/machinery/atmospherics/components/trinary/nuclear_reactor/proc/meltdown()
|
||||
set waitfor = FALSE
|
||||
SSair.atmos_machinery -= src //Annd we're now just a useless brick.
|
||||
SSair.stop_processing_machine(src)
|
||||
slagged = TRUE
|
||||
color = null
|
||||
update_icon()
|
||||
|
||||
@@ -195,7 +195,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_crystal)
|
||||
/obj/machinery/power/supermatter_crystal/Initialize(mapload)
|
||||
. = ..()
|
||||
uid = gl_uid++
|
||||
SSair.atmos_machinery += src
|
||||
SSair.start_processing_machine(src)
|
||||
countdown = new(src)
|
||||
countdown.start()
|
||||
GLOB.poi_list |= src
|
||||
@@ -214,7 +214,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_crystal)
|
||||
|
||||
/obj/machinery/power/supermatter_crystal/Destroy()
|
||||
investigate_log("has been destroyed.", INVESTIGATE_SUPERMATTER)
|
||||
SSair.atmos_machinery -= src
|
||||
SSair.stop_processing_machine(src)
|
||||
QDEL_NULL(radio)
|
||||
GLOB.poi_list -= src
|
||||
QDEL_NULL(countdown)
|
||||
|
||||
Reference in New Issue
Block a user