mirror of
https://github.com/minetest-mods/digtron.git
synced 2025-01-05 10:17:28 +01:00
prevent digging of immortal nodes
This commit is contained in:
parent
5985788181
commit
d4a03478e2
4
util.lua
4
util.lua
@ -45,7 +45,9 @@ digtron.mark_diggable = function(pos, nodes_dug, player)
|
|||||||
local target = minetest.get_node(pos)
|
local target = minetest.get_node(pos)
|
||||||
|
|
||||||
-- prevent digtrons from being marked for digging.
|
-- prevent digtrons from being marked for digging.
|
||||||
if minetest.get_item_group(target.name, "digtron") ~= 0 or minetest.get_item_group(target.name, "digtron_protected") ~= 0 then
|
if minetest.get_item_group(target.name, "digtron") ~= 0 or
|
||||||
|
minetest.get_item_group(target.name, "digtron_protected") ~= 0 or
|
||||||
|
minetest.get_item_group(target.name, "immortal") ~= 0 then
|
||||||
return 0
|
return 0
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user