Fix crash when digging locked chests
This commit is contained in:
parent
46b914e842
commit
5cdcd61a36
@ -847,7 +847,7 @@ minetest.register_node("default:chest_locked", {
|
|||||||
end,
|
end,
|
||||||
can_dig = function(pos,player)
|
can_dig = function(pos,player)
|
||||||
local meta = minetest.get_meta(pos);
|
local meta = minetest.get_meta(pos);
|
||||||
--local inv = meta:get_inventory()
|
local inv = meta:get_inventory()
|
||||||
if has_locked_chest_privilege(meta, player) then
|
if has_locked_chest_privilege(meta, player) then
|
||||||
if inv:is_empty("main") == false then
|
if inv:is_empty("main") == false then
|
||||||
default.dump_inv(pos,"main")
|
default.dump_inv(pos,"main")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user