Ouput quarry print position when it hits a protected area & fix leaves->biogas recipe (by Fedja Beader <fedja@protonmail.ch>)

This commit is contained in:
Joachim Stolberg 2020-12-09 21:36:34 +01:00
parent 5acdaf871c
commit a8ed9dd552
2 changed files with 8 additions and 2 deletions

@ -342,8 +342,13 @@ if minetest.global_exists("unified_inventory") then
width = 2, width = 2,
height = 2, height = 2,
}) })
local leaves_table = {}
for i = 1, NUM_LEAVES do
table.insert(leaves_table, "group:leaves")
end
unified_inventory.register_craft({ unified_inventory.register_craft({
items = {"group:leaves", "group:leaves"}, items = leaves_table,
output = "tubelib_addons1:biogas", output = "tubelib_addons1:biogas",
type = "fermenting" type = "fermenting"
}) })

@ -215,7 +215,8 @@ local function quarry_next_node(pos, meta)
meta:set_string("quarry_pos", P2S(quarry_pos)) meta:set_string("quarry_pos", P2S(quarry_pos))
if minetest.is_protected(quarry_pos, owner) then if minetest.is_protected(quarry_pos, owner) then
minetest.chat_send_player(owner, S("[Tubelib Quarry] Area is protected!")) minetest.chat_send_player(owner, S("[Tubelib Quarry] Area is protected!") ..
" " .. minetest.pos_to_string(quarry_pos) )
State:fault(pos, meta) State:fault(pos, meta)
return return
end end