From 6a3c47157f44e9f6695b8780d70be99d53e3d1d7 Mon Sep 17 00:00:00 2001 From: Niklp <89982526+Niklp09@users.noreply.github.com> Date: Wed, 30 Aug 2023 23:30:10 +0200 Subject: [PATCH] Add protection check when digging vines (#58) --- vines/init.lua | 3 +++ 1 file changed, 3 insertions(+) diff --git a/vines/init.lua b/vines/init.lua index 1f4f0b4..2a52632 100644 --- a/vines/init.lua +++ b/vines/init.lua @@ -37,6 +37,9 @@ end -- FUNCTIONS 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 drop_item = "vines:vines" if enable_vines == false then