-
-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: resources not being used up correctly when there are missing items
This now always makes it so that output resources are being added to the internal storage. If we do not do this, when there are missing resources, and we have the same ingredient being used multiple times, it would start from scratch for each of that same ingredient, causing a calculation that needs too many resources. So we have to *always* return resources so they can be reused later down the line, even if there are missing resources. However, we must use these resources up correctly if we do end up with missing resources! Otherwise, if another ingredient needs this resource later down the calculation, it will use them when it's not allowed to (the yields of the child calculation must be used up...)
- Loading branch information
1 parent
36bbd76
commit 6bd658a
Showing
3 changed files
with
59 additions
and
18 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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