forked from mtcontrib/plantlife_modpack
Add protection check when digging vines (#58)
This commit is contained in:
parent
9e771e2988
commit
6a3c47157f
@ -37,6 +37,9 @@ end
|
|||||||
-- FUNCTIONS
|
-- FUNCTIONS
|
||||||
|
|
||||||
local function on_dig(pos, node, player)
|
local function on_dig(pos, node, player)
|
||||||
|
if not player or minetest.is_protected(pos, player:get_player_name()) then
|
||||||
|
return
|
||||||
|
end
|
||||||
local vine_name_end = node.name:gsub("_middle", "_end")
|
local vine_name_end = node.name:gsub("_middle", "_end")
|
||||||
local drop_item = "vines:vines"
|
local drop_item = "vines:vines"
|
||||||
if enable_vines == false then
|
if enable_vines == false then
|
||||||
|
Loading…
Reference in New Issue
Block a user