mirror of
https://github.com/minetest-mods/3d_armor.git
synced 2024-11-26 06:13:45 +01:00
Fix nil value tiles exception, second attempt.
This commit is contained in:
parent
72812db4d3
commit
8f7bad9690
@ -29,9 +29,10 @@ armor_api.get_wielded_item_texture = function(self, player)
|
||||
end
|
||||
local texture = minetest.registered_items[item].inventory_image
|
||||
if texture == "" then
|
||||
if minetest.registered_items[item].tiles[1] then
|
||||
texture = minetest.registered_items[item].tiles[1]
|
||||
if not minetest.registered_items[item].tiles then
|
||||
return nil
|
||||
end
|
||||
texture = minetest.registered_items[item].tiles[1]
|
||||
end
|
||||
return texture
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user