mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-11 10:11:09 +00:00
## About The Pull Request - Fixes #92198 - Fixes #92298 **1) Replaces reagent `on_transfer()` with its corresponding `expose()` proc variants** This PR replaces all known implementations of `/datum/reagent/on_transfer()` with `/datum/reagent/expose_mob()`. We use `expose_mob()` & not the other `expose()` variants because all known implementations were targeting living beings so this was the correct replacement This has 2 benefits - `expose_mob()` gets called correctly when an impure reagent is converted to it's inverse variant like for Cryostylane & Cryogeldia. This isn't the case for `on_transfer()` so we get correct behaviour which fixes the above bug - Removing `on_transfer()` makes the proc `/datum/reagents/trans_to()` much faster performance wise because we aren't calling `update_total()` per reagent transfered now but only once at the end after all reagents are transferred Also there was little to no functional difference between the 2 procs, `expose()` works correctly in comparison & this won't confuse devs when deciding which proc to use. One proc to cover all scenarios **2) Removes unused expose signals** `COMSIG_ATOM_AFTER_EXPOSE_REAGENTS` & `COMSIG_REAGENTS_EXPOSE_ATOM` are not used anywhere in the codebase i.e. no listeners. They can be discarded as dead code **3) Fixes wrong transfer amount passed to `/datum/reagent/intercept_reagents_transfer()` & `/datum/reagents/expose()`** The wrong transfer `amount` was passed when it fact it should use `transfer_amount` which contains the multiplier & proportional multiplier applied. Also the reagent volumes exposed was computed incorrectly resulting in the 2nd issue listed above. Blood transferred to mobs now go to `blood_volume` directly instead of getting added to the mobs reagent holder as long as it's less than `BLOOD_VOLUME_MAXIMUM` level ## Changelog 🆑 fix: reagent intercept operations use correct volumes e.g. ph buffers fix: impure cryostylane now has inverse cryogeldia effects when applied on mods fix: exposing reagents now uses correct volumes i.e. injecting blood into mobs don't increase it exponentially and stops when max levels are reached. Exposure affects of all reagents are lessened upon continuous exposure refactor: refactors how reagent affects are applied on mobs. Report bugs on github /🆑
Core /atom Systems
This is a folder of basic systems that apply to all /atom types, split into relevant files. Keep the files named fittingly and don't put anything in _atom.dm if you can avoid it.