Try to fix crash

This commit is contained in:
Novatux 2015-06-23 19:16:22 +02:00
parent dada8474fe
commit 528b21da7f

View File

@ -251,6 +251,10 @@ end
-- end -- end
function luaentity.add_entity(pos, name) function luaentity.add_entity(pos, name)
if not luaentity.entities then
minetest.after(0, luaentity.add_entity, vector.new(pos), name)
return
end
local index = luaentity.entities_index local index = luaentity.entities_index
while luaentity.entities[index] do while luaentity.entities[index] do
index = index + 1 index = index + 1