mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-27 18:12:00 +00:00
## About The Pull Request This PR is a continuing refactor of and fixes bugs introduced by my prior PR #71864  Due to many functions in reagents having been implemented on top of prior buggy code, their new behaviors are not as expected in-game, and as a result reagents damage/heal robotic/cybernetic bodyparts/organs when not appropriate; bugs like healing robotic arms with Libital is currently possible. To fix the errant behaviors in the newly debugged code, I have added three variables to `datum/reagent` which are used throughout reagent code, mainly inside of `on_mob_life` etc: - `affected_bodytype = BODYTYPE_ORGANIC` - Used if the reagent damages/heals bodyparts (Brute/Fire) of an affected mob. - `affected_biotype = MOB_ORGANIC` - Used if the reagent damages/heals generic damage (Toxin/Oxygen) of an affected mob. - `affected_organtype = ORGAN_ORGANIC` - Used if the reagent damages/heals organ damage of an affected mob. The diff is large, and I have refactored the readability/maintainability around the sections of code I was modifying. At one point I chose to perform a quality pass on reagents because I found it quite hard to maintain reagents code in its current state. This PR also replaces many single-letter variables with more descriptive and readable variable names. I also found and fixed a stray tab which was located in the flavortext of `proc/item_heal_robotic` ## Why It's Good For The Game Due to an old bug being fixed recently by PR #71864 a lot of healing/damaging reagents now have an effect on robotic bodyparts. This PR corrects the issue and changes reagents to explicitly define the body type, bio type, and organ type which they can affect with helaing/damage. This PR replaces a lot of single-letter variable names with more descriptive names. I also fixed a small typo in `item_heal_robotic` which was inserting an extra tab. ## Changelog 🆑 fix: Fixed a stray-tab typo in "item_heal_robotic" fix: Fixed reagents and other effects which were inappropriately affecting robotic limbs. code: Refactored all of reagents code to be more readable and maintainable. /🆑 Co-authored-by: Time-Green <timkoster1@hotmail.com>