AtomicStryker / atomicstrykers-minecraft-mods

Repository for my open source Minecraft Mods
https://atomicstryker.github.io/
180 stars 96 forks source link

Loot tables in Ruins #490

Closed Nykrdaudr closed 9 months ago

Nykrdaudr commented 9 months ago

Hi, im playing on 1.12.2 using "modern_ruins". as far as i have understood, it just means that hes changed some of your structures to accommodate for Chisel, so i figured it would be better to ask you directly. i have been looking at ways to implement variable loot into the structures and saw there was a way to implement the vanilla loot tables. is there a way to implement modded loot tables?

AtomicStryker commented 9 months ago

If the modded loot tables have resource URL, you can use them directly. You can also define modded items, but that is tedious.

Nykrdaudr commented 9 months ago

resource url? as in file path (sevendaystomine-1.12.2-1.0.2.10\assets\sevendaystomine\loot_tables\airdrop.json) or something else more complicated?

Nykrdaudr commented 9 months ago

the specific thing i want right now, is to make this: rule11=0,100,IInventory;sevendaystomine:bookshelf;minecraft:book#1#0#1+minecraft:book#1#0#2+minecraft:book#1#0#3+minecraft:book#1#0#4+minecraft:book#1#0#7+minecraft:book#1#0#8-0

refer to 7dtm's loot table for "bookshelf_common" sevendaystomine-1.12.2-1.0.2.10\assets\sevendaystomine\loot_tables\bookshelf_common bookshelf_common.json

AtomicStryker commented 9 months ago

I googled his github, his source is public, and found the thing you refer to: https://github.com/Nuparu00/7-Days-to-Mine-Mod/blob/1.20.1/src/main/java/nuparu/sevendaystomine/world/level/levelgen/processor/BookshelfProcessor.java#L15

The correct resource URL are sevendaystomine:containers/bookshelf/bookshelf_common sevendaystomine:containers/bookshelf/bookshelf_rare

Nykrdaudr commented 9 months ago

thank you for your help :)

AtomicStryker commented 9 months ago

Note thats 1.20.1, there is a small chance the ID was different in 1.12.2, he has a branch for that, if those dont work you can check it out and do some searching

AtomicStryker commented 9 months ago

Given the matching folder structure, and the files here in 1.12: https://github.com/Nuparu00/7-Days-to-Mine-Mod/tree/1.12.2/Forge%201.12.2/src/main/resources/assets/sevendaystomine/loot_tables

i would expect the URL to be sevendaystomine:bookshelf_common sevendaystomine:bookshelf_rare