Dungeon loot chests

Download (5 KB)
For Luanti 5.6 and above

How do I install this?

Description

Dungeon loot chests 🔗

Adds:
A chests, furnaces, bookshelf, vessel with loot, a command to prevent spawning loot in the chests, furnaces, etc so you can save a schematic with a loot chest:
/loot enable
/loot disable

Function to create a new loot item list:
register_loot("name", [[
{
{name = "default:dirt", chance = 0.6, count = {2, 16}, y = {-64, 32768}, types = {"normal", "sandstone", "desert"}},
{name = "default:book", chance = 0.7},
}]])

Functions to create chests, furnaces, bookshelf, vessel with diferent loot (dungeontype is optional):
add_loot_chest("name", "description", "mod:chest", item_list, "dungeontype")
add_loot_bookshelf("name", "description", "mod:chest", item_list, "dungeontype")
add_loot_vessel("name", "description", "mod:chest", item_list, "dungeontype")
add_loot_furnace("name", "description", "mod:chest", item_list_fuel, item_list_dst, item_list_src, "dungeontype")
If you have the mod x_enchanting
add_loot_enchanting_table("name", "description", "mod:chest", item_list, "dungeontype")
add_loot_grindstone("name", "description", "mod:chest", item_list_item, item_list_trade, "dungeontype")
If you have the mod s_brewing
add_loot_brewing_stand("name", "description", "mod:chest", item_list_dst, item_list_vial, item_list_src, "dungeontype")

You can add a new item to a item list with this function:
name.register({name = "default:dirt", chance = 0.6, count = {2, 16}, y = {-64, 32768}, types = {"normal", "sandstone", "desert"}})

If you want to create a new dungeon type only in types = {" "} write the new dungeontype

If you don't put count, the item in the loot will always be 1, if you don't put y, it will appear on any coordinate, if you don't put types, it will appear in all loot chests

This are all the item lists alredy created bookshelf_loot, vessel_loot, furnace_fuel_loot, furnace_dst_loot, furnace_src_loot and dungeon_loot for chests it has "normal", "sandstone", "desert", "ice" dungeontypes.

If you have the mod s_brewing: brewing_stand_dst_loot, brewing_stand_vial_loot, brewing_stand_src_loot

If you have the mod x_enchanting: enchanting_table_item_loot, enchanting_table_trade_loot, grindstone_loot

Dungeon loot chests was created with code from dungeon_loot by sfan5

Installation 🔗

ContentDB 🔗

  • Content > Browse Online Content
  • Search for "Dungeon loot chests"
  • Click Install

Manually 🔗

  • Unzip the archive, rename the folder to dungeon_loot_chests and place it in .../minetest/mods/

  • GNU/Linux: If you use a system-wide installation place it in ~/.minetest/mods/.

The Luanti engine can be found at GitHub.

For further information or help, see: Installing Mods.

License 🔗

See LICENSE.txt

Reviews

Review

Do you recommend this mod?

  • English

    Help

    Can you help me, i tried to disable loot generation with /loot disable and /grantme server. So everytime i try to put a loot chest it transforms into a default chest, i can't do a dungeon schematic for a mod i'm working on.

    What should i do ?

    3 comments

Releases

2025-06-08

Download

Luanti 5.6+

2025-06-08 14:41 UTC

2025-06-08 🔗

  • Replace s_potions with potions in init.lua
  • Replace s_brewing with potions_brewing in mod.conf
  • global function populate in init.lua
  • Fix chatcommand in init.lua

2025-05-07

Download

Luanti 5.6+

2025-05-07 02:10 UTC

2025-05-07 🔗

  • Update README.md
  • Update README.md
  • Update init.lua
  • Update mod.conf

2025-04-30

Download

Luanti 5.6+

2025-04-30 02:10 UTC

2025-04-30 🔗

  • Add optional item list, register item list, support for x_enchanting, s_brewing, furnace, bookshelf, vessels in init.lua

2025-03-19

Download

Luanti 5.6+

2025-03-19 02:10 UTC

2025-03-19 🔗

  • Remove params = "<enable/disable>", in init.lua

2025-03-06

Download

Luanti 5.6+

2025-03-06 16:57 UTC

2025-03-06 🔗

  • Add min and max version in mod.conf
  • Remove author in mod.conf
  • Remove max version in mod.conf
All releases