Template:UpgradeIcon: Difference between revisions

From Melvor Idle
(Added link override.)
(Now uses generic Icon template as a base.)
Line 4: Line 4:




<onlyinclude>{{#if:{{{2|}}}|[[File:{{{1}}} (upgrade).svg|25px|link={{{1}}}]]&nbsp;[[{{{1}}}|{{{2}}}]]|[[File:{{{1}}} (upgrade).svg|25px|link={{{1}}}]]&nbsp;[[{{{1}}}]]}}</onlyinclude>
<includeonly><onlyinclude>{{Icon|type=upgrade|{{{1}}}|{{{2|}}}|ext={{{ext|svg}}}}}</onlyinclude></includeonly>

Revision as of 19:38, 24 August 2020

A template for quickly building upgrade links with icons. For example, {{UpgradeIcon|Dragon Pickaxe}} becomes Dragon Pickaxe

Also allows for overriding the link text with a second argument. For example, {{UpgradeIcon|Dragon Axe|The Best Axe}} becomes The Best Axe