Copper recipes do not appear in the recipe book
tungstonminer opened this issue · 3 comments
When the player first obtains a copper ingot, the recipe book should get updated with the recipe for a compressed copper ingot. When you obtain a compressed copper ingot, the recipe book should likewise get updated to show all the recipes for the various tools, weapons, armor, etc. In reality, no recipes for any of the items added by this mod get added to the recipe book.
Thank you! I tried experimenting with making a datapack to add them myself, and I was unsuccessful. The best I could do is to have everything get added all at once as soon as a copper ingot was discovered: even though I had them all set up as nicely-tiered advancements. I'm curious to check out how you actually did it. :-)
Initially, I didn't know how to do it either.
I first looked at forge docs (https://mcforge.readthedocs.io/en/latest/utilities/recipes/) and realized that you need to use achievements for this.
I found an achievement generator (https://misode.github.io/advancement/) which had vanilla achievement templates. I tried to find them in the minecraft source code that forge provides, but I couldn't find it.
In the template, I changed parameters I needed, put .json files into src/main/resources/data/copperequipment/advancements. And it worked! I don’t know exactly what path should be in the datapack, but I assume that it is something like copperequipment/advancements.
Then, while looking through the source code of another mod, I accidentally noticed that you can put the achievement files in a different folder in the achievements folder.
Code - https://github.com/Redy1aye/CopperEquipmentForge/tree/CopperEquipment/src/main/resources/data/copperequipment/advancements/recipes