CraftTweaker

CraftTweaker

151M Downloads

Recipe Functions don't Work (mismatched parameters error)/Documentation out of date

Timeslice42 opened this issue ยท 7 comments

commented

I've spent some time trying to get recipe functions to work, and finally just gave up and tried the examples from the wiki. The examples do not work, with CT failing to recognize the anonymous functions as ZenTypeNative

Scripts:
scripts.zip

Affected Versions (Do not use "latest"):

  • Minecraft: 1.12.2
  • Forge: 14.23.0.2515
  • Crafttweaker: 1.12-4.0.8

Your most recent log file where the issue was present:

CraftTweaker Log: https://paste.ee/p/rlq2c
Forge Log:
latest.zip

commented

You'll need to also add a name for the Optionals to work...
ZS thing, dunno why but adding the name usually makes em work for me ๐Ÿ˜‰

commented

Without the recipe functions the examples work just fine.

commented

What do you mean with adding a name? I'm not sure I understand...

commented

I mean that you should add a string as first parameter so recipes.addShaped(out,ins,functionA, functionB) becomes recipes.addShaped(name,out,ins,functionA, functionB)

commented

Thanks

commented

What does naming a recipe allow you to do?

commented

naming a recipe was introduced in 1.12.2, to you, it has no use, just give it a random name that is unique to that recipe