-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rewrite recipe chain calculator #530
base: master
Are you sure you want to change the base?
Conversation
bdf0c69
to
0146a73
Compare
Here you have crafting chain mode disabled. Did it use to do that on shift+ctrl+scroll?
It uses whatever recipe it encounters first. I should probably make it more consistent, because currently to the user it feels random because of hashmap. And maybe color conflicting recipe in gray or something. But functionally, I don't see a way to support multiple recipes that give the same output. If there is a recipe that you need pinned, but that you don't wanna use for some item, you can unpin output from that recipe.
If you unpin an ingredient from the recipe, then graph traversal won't continue, even if that recipe is pinned. For example, iron is not pinned in hopper recipe, so iron is not calculated.
Oops, forgot to filter by group id.
Cause currently it adds/removes 64 or whatever multiple you have set. But now that I think about it, forcing it to be a multiple would be nicer. Noted.
You mean it should treat cells as raw fluids? Makes sense, noted.
That is by design. It is a catalyst that is unused, but it is required for the craft. They were cancelling each other in first implementation, but after some playtesting I found out that it was not very helpful. In general, this tries to mimic the way AE2 autocrafting works. And that's how it would see it.
That's actually Lightly Steam-Cracked fuel in the remainders. Ethylene requires 19000L and cracking recipe will produce 19200. That is a problem I had with the tooltip, because you often can't tell what ingredient/results/remainders are shown, because a lot of them look very similar
You mean showing outputs+remainders as a stack size for outputs? Okay, previously I couldn't exactly figure out what that was.
Do you know where that is calculated? There is no reason it shouldn't work, other than explicitly checking for stack size to be greater than 0. |
Previously, the algorithm worked the same whether the chain was enabled or not
Here it would be correct to change the quantity on the recipe you are on.
How to reset group state? Why do you need a negative value in the final recipe?
yes, it will work fine before
This will mislead the player into crafting a catalyst in quantities he doesn't need. they are no different from a circuit in situations like this. The only thing you can do is to output it as an ingredient in the amount of one item. Otherwise the player will again have to filter out unnecessary things in tooltips/highlights
correctly: Ethylene requires 18800L and cracking recipe will produce 19000.
|
Notes to self, to not forget anything
|
8207981
to
eac0e1d
Compare
Rewrote recipe chain calculator. The main difference is that it now uses graph traversal to calculate things. Fixes GTNewHorizons/GT-New-Horizons-Modpack#17148
Notable features:
There are some differences in how it looks and feels. Here are new behaviors.
Modifying item counts
StackInfo::getFluidCellSize
), but could not find a better approach.Visual
+123
/-123
. This is not required to be a multiple of whatever the recipe output is. Previously it would just change number of items individually.x123
. Background highlights behave the same way.Behavioral and implementation details.
BookmarkRecipeId
. I extract actual recipes at runtime.Some screenshots: