lucky_block.lua 555 B

1234567891011121314151617181920212223242526272829
  1. -- add lucky blocks
  2. local function growy(pos, player)
  3. local dpos = minetest.find_node_near(pos, 1, "group:soil")
  4. if dpos then
  5. bonemeal:on_use(dpos, 5)
  6. end
  7. end
  8. if minetest.get_modpath("lucky_block") then
  9. lucky_block:add_blocks({
  10. {"lig"},
  11. {"dro", {"bonemeal:mulch"}, 10},
  12. {"dro", {"bonemeal:bonemeal"}, 10},
  13. {"dro", {"bonemeal:fertiliser"}, 10},
  14. {"cus", growy},
  15. {"nod", "default:chest", 0, {
  16. {name = "bonemeal:mulch", max = 20},
  17. {name = "bonemeal:bonemeal", max = 15},
  18. {name = "bonemeal:fertiliser", max = 10}
  19. }}
  20. })
  21. end