How to add into an existing loot table?

Started by Ali107 on Thu, 07/07/2022 - 14:30

Topic category: Help with modding (Java Edition)

Last seen on 00:20, 9. Aug 2022
Joined Jul 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
How to add into an existing loot table?
Thu, 07/07/2022 - 14:30

How do I add extra items that are rare into an existing vanilla loot table without removing all the other items?

Last seen on 19:19, 9. Aug 2022
Joined Mar 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Find the original loot table…
Thu, 07/07/2022 - 22:54

Find the original loot table json file in: <your minecraft version>.jar \ data \ minecraft \ loot_tables \ XXX \  XXX.json

Open this file with a text editor and copy the contents.

Make a new loot table in mcreator.

Set the namespace to minecraft and the type to the appropriate type.

Set the Loot table registry name to match the original file.

Save, then open with the code editor.

Paste in the original loot table data over whatever is in the new file.

Save and Lock. 

 

You can now code edit this copy of the original loot table and insert your new item manually.

Last seen on 00:20, 9. Aug 2022
Joined Jul 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Thanks for the help!  But…
Fri, 07/08/2022 - 14:24

Thanks for the help! 

But won't this make it not compatible with other mods if they try to add stuff in the same loot table?

Last seen on 19:19, 9. Aug 2022
Joined Mar 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
It's the nature of the beast…
Fri, 07/08/2022 - 21:04

It's the nature of the beast, the game will use whichever loot table is loaded last.