Fix Voiding and Incorrect Input Consumption in Parallel Recipes #2649
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.
What
This PR fixes two issues relating to parallel recipes:
The only recipe with non-cached inputs in vanilla GT is canning machine filling recipes.
Fixes Nomi-CEu/Nomi-CEu#924
Implementation Details
This PR simply copies the GTRecipeInput when applying parallel, instead of modifying it directly. This has no effect on cached inputs, which are copied when
withAmount
is called regardless.For the output voiding fix, this PR simply checks for the minimum of the slot's available space and the stack's
maxStackSize
, as empty slots return an available space of 64 regardless of intended stack.Outcome
Fixes Nomi-CEu/Nomi-CEu#924
Fixes edge case voiding with parallel recipes
Additional Information
This PR was originally implemented in Labs here: Nomi-CEu/Nomi-Labs@1c35289 & Nomi-CEu/Nomi-Labs@eb4fab3
Potential Compatibility Issues
None