[MIRROR] Fixes crafting menu incorrect use of reagents #915
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Mirrored on Skyrat: Skyrat-SS13/Skyrat-tg#25382
Original PR: tgstation/tgstation#80046
About The Pull Request
The way crafting menu handles reagents is an abomination. It manually updates its volume, rather than calling the correct procs for it and also "clones" reagents like... it does some weird stuff that can leave the beaker in an inconsistent state let's just leave it at that.
Now we properly consume the reagent via
remove_reagent()
proc and don't do stuff manually so it works now. Also added some sanity checks such as>=
and not simply>
when checking for reagent volumes and also checks if we actually found a container in our surroundings which could runtime if none was availableAlso for my sanity please don't tell me to change any single letter var names here. This whole file is crawling with them so let someone else get their GBP from that
Changelog
🆑 SyncIt21
fix: crafting food or any other items that require reagents will not leave behind blank reagents. That and properly updates the holder those reagents are stored in
/:cl: