User:Llamageddon/RrtyIcon: Difference between revisions

From Baldur's Gate 3 Wiki
Jump to navigation Jump to search
mNo edit summary
mNo edit summary
Line 2: Line 2:
{{#lvardef: exlk | {{{1 |}}} }}
{{#lvardef: exlk | {{{1 |}}} }}
{{#lvardef: rrty | {{{2 |}}} }}
{{#lvardef: rrty | {{{2 |}}} }}
}}<span style="box-shadow: rgba(0, 0, 0, 0.14) 3px 3px 6px 0px inset, rgba(0, 0, 0, 0.14) -3px -3px 6px 1px inset; background: #1B1A19; padding: 4px 0px 6px 0px; max-width: 25px; border: 2px solid {{#switch: {{#lvar:rrty}} | common = #1B1A1999 | uncommon = #00491599 | rare = #00374999 | veryrare = #54003299 | legendary = #563E0D99 | story = #561D0099 | #1B1A1999 }};">{{ItemIcon|name={{#lvar:exlk}}|size=25}}</span>&nbsp;</includeonly><noinclude>
{{#lvardef: bord | <span style="box-shadow: rgba(0, 0, 0, 0.14) 3px 3px 6px 0px inset, rgba(0, 0, 0, 0.14) -3px -3px 6px 1px inset; background: #1B1A19; padding: 4px 0px 6px 0px; max-width: 25px; border: 2px solid {{#switch: {{#lvar:rrty}} | common = #1B1A1999 | uncommon = #00491599 | rare = #00374999 | veryrare = #54003299 | legendary = #563E0D99 | story = #561D0099 | #1B1A1999 }};"> }}
}}{{#lvar:bord}}{{ItemIcon|name={{#lvar:exlk}}|size=25}}</span>&nbsp;</includeonly><noinclude>
This template uses the [[Template:ItemIcon|{{ItemIcon}}]] template to give the icon for the item defined in the first parameter a coloured border, based on rarity. The rarity is defined by the second paramater: {{C|{{Color|#1B1A1999|common}}}}, {{C|{{Color|#00491599|uncommon}}}}, {{C|{{Color|#00374999|rare}}}}, {{C|{{Color|#54003299|veryrare}}}}, {{C|{{Color|#563E0D99|legendary}}}},  or {{C|{{Color|#561D0099|story}}}}. If left blank, it will default to dark grey (common) for the border.
 
== Examples ==
== Examples ==
<nowiki>{{User:Llamageddon/RrtyIcon|Potion of Healing|rare}}</nowiki>
<nowiki>{{User:Llamageddon/RrtyIcon|Potion of Healing|rare}}</nowiki>

Revision as of 19:12, 6 September 2023

This template uses the [[Template:ItemIcon|[[File:{{{name}}} Unfaded Icon.png|link={{{name}}}|x40px|alt=|class=bg3wiki-icon ]]]] template to give the icon for the item defined in the first parameter a coloured border, based on rarity. The rarity is defined by the second paramater: common, uncommon, rare, veryrare, legendary, or story. If left blank, it will default to dark grey (common) for the border.

Examples

{{User:Llamageddon/RrtyIcon|Potion of Healing|rare}}

 

{{User:Llamageddon/RrtyIcon|Mace|common}}

 

{{User:Llamageddon/RrtyIcon|Longsword|uncommon}}

 

{{User:Llamageddon/RrtyIcon|Club|rare}}

 

{{User:Llamageddon/RrtyIcon|Longbow|veryrare}}

 

{{User:Llamageddon/RrtyIcon|Warhammer|legendary}}

 

{{User:Llamageddon/RrtyIcon|Stuffed Bear A|story}}

 

{{User:Llamageddon/RrtyIcon|Ball}}

 

List Layout