forked from mtcontrib/homedecor_modpack
fix deduction of spiral staircase
This commit is contained in:
parent
7266b230aa
commit
804ee36102
@ -887,11 +887,11 @@ homedecor.register("spiral_staircase", {
|
|||||||
})
|
})
|
||||||
|
|
||||||
minetest.register_on_placenode(function(pos, newnode, placer, oldnode, itemstack, pointed_thing)
|
minetest.register_on_placenode(function(pos, newnode, placer, oldnode, itemstack, pointed_thing)
|
||||||
|
|
||||||
local belownode = minetest.get_node({ x = pos.x, y = pos.y - 1, z = pos.z })
|
local belownode = minetest.get_node({ x = pos.x, y = pos.y - 1, z = pos.z })
|
||||||
|
|
||||||
if belownode and belownode.name == "homedecor:spiral_staircase" then
|
if newnode.name ~= "homedecor:spiral_staircase"
|
||||||
|
and belownode
|
||||||
|
and belownode.name == "homedecor:spiral_staircase" then
|
||||||
minetest.set_node(pos, { name = "air" })
|
minetest.set_node(pos, { name = "air" })
|
||||||
|
|
||||||
local newpos = { x = pos.x, y = pos.y + 2, z = pos.z }
|
local newpos = { x = pos.x, y = pos.y + 2, z = pos.z }
|
||||||
|
Loading…
Reference in New Issue
Block a user