fix duck webs going everywhere

This commit is contained in:
Tai Kedzierski 2019-01-02 22:54:07 +00:00
parent 317765cbc0
commit b8e90803be
2 changed files with 4 additions and 2 deletions

View File

@ -174,8 +174,9 @@ function explosion_web(pos, webtype)
local k = {x=i,y=j+1,z=k} local k = {x=i,y=j+1,z=k}
local current = minetest.env:get_node(p).name local current = minetest.env:get_node(p).name
local ontop = minetest.env:get_node(k).name local ontop = minetest.env:get_node(k).name
if not nssm.unswappable_node(k) then if current == "air" then
minetest.set_node(k, {name=webtype}) --if not nssm.unswappable_node(p) then -- replaces to many nodes
minetest.set_node(p, {name=webtype})
end end
end end
end end

View File

@ -10,6 +10,7 @@ local no_swap_nodes = {
"ignore", "ignore",
"default:chest_locked", "default:chest_locked",
"nssm:mob_inhibitor", "nssm:mob_inhibitor",
"nssm_server:mob_inhibitor",
} }
nssm.unswappable_node = function (pos, node_list) nssm.unswappable_node = function (pos, node_list)