Patbox / brewery

Create alcoholic and non-alcoholic drinks with cauldrons and barrels! Server Side mod for Fabric/Quilt
GNU Lesser General Public License v3.0
22 stars 12 forks source link

0.4.3 Compatibility with CraftTweaker on Minecrat 1.20.1 + Fabric #23

Open A-Smith opened 8 months ago

A-Smith commented 8 months ago

Having Patbox's Brewery 0.4.3 installed seems to cause CraftTweaker recipes that use item transformations to fail. For example, this recipe (create rabbit hide from leather using shears) works fine in a modpack with 160 mods:

import crafttweaker.api.ingredient.transform.type.TransformDamage;
import crafttweaker.api.item.IItemStack;

craftingTable.addShapeless("shear_small_hide_from_leather", <item:minecraft:rabbit_hide> * 4, [
    <item:minecraft:leather>,
    <item:minecraft:shears>.anyDamage().transformDamage()
]);

(Inside the .minecraft folder for the instance, save this as scripts/recipe_test.zs.)

but as soon as I add Patbox's Brewery to the modpack, this recipe fails to load with the error:

[22:26:07] [Render thread/INFO]: [System] [CHAT] [WARN]: Shapeless recipe with ID 'crafttweaker:shear_small_hide_from_leather' contains null or empty ingredients, removing entries! 
[22:26:08] [Render thread/INFO]: Loaded 20 advancements

To try and narrow down the problem, I created a modpack with only four mods: Patbox's Brewery, CraftTweaker, and CraftTweaker's dependencies. I used the latest versions of each mod available for Minecraft/Fabric 1.20.1. The total list of mods is:

I observe the same behaviour: if I disable Brewery, then the recipe works; if I enable it, it fails.

I know that Brewery 0.4.3 is an older version. To test to see if this was fixed in a newer version, I installed the latest versions of mods I could. The latest version of Minecraft that CraftTweaker supports on Fabric is currently 1.20.2, so I installed the following:

So it appears the compatibility issue either went away with Brewery 0.5. Are you able to investigate the cause and ideally back-port either a fix or a release of Brewery 0.5 for Minecraft 1.20.1? I'd love to be able to use this mod in a modpack I'm creating, but too many of the other mods in the pack are stuck on 1.20.1, and I rely on CraftTweaker heavily to balance the pack and tweak crafting recipes to avoid conflicts.

Patbox commented 8 months ago

To be fair I'm not sure how Brewery could cause that, as only difference between 0.4.3 and 0.5 are update related https://github.com/Patbox/brewery/commit/2a5ea45e9ddd58866574a57da15bcc00782c2a1e and none of the used libraries touch anything related to loading recipes. This might be a bug on CT side maybe? I don't know really