Adds the atmos type: NoDecay (#26432)

* ddsadsa

ddsadsa

* adds a new MILLA atmos  type

* Build MILLA

* oopsie

* comments

* Update code/__DEFINES/atmospherics_defines.dm

Co-authored-by: Charlie Nolan <funnyman3595@gmail.com>
Signed-off-by: Kyani <65205627+EmeraldCandy@users.noreply.github.com>

* adds commenting

* merged and redid commenting

* Build MILLA

---------

Signed-off-by: Kyani <65205627+EmeraldCandy@users.noreply.github.com>
Co-authored-by: paradisess13[bot] <165046124+paradisess13[bot]@users.noreply.github.com>
Co-authored-by: Charlie Nolan <funnyman3595@gmail.com>
This commit is contained in:
Kyani
2024-08-14 19:21:45 +00:00
committed by GitHub
co-authored by Charlie Nolan paradisess13[bot] <165046124+paradisess13[bot]@users.noreply.github.com>
parent de2380422f
commit 58097d7c5b
6 changed files with 6 additions and 0 deletions
+1
View File
@@ -156,6 +156,7 @@
#define ATMOS_MODE_SPACE 0 //! Tile is exposed to space and loses air every second
#define ATMOS_MODE_SEALED 1 //! Tile has no special behaviour
#define ATMOS_MODE_EXPOSED_TO_ENVIRONMENT 2 //! Tile is exposed to the environment, ex: lavaland
#define ATMOS_MODE_NO_DECAY 3 //! Prevents hot tiles from automatically decaying towards T20C.
/// Lavaland environment: hot, low pressure.
#define ENVIRONMENT_LAVALAND "lavaland"
BIN
View File
Binary file not shown.
+1
View File
@@ -239,6 +239,7 @@ pub(crate) fn internal_set_tile(
};
}
}
3 => tile.mode = AtmosMode::NoDecay,
_ => return Err(eyre!("Invalid atmos_mode: {}", value)),
}
}
+3
View File
@@ -130,6 +130,8 @@ pub(crate) enum AtmosMode {
Sealed,
/// Tile is exposed to the given environment.
ExposedTo { environment_id: u8 },
/// Prevents hot tiles from automatically decaying towards T20C
NoDecay,
}
impl From<AtmosMode> for ByondValue {
@@ -138,6 +140,7 @@ impl From<AtmosMode> for ByondValue {
AtmosMode::Space => ByondValue::from(0.0),
AtmosMode::Sealed => ByondValue::from(1.0),
AtmosMode::ExposedTo { .. } => ByondValue::from(2.0),
AtmosMode::NoDecay => ByondValue::from(3.0),
}
}
}
+1
View File
@@ -437,6 +437,7 @@ pub(crate) fn apply_tile_mode(
my_inactive_tile.thermal_energy *= 1.0 - SPACE_COOLING_FACTOR;
}
}
AtmosMode::NoDecay => {} // No special interactions
}
Ok(())
}
Binary file not shown.