Jump to content

Recommended Posts

Posted

I'm having a bit of an issue trying to override the vanilla drops of Iron and gold ore to drop ore items instead of the block. I think I have it set up correctly, but in game when I mine the blocks, they just drop nothing. Doesn't matter what tool or tool level I mine with, or silk touch, fortune, or anything they just drop nothing. My vanilla loot tables are all located in src/main/resources/data/minecraft/loot_tables/blocks and named the same as the vanilla ones (iron_ore, etc.).

 

Here is the loot table code.. which is most likely the issue. I copied it straight from the diamond ore loot table since I want the others to basically have the exact same functionality, just drop their own items:

 

"type": "minecraft:block",
  "pools": [
    {
      "rolls": 1,
      "entries": [
        {
          "type": "minecraft:alternatives",
          "children": [
            {
              "type": "minecraft:item",
              "conditions": [
                {
                  "condition": "minecraft:match_tool",
                  "predicate": {
                    "enchantments": [
                      {
                        "enchantment": "minecraft:silk_touch",
                        "levels": {
                          "min": 1
                        }
                      }
                    ]
                  }
                }
              ],
              "name": "minecraft:iron_ore"
            },
            {
              "type": "minecraft:item",
              "functions": [
                {
                  "function": "minecraft:apply_bonus",
                  "enchantment": "minecraft:fortune",
                  "formula": "minecraft:ore_drops"
                },
                {
                  "function": "minecraft:explosion_decay"
                }
              ],
              "name": "mop:chunk_iron"
            }
          ]
        }
      ]
    }
  ]
}

 

"mop" is my mod ID. There are no errors in any of the JSON files. Is there something else I need to change in this file for it to function properly? Is it the ore_drops formula? It's obviously overriding the vanilla table since they aren't dropping ore, it's just not processing mine correctly. I feel like I am missing something really simple and if I am, I apologize, but I've been fighting with this for hours now and not seeing the problem so I am seeking some help.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.