Module:SpriteFile: Difference between revisions

Jump to navigation Jump to search
no edit summary
(Undo revision 7685 by Diamondback88 (talk))
Tag: Undo
No edit summary
Line 45: Line 45:
elseif link ~= '' then
elseif link ~= '' then
local linkPrefix = ( not link:find( '//' ) and args.linkprefix ) or ''
local linkPrefix = ( not link:find( '//' ) and args.linkprefix ) or ''
if linkprefix == '' then  -- <- these are the added bits here
if linkprefix == 'parallel:' then  -- <- these are the added bits here
linkprefix = 'vanilla:'   
linkprefix = ''   
elseif linkprefix == 'parallel:' then
linkprefix = ''
end
end
link = linkPrefix .. link
link = linkPrefix .. link
Line 111: Line 109:
spriteText = '[[' .. mw.ustring.gsub( link, "parallel:", "" ) .. '|' .. mw.ustring.gsub( tostring(spriteText), "parallel:", "" ) .. ']]'  
spriteText = '[[' .. mw.ustring.gsub( link, "parallel:", "" ) .. '|' .. mw.ustring.gsub( tostring(spriteText), "parallel:", "" ) .. ']]'  
else
else
spriteText = '[[' .. 'Vanilla:' .. link .. '|' .. tostring( spriteText ) .. ']]'
spriteText = '[[' .. link .. ' (Vanilla)' .. '|' .. tostring( spriteText ) .. ']]'
end
end
end
end

Navigation menu