Add some wieldview bug fixes from Carbone game by Calinou

This commit is contained in:
stujones11 2015-02-19 22:01:09 +00:00
parent 195d138da5
commit d95f494a94

@ -21,11 +21,12 @@ wieldview.get_item_texture = function(self, item)
local texture = "3d_armor_trans.png"
if item ~= "" then
if minetest.registered_items[item] then
local inventory_image = minetest.registered_items[item].inventory_image
if inventory_image and inventory_image ~= "" then
texture = inventory_image
elseif node_tiles == true and minetest.registered_items[item].tiles then
texture = minetest.registered_items[item].tiles[1]
if minetest.registered_items[item].inventory_image ~= "" then
texture = minetest.registered_items[item].inventory_image
elseif node_tiles == true and minetest.registered_items[item].tiles
and type(minetest.registered_items[item].tiles[1]) == "string"
and minetest.registered_items[item].tiles[1] ~= "" then
texture = minetest.inventorycube(minetest.registered_items[item].tiles[1])
end
end
if wieldview.transform[item] then