emilyploszaj / emi

A featureful and accessible item and recipe viewer
MIT License
220 stars 46 forks source link

chances of recipes in recipe tree crafting mode ignored (1.1.3+1.20.1+fabric) #471

Open MrRedstoneToGo opened 3 months ago

MrRedstoneToGo commented 3 months ago

Look at the soul sand: 2024-03-16_02 26 20 2024-03-16_02 26 28 Shouldn't it be ~563 soul sand at the second picture? I think EMI ignores chances in the recipe tree crafting mode but copies the ingredients at the bottom of the recipe tree (which are marked yellow)

PS: Ignore that you can't craft 11 gold nuggets to an ingot without rest

emilyploszaj commented 3 months ago

This is working as intended, while it would be better to display the approximate equality there really isn't that much space, and crafting a recipe tree with chance doesn't make a ton of sense inherently.

MrRedstoneToGo commented 3 months ago

It's just a bit annoying. If I wash soul sand, the number in this mode just decreases by 1 instead of 9. So I have to look in the recipe tree every time to estimate the amount of sand for haunting.

emilyploszaj commented 3 months ago

Oh I was looking at the wrong thing, yes that's definitely an issue.

MrRedstoneToGo commented 3 months ago

Thanks a lot.

MrRedstoneToGo commented 3 months ago

I you've fixed this: Is there any way to tell EMI in the recipe tree crafting mode that you have already pruduced a fluid?

emilyploszaj commented 3 months ago

No, if it's not in your inventory, which is pretty difficult for a fluid to be, it'll be counted as not present. If you complete any step above that requires the fluid, it'll disappear.

MrRedstoneToGo commented 3 months ago

The recipe tree has one big problem: It miscalculates with chances. Another bug, this time with catalysts: 2024-03-19_19 50 40 Regardless of the output of a recipe, EMI should make the amount of catalyst liquids/items only (!) dependent on the description in the recipe.

MrRedstoneToGo commented 1 week ago

Since the (original) thing with the crafting mode under the favorites side bar isn't fixed yet (sorry for the mess), I looked a bit into EMI's code and it seems that you simply forgot to implement the devisor/chance at https://github.com/emilyploszaj/emi/blob/64a81e8537809b6ffd9ceef5d1a8992cd131f9f6/xplat/src/main/java/dev/emi/emi/runtime/EmiFavorites.java#L257 and https://github.com/emilyploszaj/emi/blob/64a81e8537809b6ffd9ceef5d1a8992cd131f9f6/xplat/src/main/java/dev/emi/emi/runtime/EmiFavorites.java#L260