mirror of
https://codeberg.org/tenplus1/mobs_redo.git
synced 2024-12-24 09:40:21 +01:00
fix nil check
This commit is contained in:
parent
975175e7b8
commit
e4ca52fafb
5
api.lua
5
api.lua
@ -6,7 +6,7 @@ local use_cmi = minetest.global_exists("cmi")
|
||||
|
||||
mobs = {
|
||||
mod = "redo",
|
||||
version = "20190513",
|
||||
version = "20190520",
|
||||
intllib = S,
|
||||
invis = minetest.global_exists("invisibility") and invisibility or {},
|
||||
}
|
||||
@ -463,7 +463,8 @@ local ray_line_of_sight = function(self, pos1, pos2)
|
||||
|
||||
local name = minetest.get_node(thing.under).name
|
||||
|
||||
if minetest.registered_items[name].walkable then return false end
|
||||
if minetest.registered_items[name]
|
||||
and minetest.registered_items[name].walkable then return false end
|
||||
end
|
||||
|
||||
thing = ray:next()
|
||||
|
Loading…
Reference in New Issue
Block a user