Module:Inventory slot: Difference between revisions
No edit summary |
Reverted my changes on this for now Tag: Manual revert |
||
| (16 intermediate revisions by the same user not shown) | |||
| Line 114: | Line 114: | ||
local img = frame.img | local img = frame.img | ||
if not img then | if not img then | ||
if minecraft then | if name:match( '%.gif$' ) or name:match( '%.png$' ) then | ||
img = name | |||
-- Remove file extension from name | |||
name = name:sub( 0, -5 ) | |||
elseif minecraft then | |||
img = 'Invicon ' .. name .. '.png' | img = 'Invicon ' .. name .. '.png' | ||
elseif mod then | elseif mod then | ||