mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-09 05:11:36 +01:00
d3584b1d1c
* LINDA -> MILLA * Tiles now change their atmos mode properly. * Fixed a bug that made walls generate supercold air when deconstructed/destroyed. * Apply suggestions from code review Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> Co-authored-by: GDN <96800819+GDNgit@users.noreply.github.com> Signed-off-by: Charlie Nolan <funnyman3595@gmail.com> * Begone, var! * MILLA -> milla * Lint. * More lint. * Prevent negative/NaN atmos from spreading. * Made fires start more reliably. * Undef what the rest should not see. * Enums are nice. * Match LINDA better. * Debugging verbs. * Debug verb fixes. * Labelled more lavaland stuff with ATMOS_MODE_LAVALAND * Block superconductivity on a couple more things for Lavaland. * Updated milla.dll * Lavaland map fixes. * Missed a spot. * Begone, var! (again) * Add libmilla_ci.so for continuous integration tests. * Install/contributing instructions for MILLA. * Directional plasmaglass windows on shuttles shouldn't stop protecting from heat after moving. * Banish bad naming. * Better naming and debug stats for SSair. * Apply suggestions from code review Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com> Signed-off-by: Charlie Nolan <funnyman3595@gmail.com> * Magic numbers and formatting. * Don't screw up the temperature during reactions. * Efficiency and readability. * Fix hotspots. * Removed redundant safety (MILLA will already output an error) * Optimizations. * oops * TGS build script update. * Change API of gas_mixture and how you get one from a turf. * Get in there. * so many vars * MILLA binary updates. * Lint * Made MT cost more honest. * Gave MILLA a read-only mode. * More read-only vs synchronized mode work. * Even more. * Synchronize disposals. * Updated a bunch of stuff to use SSair.synchronize or GM.synchronize. * MILLA <3 Tracy * lint * cargo fmt * more lint * Test needed MILLA sync. * Silence atmos machinery that's behaving as intended, but continue objecting to other potential failures to synchronize. * Push new MILLA DLL * Build MILLA * Update PR instructions for MILLA. * Add some fancy plasmaglass windows to the Lifebringers' ship. * The golems remembered that they should insulate *all* their engines. * First round of TM bugfixes. * Build MILLA * fix two lavaland ruin turf types * bunch more maps * fixes milla ci and makes the interesting turf verb better * Solid turfs can no longer conduct heat (for now...) * Made indoor tiles in beach and winter biodomes not lavaland air. * Re-added random IT teleport, adjusted warning message * Fixed a tinted window on Lavaland to be a plasglass window instead. * Made firelocks and holofans heatproof * Made RPD auto-wrench pipes if you have a wrench in your offhand. * Runtime fixes. * Made visuals update more reliably. * Lint * Update .github/CONTRIBUTING.md Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com> Signed-off-by: Charlie Nolan <funnyman3595@gmail.com> * Build MILLA * The Syndicate have installed tiny fans on their research base. * The syndicate have figured out how to make plastitanium windows heatproof. * This is getting out of hand. Now there are two of them. * Un-break the auto-wrenching that I broke before committing. * Build MILLA * Build MILLA * Massive MILLA refactor, assorted bugfixes. * Build MILLA * Explicit typing. * Less sleeping/blocking. * Build MILLA * Yes, yes, this part can sleep. * Build MILLA * SSair reporting improvements. * Build MILLA * Please do not dock twice and splat yourself. * Build MILLA * Pls to not make SM go nuts. * Build MILLA * Build MILLA * Added stricter lower bounds on plasmafire, fixing perpetually-burning SM. * Build MILLA * Lint * Temporary logging, begone. * Build MILLA * Prevent hotspot strobing. * Add in radiate_to_spess behavior. * Build MILLA * progress * Compiling is good. * bugfixes * Progress. * Ruins update. * This one exists. * Fixup temporary hotspots to last longer than one tick. * Add/fix comments. * Cut the slash. * Fix test. * No sleep for you. * Build MILLA * Prevent nested MILLA safety from runtiming. * Build MILLA * Runtime fix. * Build MILLA * Fix canisters not updating icon when gas contents change. * Build MILLA * Build MILLA * Fixed an issue that made mechs very cold on environment air. * Build MILLA * oops * Build MILLA * Walls can make loud noises again. * Build MILLA * Fixes a rare runtime. * Build MILLA * Update .github/DOWNLOADING.md Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com> Signed-off-by: Charlie Nolan <funnyman3595@gmail.com> * Review suggestions * Lint * Build MILLA * bound_mixtures now only contains mixtures that can be written * Build MILLA * Apply suggestions from code review Co-authored-by: Matt <116982774+Burzah@users.noreply.github.com> Signed-off-by: Charlie Nolan <funnyman3595@gmail.com> * Build MILLA * Restore the original async behavior of pyro anomalies. * Build MILLA * Build MILLA * Make the safety assertion in /datum/milla_safe safer. * Build MILLA --------- Signed-off-by: Charlie Nolan <funnyman3595@gmail.com> Co-authored-by: FunnyMan3595 (Charlie Nolan) <funnyman@google.com> Co-authored-by: Burzah <116982774+Burzah@users.noreply.github.com> Co-authored-by: GDN <96800819+GDNgit@users.noreply.github.com> Co-authored-by: AffectedArc07 <25063394+AffectedArc07@users.noreply.github.com> Co-authored-by: paradisess13[bot] <165046124+paradisess13[bot]@users.noreply.github.com> Co-authored-by: warriorstar-orion <orion@snowfrost.garden> Co-authored-by: GDN <Roanrichards1@Gmail.com>
161 lines
4.9 KiB
Plaintext
161 lines
4.9 KiB
Plaintext
/// Knockdown time for slipping on water
|
|
#define WATER_WEAKEN_TIME 4 SECONDS
|
|
/turf/simulated
|
|
name = "station"
|
|
/// Used to check if the turf is wet. Really should just be an object on the turf
|
|
var/wet = 0
|
|
/// Used to store the wet turf overlay. Really should just be an object on the turf
|
|
var/image/wet_overlay = null
|
|
/*
|
|
Atmos Vars
|
|
*/
|
|
oxygen = MOLES_O2STANDARD
|
|
nitrogen = MOLES_N2STANDARD
|
|
var/to_be_destroyed = 0 //Used for fire, if a melting temperature was reached, it will be destroyed
|
|
var/max_fire_temperature_sustained = 0 //The max temperature of the fire which it was subjected to
|
|
/// The excited group we're linked to. Used for zone atmos calculations
|
|
var/datum/excited_group/excited_group
|
|
/// Is this turf active?
|
|
var/excited = 0
|
|
/// Was this turf recently activated? Probably not needed anymore
|
|
var/recently_active = 0
|
|
var/archived_cycle = 0
|
|
var/current_cycle = 0
|
|
/// The active hotspot on this turf. The fact this is done through a literal object is painful
|
|
var/obj/effect/hotspot/active_hotspot
|
|
/// The temp we were when we got archived
|
|
var/temperature_archived
|
|
/// Current gas overlay. Can be set to plasma or sleeping_gas
|
|
var/atmos_overlay_type = null
|
|
/// If a fire is ongoing, how much fuel did we burn last tick?
|
|
/// Value is not updated while below PLASMA_MINIMUM_BURN_TEMPERATURE.
|
|
var/fuel_burnt = 0
|
|
|
|
/turf/simulated/proc/break_tile()
|
|
return
|
|
|
|
/turf/simulated/proc/burn_tile()
|
|
return
|
|
|
|
/turf/simulated/cleaning_act(mob/user, atom/cleaner, cleanspeed = 50, text_verb = "clean", text_description = " with [cleaner].", text_targetname = name)
|
|
if(!..())
|
|
return
|
|
|
|
if(!cleaner.can_clean())
|
|
return
|
|
|
|
clean_blood()
|
|
for(var/obj/effect/O in src)
|
|
if(O.is_cleanable())
|
|
qdel(O)
|
|
|
|
/turf/simulated/water_act(volume, temperature, source)
|
|
. = ..()
|
|
|
|
if(volume >= 3)
|
|
MakeSlippery()
|
|
|
|
quench(1000, 2)
|
|
|
|
/// Quenches any fire on the turf, and if it does, cools down the turf's air by the given parameters.
|
|
/turf/simulated/proc/quench(delta, divisor)
|
|
var/found = FALSE
|
|
for(var/obj/effect/hotspot/hotspot in src)
|
|
qdel(hotspot)
|
|
found = TRUE
|
|
|
|
if(!found)
|
|
return
|
|
|
|
var/datum/milla_safe/turf_cool/milla = new()
|
|
milla.invoke_async(src, delta, divisor)
|
|
|
|
/datum/milla_safe/turf_cool
|
|
|
|
/datum/milla_safe/turf_cool/on_run(turf/T, delta, divisor)
|
|
var/datum/gas_mixture/air = get_turf_air(T)
|
|
air.set_temperature(max(min(air.temperature()-delta * divisor,air.temperature() / divisor), TCMB))
|
|
air.react()
|
|
|
|
/*
|
|
* Makes a turf slippery using the given parameters
|
|
* @param wet_setting The type of slipperyness used
|
|
* @param time Time the turf is slippery. If null it will pick a random time between 790 and 820 ticks. If INFINITY then it won't dry up ever
|
|
*/
|
|
/turf/simulated/proc/MakeSlippery(wet_setting = TURF_WET_WATER, time = null) // 1 = Water, 2 = Lube, 3 = Ice, 4 = Permafrost
|
|
if(wet >= wet_setting)
|
|
return
|
|
wet = wet_setting
|
|
if(wet_setting != TURF_DRY)
|
|
if(wet_overlay)
|
|
overlays -= wet_overlay
|
|
wet_overlay = null
|
|
var/turf/simulated/floor/F = src
|
|
if(istype(F))
|
|
if(wet_setting >= TURF_WET_ICE)
|
|
wet_overlay = image('icons/effects/water.dmi', src, "ice_floor")
|
|
else
|
|
wet_overlay = image('icons/effects/water.dmi', src, "wet_floor_static")
|
|
else
|
|
if(wet_setting >= TURF_WET_ICE)
|
|
wet_overlay = image('icons/effects/water.dmi', src, "ice_floor")
|
|
else
|
|
wet_overlay = image('icons/effects/water.dmi', src, "wet_static")
|
|
wet_overlay.plane = FLOOR_OVERLAY_PLANE
|
|
overlays += wet_overlay
|
|
if(time == INFINITY)
|
|
return
|
|
if(!time)
|
|
time = rand(790, 820)
|
|
addtimer(CALLBACK(src, PROC_REF(MakeDry), wet_setting), time)
|
|
|
|
/turf/simulated/MakeDry(wet_setting = TURF_WET_WATER)
|
|
if(wet > wet_setting)
|
|
return
|
|
wet = TURF_DRY
|
|
if(wet_overlay)
|
|
overlays -= wet_overlay
|
|
|
|
/turf/simulated/Entered(atom/A, atom/OL, ignoreRest = 0)
|
|
..()
|
|
if(!ignoreRest)
|
|
if(ishuman(A))
|
|
var/mob/living/carbon/human/M = A
|
|
if(IS_HORIZONTAL(M))
|
|
return 1
|
|
|
|
if(M.flying)
|
|
return ..()
|
|
|
|
switch(src.wet)
|
|
if(TURF_WET_WATER)
|
|
if(!(M.slip("the wet floor", WATER_WEAKEN_TIME, tilesSlipped = 0, walkSafely = 1)))
|
|
M.inertia_dir = 0
|
|
return
|
|
|
|
if(TURF_WET_LUBE) //lube
|
|
M.slip("the floor", 10 SECONDS, tilesSlipped = 3, walkSafely = 0, slipAny = 1)
|
|
|
|
|
|
if(TURF_WET_ICE) // Ice
|
|
if(M.slip("the icy floor", 8 SECONDS, tilesSlipped = 0, walkSafely = 0))
|
|
M.inertia_dir = 0
|
|
if(prob(5))
|
|
var/obj/item/organ/external/affected = M.get_organ("head")
|
|
if(affected)
|
|
M.apply_damage(5, BRUTE, "head")
|
|
M.visible_message("<span class='warning'><b>[M]</b> hits their head on the ice!</span>")
|
|
playsound(src, 'sound/weapons/genhit1.ogg', 50, 1)
|
|
|
|
if(TURF_WET_PERMAFROST) // Permafrost
|
|
M.slip("the frosted floor", 10 SECONDS, tilesSlipped = 1, walkSafely = 0, slipAny = 1)
|
|
|
|
/turf/simulated/ChangeTurf(path, defer_change = FALSE, keep_icon = TRUE, ignore_air = FALSE, copy_existing_baseturf = TRUE)
|
|
. = ..()
|
|
QUEUE_SMOOTH_NEIGHBORS(src)
|
|
|
|
/turf/simulated/proc/is_shielded()
|
|
return
|
|
|
|
#undef WATER_WEAKEN_TIME
|