GregTech CE Unofficial

GregTech CE Unofficial

412k Downloads

Recipes defined in code replace decomposition recipes

ALongStringOfNumbers opened this issue ยท 0 comments

commented

GregTech CEu Version

2.4.1

Modpack Used

No response

Addons Installed

No response

Environment

singleplayer

New Worlds

Yes

Cross-Mod Interaction

No

Expected Behavior

Recipes defined via code that clash with decomposition recipes to be counted as duplicate.

Actual Behavior

Recipes that are defined in code can replace auto generated decomposition recipes, while recipes defined via crafttweaker do not do this (probably because of when the recipes are loaded?)

For example, this recipe defined in code will replace the wood plank -> wood dust decomposition recipe

        MACERATOR_RECIPES.recipeBuilder().EUt(30).duration(100)
                .notConsumable(new ItemStack(Blocks.PLANKS, 2))
                        .output(Blocks.STONE)
                                .buildAndRegister();

However, when the recipe is defined via crafttweaker such as

macerator.recipeBuilder()
        .notConsumable(<minecraft:planks> * 2)
        .outputs([<minecraft:stone>])
        .EUt(30).duration(100).buildAndRegister();

The recipe is correctly caught as a duplicate and not registered

Steps to Reproduce

Add recipe via script/code and join the game, noticing the replaced recipe, or the warning of a recipe conflict.

Additional Information

No response