1
0
mirror of https://github.com/minetest-mods/3d_armor.git synced 2024-12-27 03:00:40 +01:00

Fix nil fields exception for unknown items.

This commit is contained in:
stujones11 2013-03-04 21:15:25 +00:00
parent 8f7bad9690
commit b9a6655858

View File

@ -27,6 +27,9 @@ armor_api.get_wielded_item_texture = function(self, player)
if not item then
return nil
end
if not minetest.registered_items[item] then
return nil
end
local texture = minetest.registered_items[item].inventory_image
if texture == "" then
if not minetest.registered_items[item].tiles then