NeoForge 1.21.1 - Creating a Data Pack
DumbXBoxAcct opened this issue ยท 4 comments
Hoping you can give me a little direction. First off, though, thank you for this fabulous mod, it fills a yawning gap in available trades in NeoForge, since there aren't a lot of mods to customize villager trades available yet, that I've seen.
I read your Wiki and can successfully add trades and categories if I modify your .JAR file using Winzip, so I know that my underlying files are correct, but I'd like to do it the right way and load them from a datapack. Unfortunately, haven't had any luck with either of the two following methods:
-
Putting the files into paths in the datapack using the paths in the JAR:
a. data \ [mod name]\market_presets
(NOTE: there are no spaces in the actual path above, GitHub wouldn't let me put a " \ " in next to the text)
b. data\farmingforblockheads\market_categories
c. data\farmingforblockheads\recipe\market[mod name]\
The datapack's root then shows "data" and "pack.mcmeta"
Have also tried putting the above "data" folder with the above paths into a folder called "farmingforblockheads", so that the datapack's root shows "farmingforblockheads" and "pack.mcmeta"
-
Using the folders in Minecraft's Config folder, with recipes in a datapack:
a. Copied the market presets file into the ".minecraft\config\market_presets folder"
b. Copied the market_categories file into the ".minecraft\config\market_categories" folder
c. Put the recipe into a datapack in the "data\farmingforblockheads\recipe\market[mod name]" folder
Again, the datapack's root shows shows "data" and "pack.mcmeta"
Can you please let me know what the full, correct paths would be for the three files necessary to add items & categories from a datapack into NeoForge 1.21.1?
Your pack.mcmeta has a json syntax error, missing a closing bracket for supported_formats.
After fixing that, the pack shows up for me in /datapack list and can be enabled.
{
"pack": {
"description": "Datapack for Farming for Blockheads Market items",
"pack_format": 15,
"supported_formats": {
"min_inclusive": 15,
"max_inclusive": 34
}
}
}Also, since your axes category is defined in the namespace "ffbitems", the category in goldenaxe.json should be ffbitems:axes.
Right, you are, Blay, I'm in business! Thank you so much for your quick assistance, I really appreciate it!
data/<namespace>/market_presets/your_preset.jsondata/<namespace>/market_categories/your_category.jsondata/<namespace>/recipe/your_recipe.json
where <namespace> is a name for your datapack. You also have to enable the datapack with the /datapack command and /reload when you make changes.
So, theoretically, the attached datapack should work, since I've followed the rules above but it doesn't work, for some reason. Is there something that I missed?