From dc72f1d10ed9a593951fac9fcd12c8b013a9edb3 Mon Sep 17 00:00:00 2001 From: ANAND Date: Fri, 24 Apr 2020 22:53:14 +0530 Subject: [PATCH] Fix another default/item_entity.lua crash --- mods/mtg/default/item_entity.lua | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/mods/mtg/default/item_entity.lua b/mods/mtg/default/item_entity.lua index b5f9ef9..c1e030a 100644 --- a/mods/mtg/default/item_entity.lua +++ b/mods/mtg/default/item_entity.lua @@ -48,7 +48,12 @@ local item = { if self.ignite_timer > 10 then self.ignite_timer = 0 - local node = minetest.get_node_or_nil(self.object:get_pos()) + local pos = self.object:get_pos() + if not pos then + return + end + + local node = minetest.get_node_or_nil(pos) if not node then return end