fix: Construction Recipe check for components same as tool fixed. #4514
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.
Purpose of change
Check was bugged, if an item requires charges for tool use but is not
count_by_charges()
only unloaded tools are considered valid components, but the game looks for the extra item that is used in the tools because it cannot discern that it doesn't need to.Describe the solution
An extra check was added so that if the tool uses charges but is not
count_by_charges()
it goes to standard checks. It would technically also work vice-versa but I don't think that use case can even happen under normal circumstances.Describe alternatives you've considered
Testing
Additional context
I don't really think I can fix the display without a lot of code diving into parts I'd rather not.
Checklist