Sophisticated Backpacks

Sophisticated Backpacks

89M Downloads

Mushroom stew duplicated in some situation

TristanKing0 opened this issue ยท 4 comments

commented

Using the latest version of the mod, when I have mushroom stew in my diamond stack upgraded backback and it feeds me I get 128 mushroom stew in my inventory!

Obviously a bug with how the mod handles the wooden bowl, it might exist elsewhere with other food items that have similar mechanics.

commented

I will need more information on this. Retested and it properly just feeds me one and puts an empty bowl in the backpack.

If you have only taken the steps described above I am guessing you're using this in a modpack and there's an interference of another mod happening here. Can you narrow it down to what minimum set of mods needs to be used to get this issue?

commented

After some testing I've worked out it's a conflict with Charm (Reforged in my case) which allows stacking mushroom stew (and other items) to 16.

When the backpack feeds me if I have 1 mushroom stew in my backpack it will consume it as normal and put an empty bowl in my inventory (rather than my backpack).

If I have 2 in a slot it will give me an empty bowl (again in my inventory, not my backpack) but never consume any stew. Infinite bowls and saturation!

If I have 3 it will give me a bowl and increase the stew by 1 so I now have 4.

4 goes to 6, 6 to 10, 18, 34, 66.
Then 128 in one slot and 2 in another.
Then 2 slots full of 128.
Then another slot is filled with 126.
Then that slot is filled to 128 and I get another slot of 124.
Then that slot is filled to 128 and I get another slot of 122.

And so on until I very quickly end up with thousands of stew just from an initial 3. I'm testing with a diamond stack upgrade and assume it'd be even worse with a netherite one.

I assume this issue would be present for other mods that add stacking food items like Mushroom Stew as well and would have one fix in your mod to solve them all.

commented

Just tested that with Charm. It's an issue of charm's implementation - it returns reduced stack (stack - 1 that was eaten) where it's supposed to return the container item (the bowl) and instead puts the bowl directly into player's inventory.
So this will need to be fixed on their side.

And just as a side note I have already tested this previously with other foods that stack and use containers - e.g. there are multiple in Simple Farming mod.

commented

Actually I am looking at this more and missed something in the code. I should be able to fix this for the charm part without breaking it for other mods.