Reworked recipe group color to not be stored on recipe instance - #5298
Open
Archengius wants to merge 1 commit into
Open
Reworked recipe group color to not be stored on recipe instance#5298Archengius wants to merge 1 commit into
Archengius wants to merge 1 commit into
Conversation
screret
approved these changes
Aug 16, 2026
Member
|
Holding off on this as this will probably be done in 9.0 when we plan to do a general refactor of recipe stuff, including splitting recipe run data out of GTRecipe |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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
Reworked recipe group color to not be stored on recipe instance. This makes recipe group coloring consistent across all possible recipe execution paths across all machines (e.g. distillation tower, research station, and other special cases of recipe matching) and all entry points to setupRecipe (some machines have custom logic there that may run with the original, uncopied recipe).
Implementation Details
ActionResult returned from recipe runner now stores assignedGroupColor value assigned by the recipe runner if no predefined group color was specified in the recipe handler call. Recipe handling family of functions now explicitly accepts recipe group color rather than implicitly reading it from recipe object. Running recipe group color is now stored on the recipe logic and not implicitly in the copied recipe. setupRecipe now explicitly takes recipe group color alongside the recipe, rather than expecting it to be set on the recipe. Consistency edits across the codebase to make sure all machines correctly handle recipe group coloring (most notably distillation tower).
AI Usage
Claude Sonnet 5 was used to review the code. All of the code is hand-written.
Outcome
All machines and recipe logic implementations now correctly handle recipe group coloring under all circumstances and entry points to setupRecipe. group coloring information is always consistent after being assigned first during recipe matching.
How Was This Tested
Tested a few multiblocks without colored buses and with colored buses and made sure the coloring logic works as expected.
Potential Compatibility Issues
API did change, most notably RecipeHelper family of functions, RecipeLogic overridable functions, and ActionResult SUCCESS and PASS constants were replaced with factory methods.