From c97b2e67193359c09c8160fa8ccf0e77c91b0412 Mon Sep 17 00:00:00 2001 From: Crosarius <30341877+Crosarius@users.noreply.github.com> Date: Sun, 9 Jun 2024 02:39:04 +1000 Subject: [PATCH] Butanol Drink Fix (#19359) fixes https://github.com/Aurorastation/Aurora.3/issues/19343 Fixes butanol becoming strength 0 after being ingested by Humans, due to a mistake in handling the strength variable. I've removed the code responsible, and made a small change that makes that part unnecessary anyway. Tested and now working as intended. --- .../Chemistry-Reagents-Dispenser.dm | 12 ++-- html/changelogs/Crosarius-butanolfix2.yml | 58 +++++++++++++++++++ 2 files changed, 63 insertions(+), 7 deletions(-) create mode 100644 html/changelogs/Crosarius-butanolfix2.yml diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Dispenser.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Dispenser.dm index ce8af4cece9..b2a1456e141 100644 --- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Dispenser.dm +++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Dispenser.dm @@ -269,13 +269,11 @@ M.adjustNutritionLoss(-nutriment_factor * removed) M.adjustHydrationLoss(-hydration_factor * removed) - if (adj_temp > 0 && M.bodytemperature < targ_temp) // 310 is the normal bodytemp. 310.055 - M.bodytemperature = min(targ_temp, M.bodytemperature + (adj_temp * TEMPERATURE_DAMAGE_COEFFICIENT)) - if (adj_temp < 0 && M.bodytemperature > targ_temp) - M.bodytemperature = min(targ_temp, M.bodytemperature - (adj_temp * TEMPERATURE_DAMAGE_COEFFICIENT)) - else - strength = 0 //Only Unathi are intoxicated by butanol. - ..() + if (adj_temp > 0 && M.bodytemperature < targ_temp) // 310 is the normal bodytemp. 310.055 + M.bodytemperature = min(targ_temp, M.bodytemperature + (adj_temp * TEMPERATURE_DAMAGE_COEFFICIENT)) + if (adj_temp < 0 && M.bodytemperature > targ_temp) + M.bodytemperature = min(targ_temp, M.bodytemperature - (adj_temp * TEMPERATURE_DAMAGE_COEFFICIENT)) + /singleton/reagent/hydrazine name = "Hydrazine" diff --git a/html/changelogs/Crosarius-butanolfix2.yml b/html/changelogs/Crosarius-butanolfix2.yml new file mode 100644 index 00000000000..9099e4bef93 --- /dev/null +++ b/html/changelogs/Crosarius-butanolfix2.yml @@ -0,0 +1,58 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# - (fixes bugs) +# wip +# - (work in progress) +# qol +# - (quality of life) +# soundadd +# - (adds a sound) +# sounddel +# - (removes a sound) +# rscadd +# - (adds a feature) +# rscdel +# - (removes a feature) +# imageadd +# - (adds an image or sprite) +# imagedel +# - (removes an image or sprite) +# spellcheck +# - (fixes spelling or grammar) +# experiment +# - (experimental change) +# balance +# - (balance changes) +# code_imp +# - (misc internal code change) +# refactor +# - (refactors code) +# config +# - (makes a change to the config files) +# admin +# - (makes changes to administrator tools) +# server +# - (miscellaneous changes to server) +################################# + +# Your name. +author: Crosarius + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, this gets changed to [] after reading. Just remove the brackets when you add new shit. +# Please surround your changes in double quotes ("). It works without them, but if you use certain characters it screws up compiling. The quotes will not show up in the changelog. +changes: + - bugfix: "Fixes butanol drinks globally becoming strength 0 after being ingested by non-Unathi."