Fix logic error in bed rotation

Esse commit está contido em:
fluxionary
2023-05-20 03:17:43 -07:00
commit de GitHub
commit 9a9df3a42e

Ver arquivo

@@ -115,8 +115,8 @@ function beds.register_bed(name, def)
local dir = minetest.facedir_to_dir(node.param2) local dir = minetest.facedir_to_dir(node.param2)
local p = vector.add(pos, dir) local p = vector.add(pos, dir)
local node2 = minetest.get_node_or_nil(p) local node2 = minetest.get_node_or_nil(p)
if not node2 or not minetest.get_item_group(node2.name, "bed") == 2 or if not node2 or minetest.get_item_group(node2.name, "bed") ~= 2 or
not node.param2 == node2.param2 then node.param2 ~= node2.param2 then
return false return false
end end
if minetest.is_protected(p, user:get_player_name()) then if minetest.is_protected(p, user:get_player_name()) then