#How do I create custom vanilla restrictions for the LevelZ mod using datapacks?

1 messages · Page 1 of 1 (latest)

marble hedge
#

I'm using the LevelZ mod to balance my modpack, but I'm running into an interesting problem. I am using modrinth to create this modpack. I'm able to configure the restrictions for modded items just fine, using this format:

{ "replace": true, "skill": "strength", "level": 20, "item": "minecraft:custom_item", "object": "MOD_DESIGNATION:MODDED_ITEM_TAG" }

However, I can't find a way to edit vanilla item restrictions. Here's what I've tried so far:

{ "replace": true, "skill": "strength", "level": 20, "item": "minecraft:diamond_sword", "object": "minecraft:diamond_sword" //tried removing this as well, since vanilla shouldn't need object designation (I think) }

{ "diamond_sword_restriction": { "skills": { "strength": 20 }, "items": [ "minecraft:diamond_sword" ] } }

No matter what, the game forces the restriction of strength 16 on the diamond sword (and other items). I have a couple ideas as to why this might be happening:

  1. The modpack contains some mod that defines the restrictions of vanilla items and takes priority over datapacks
  2. I'm not formatting the restriction correctly

IMPORTANT INFO

Minecraft version: 1.20.1

File path: C:\Users\MY_NAME\AppData\Roaming\ModrinthApp\profiles\MODPACK_PROFILE_NAME\saves\Test World\datapacks\test_restriction_pack\data\levelz\item\test.json

Documentation for the LevelZ mod: https://github.com/Globox1997/LevelZ (In the README section)

GitHub

https://modrinth.com/mod/levelz. Contribute to Globox1997/LevelZ development by creating an account on GitHub.

mellow zodiac
#

This isn't a datapack question

marble hedge
# mellow zodiac This isn't a datapack question

How so? The only way (that I can find) to edit the mod is through the use of datapacks, which is what I've described. I'm not a json pro by any means and I've only dabbled with datapacks, sorry if this is a stupid question.

mellow zodiac
#

But your issue is with a mod, not with a datapack. Anything you described above is not vanilla datapacking.

How this mod does or does not handle datapacks etc. is not something we can answer.

There are a few things I can suggest you to check, but since it is modded it might just as well do nothing:

  1. Ensure your datapack is applied last.
  2. /datapack list should show you which datapacks are enabled, you should be able to check each of these datapacks by using an archiving tool to see if they also add levelz restrictions or anything like it.
  3. Enable logs and check if any errors are shown when loading your world.
  4. Save and Quit your world between changes, some changes don't work on reload.

Other than that, try some sources related to the mod as this is not a typical datapack. None of the above would do anything let alone parse in vanilla minecraft.

#

It is like you upgrading your bicycle with an engine and asking a bicycle shop to tell you why the engine doesn't work and how to fix it.

marble hedge
#

I see. Well, thank you for your help.