midas ability only works on "normal" type nodes
This commit is contained in:
parent
5596d2110b
commit
a5b7cf4db3
10
nssm_api.lua
10
nssm_api.lua
@ -380,11 +380,13 @@ function nssm:midas_ability( --ability to transform every blocks it touches in
|
||||
|
||||
local p = {x = pos.x + dx, y = pos.y + dy, z = pos.z + dz}
|
||||
local n = minetest.get_node(p).name
|
||||
local d = minetest.registered_nodes[n]
|
||||
|
||||
if minetest.get_item_group(n, "unbreakable") == 1
|
||||
or minetest.is_protected(p, "") or n == "air"
|
||||
or (n == "bones:bones" and not nssm:affectbones(self))
|
||||
or n == m_block then
|
||||
if d.drawtype ~= "normal" or n == m_block
|
||||
or minetest.get_item_group(n, "unbreakable") == 1
|
||||
or minetest.is_protected(p, "")
|
||||
or (n == "bones:bones" and not nssm:affectbones(self)) then
|
||||
-- do nothing
|
||||
else
|
||||
minetest.set_node(p, {name = m_block})
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user