mirror of
https://git.minetest.land/VoxeLibre/VoxeLibre.git
synced 2024-11-19 01:21:05 +01:00
Merge pull request 'Fix villager crash when opening iron doors' (#2440) from fix_mobs_doors_rightclick into master
Reviewed-on: https://git.minetest.land/MineClone2/MineClone2/pulls/2440 Tested by @kwadroke in https://git.minetest.land/MineClone2/MineClone2/issues/2439#issuecomment-42202
This commit is contained in:
commit
8f875395ea
1 changed files with 2 additions and 2 deletions
|
@ -2312,9 +2312,9 @@ local function check_doors(self)
|
|||
local def = minetest.registered_nodes[n.name]
|
||||
local closed = n.name:find("_b_1")
|
||||
if t < 0.3 or t > 0.8 then
|
||||
if not closed then def.on_rightclick(d,n,self) end
|
||||
if not closed and def.on_rightclick then def.on_rightclick(d,n,self) end
|
||||
else
|
||||
if closed then def.on_rightclick(d,n,self) end
|
||||
if closed and def.on_rightclick then def.on_rightclick(d,n,self) end
|
||||
end
|
||||
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue