Adds Hydrogen - The Framework for more Atmos Gases (#30742)

* IMPORTANT MILESTONE, AIR IS BREATHABLE

* the vibrations of the SM in my headphones are pleasing (no stupid hotspots)

* sanity check, it all works

* SM is fine

* this will work first try

* linter

* "thank you, warriorstar" everyone says in unison

* Build Rust library

* finishing touches (hopefully)

* Build Rust library

* update gas_mixture.dm to include hydrogen burning

* Build Rust library

* hydrogen should be the right color on gas analyzers

* i JUST rebuilt it

* adds agent B and Hydrogen floors

* update the h2 canister

* caniser bad speling

* in aa we trust

* Build Rust library

* Build Rust library

---------

Co-authored-by: paradisess13[bot] <165046124+paradisess13[bot]@users.noreply.github.com>
This commit is contained in:
Hayden Redacted
2025-11-03 21:05:26 +00:00
committed by GitHub
co-authored by paradisess13[bot] <165046124+paradisess13[bot]@users.noreply.github.com>
parent 096cbdd9a1
commit 99d57fd35d
42 changed files with 458 additions and 58 deletions
+4
View File
@@ -10,6 +10,7 @@
var/cdiox = 0
var/nitrox = 0
var/agentbx = 0
var/hydrogen = 0
/datum/buildmode_mode/atmos/show_help(mob/user)
@@ -31,6 +32,7 @@
cdiox = tgui_input_number(user, "CO2 ratio", "Input", 0, 100000, 0, round_value = FALSE)
nitrox = tgui_input_number(user, "N2O ratio", "Input", 0, 100000, 0, round_value = FALSE)
agentbx = tgui_input_number(user, "Agent B ratio", "Input", 0, 100000, 0, round_value = FALSE)
hydrogen = tgui_input_number(user, "Hydrogen ratio", "Input", 0, 100000, 0, round_value = FALSE)
/datum/buildmode_mode/atmos/proc/ppratio_to_moles(ppratio)
// ideal gas equation: Pressure * Volume = Moles * r * Temperature
@@ -51,6 +53,7 @@
air.set_carbon_dioxide(ppratio_to_moles(cdiox))
air.set_sleeping_agent(ppratio_to_moles(nitrox))
air.set_agent_b(ppratio_to_moles(agentbx))
air.set_hydrogen(ppratio_to_moles(hydrogen))
for(var/turf/T in block(cornerA,cornerB))
if(issimulatedturf(T))
@@ -66,6 +69,7 @@
T.carbon_dioxide = air.carbon_dioxide()
T.sleeping_agent = air.sleeping_agent()
T.agent_b = air.agent_b()
T.hydrogen = air.hydrogen()
// admin log
log_admin("Build Mode: [key_name(user)] changed the atmos of region [COORD(cornerA)] to [COORD(cornerB)]. T: [temperature], P: [pressure], Ox: [oxygen]%, N2: [nitrogen]%, Plsma: [plasma]%, CO2: [cdiox]%, N2O: [nitrox]%. [ctrl_click ? "Overwrote base space turf gases." : ""]")