Loot Tables Code

Loot Tables Code


[20/10/2015, 17:56:27] Nathan Adams:  /summon MinecartChest  1 ~ {LootTable:chests/simple_dungeon}
^ this summons a minecart chest with the typical dungeon loot, randomly picked when the player first opens it.
/setblock   ~ chest 0 false {LootTable:chests/end_city_treasure,LootTableSeed:12345}
This places a chest with the end city treasure, with deterministic loot picked when the player opens it.
[20/10/2015, 17:56:55] Nathan Adams: So if you set the seed, it'll always pick using that seed. Otherwise, it'll pick randomly.
[20/10/2015, 17:57:14] Nathan Adams: All chests placed at world gen have a seed
[20/10/2015, 17:57:51] Nathan Adams: So the same world opened twice will have the same chests and the same loot inside the chests (unless, of course, something happened to change the loot generation)

The loot tables themselves are files on disc, either world/data/loot_tables/xxxx.json or if that didn't exist, inside the jar. So you can make your own, or overwrite existing ones.


Nathan Adams ‏@Dinnerbone  2h2 hours ago
This is a command to summon a Zombie that drops same items you find in dungeons: /summon Zombie ~ ~ ~ {DeathLootTable:chests/simple_dungeon}

"minecraft:empty" is a loot table that is empty, and leaving off "item" gives you an empty item in a loot table




 saves\43A\data\loot_tables\minecraft\entities\pig.json

No comments:

Post a Comment