Difference between revisions of "Template:Item icon"

From Project: Gorgon Wiki
Jump to: navigation, search
(v415 update)
(Updating to v416)
 
(2 intermediate revisions by one other user not shown)
Line 1: Line 1:
<noinclude><!-- Updated on Fri Oct 25 2024 07:50:40 GMT-0600 (Mountain Daylight Time) using FoxnEagle's auto-wiki-generator -->
+
<noinclude><!-- Updated on Sat Dec 14 2024 04:11:28 GMT-0700 (Mountain Standard Time) using FoxnEagle's auto-wiki-generator -->
 
</noinclude><includeonly>{{ #switch: {{{2}}} | 1 | 32 = <span class="extimage32px">| 2 | 64 = <span class="extimage64px"> | }}{{ #if: {{{1|}}} |  
 
</noinclude><includeonly>{{ #switch: {{{2}}} | 1 | 32 = <span class="extimage32px">| 2 | 64 = <span class="extimage64px"> | }}{{ #if: {{{1|}}} |  
{{ #replace: http://cdn.projectgorgon.com/v415/icons/icon_{{ #switch: {{padleft: | 1 | {{ lc: {{{1}}} }} }}
+
{{ #replace: http://cdn.projectgorgon.com/v416/icons/icon_{{ #switch: {{padleft: | 1 | {{ lc: {{{1}}} }} }}
 
| a = {{ #switch: {{{1}}}
 
| a = {{ #switch: {{{1}}}
 
| Aberration Skull = 5367
 
| Aberration Skull = 5367
Line 13: Line 13:
 
| Acid-Addled Blade = 15009
 
| Acid-Addled Blade = 15009
 
| Acid-Pitted Shield = 14003
 
| Acid-Pitted Shield = 14003
 +
| Acur Blood = 6581
 
| Adequate Staff = 18001
 
| Adequate Staff = 18001
 
| Admin Invisibility Potion = 5089
 
| Admin Invisibility Potion = 5089
Line 1,583: Line 1,584:
 
| Choggo's Calling Card = 4005
 
| Choggo's Calling Card = 4005
 
| Chopping Sword = 15018
 
| Chopping Sword = 15018
 +
| Chrysoberyl = 6622
 
| Chub Fillet = 5034
 
| Chub Fillet = 5034
 
| Chub = 6491
 
| Chub = 6491
Line 2,467: Line 2,469:
 
| Dye Making: Electric Yellow Dye = 4003
 
| Dye Making: Electric Yellow Dye = 4003
 
| Dye Making: Hateful Orchid Dye = 4003
 
| Dye Making: Hateful Orchid Dye = 4003
 +
| Dye Making: Honeydew Dye = 4003
 +
| Dye Making: Light Salmon Dye = 4003
 
| Dye Making: Light Steel Blue Dye = 4003
 
| Dye Making: Light Steel Blue Dye = 4003
 
| Dye Making: Lime Green Dye = 4003
 
| Dye Making: Lime Green Dye = 4003
Line 2,503: Line 2,507:
 
| Elegant Cotton Skirt = 11017
 
| Elegant Cotton Skirt = 11017
 
| Elegant Fletchings = 5226
 
| Elegant Fletchings = 5226
 +
| ElegantBardRobesChest = 12001
 +
| ElegantBardRobesFeet = 10001
 +
| ElegantBardRobesHands = 13001
 +
| ElegantBardRobesHead = 16001
 +
| ElegantBardRobesLegs = 11001
 
| ElegantClothChest = 12001
 
| ElegantClothChest = 12001
 
| ElegantClothFeet = 10001
 
| ElegantClothFeet = 10001
Line 2,668: Line 2,677:
 
| Extra-Sturdy Shirt = 12002
 
| Extra-Sturdy Shirt = 12002
 
| Extraordinary Metal Slab = 6403
 
| Extraordinary Metal Slab = 6403
| Extraplanar Blood = 6581
 
 
| Extreme Acid Resistance Potion = 5154
 
| Extreme Acid Resistance Potion = 5154
 
| Extreme Rivets = 6447
 
| Extreme Rivets = 6447
Line 2,840: Line 2,848:
 
| Fire Magic Textbook (Levels 96-100) = 6399
 
| Fire Magic Textbook (Levels 96-100) = 6399
 
| Fire Magic: Purple Fire Walls = 4003
 
| Fire Magic: Purple Fire Walls = 4003
 +
| Fire Opal = 6623
 
| Fire Orb = 5382
 
| Fire Orb = 5382
 
| Fire Resistance Potion = 5154
 
| Fire Resistance Potion = 5154
Line 3,594: Line 3,603:
 
| Helm of the Summer Court = 16019
 
| Helm of the Summer Court = 16019
 
| Helm of the Winter Court = 16019
 
| Helm of the Winter Court = 16019
 +
| Hematic Opal = 6623
 
| Herbal Soap = 5992
 
| Herbal Soap = 5992
 
| Herbed Salmon Steak = 5132
 
| Herbed Salmon Steak = 5132
Line 4,143: Line 4,153:
 
| Licking Moss = 6416
 
| Licking Moss = 6416
 
| Life or Death Potion = 5157
 
| Life or Death Potion = 5157
 +
| Lifeblood = 6617
 
| Lifepulse Ring = 17002
 
| Lifepulse Ring = 17002
 
| Light Cyan Dye = 6067
 
| Light Cyan Dye = 6067
Line 4,490: Line 4,501:
 
| Misery Trooper Leggings = 11010
 
| Misery Trooper Leggings = 11010
 
| Miss Fly-Hater = 6413
 
| Miss Fly-Hater = 6413
 +
| Missing Hematic Lens = 5753
 
| Mister Whiskers = 17001
 
| Mister Whiskers = 17001
 
| Misty Rose Dye = 6016
 
| Misty Rose Dye = 6016
Line 8,008: Line 8,020:
 
| Winter Salad = 5820
 
| Winter Salad = 5820
 
| Winter Shield = 14006
 
| Winter Shield = 14006
 +
| Winter Snowflake Banner = 6583
 
| WinterOrganicChest = 12001
 
| WinterOrganicChest = 12001
 
| WinterOrganicFeet = 10001
 
| WinterOrganicFeet = 10001
Line 9,371: Line 9,384:
 
}}
 
}}
 
}}.png
 
}}.png
| http://cdn.projectgorgon.com/v415/icons/icon_.png <!-- result when no match is found, will be #replaced -->
+
| http://cdn.projectgorgon.com/v416/icons/icon_.png <!-- result when no match is found, will be #replaced -->
 
| <span style="color:red">Error: Item not found</span> }} | [[File:Item-icon-none.png]] }}{{ #switch: {{{2}}} | 1 | 2 | 32 | 64 = </span> | }}</includeonly><noinclude>
 
| <span style="color:red">Error: Item not found</span> }} | [[File:Item-icon-none.png]] }}{{ #switch: {{{2}}} | 1 | 2 | 32 | 64 = </span> | }}</includeonly><noinclude>
 
{{Documentation}}
 
{{Documentation}}
 
[[Category:Formatting templates|ItemT]]
 
[[Category:Formatting templates|ItemT]]
 
</noinclude>
 
</noinclude>

Latest revision as of 06:14, 14 December 2024


Template documentation (for the above template, sometimes hidden or invisible) [view] [edit] [history] [refresh]

Description

This template accepts an item name as input and returns the in-game icon. This template is used by both Template:Item and Template:Loot. See the Examples section below.

Syntax

{{Item icon|<name>|<size selection>}}

Parameters

<name>
The name of the icon. It must match exactly what is displayed in-game (e.g. "Red Apple", not "Apple" or "red apple")
If omitted or empty, template returns a blank icon image.
If no match is found, template returns an error.
<size selection>
1 or 32 for 32x32.
2 or 64 for 64x64.
If omitted, empty, or anything else, image isn't resized.

Examples

Standard Use

{{Item icon|Glowy Yellow Crystal}}

{{Item icon|Ice Core}}

{{Item icon}}

{{Item icon|FakeItemReturnsError}}

icon_5702.png

icon_5295.png

Item-icon-none.png

Error: Item not found


Resizing

{{Item icon|Glowy Yellow Crystal}} <!-- default size is 64x64 -->

{{Item icon|Ice Core}} <!-- default size is 32x32 -->

{{Item icon|Glowy Yellow Crystal|32}}

{{Item icon|Ice Core|64}}

icon_5702.png

icon_5295.png

icon_5702.png

icon_5295.png


Alternative Resizing (old method)

You can also manually resize the images if you wish (using the template just wraps the image in this span automatically).

<span class="extimage32px">{{Item icon|Salt}}</span>

<span class="extimage64px">{{Item icon|Salt}}</span>

icon_5013.png

icon_5013.png

Notes

Sometimes items appear in-game that share the same displayed name but have different internal names. Often future patches rename one of them to prevent conflicts, but a few persist. This wiki resolves the issue by renaming the less-likely to be searched for item.

One example is and
Error: Item not found
 
. Both are called just "Daisy" in-game, but the Lute has an InternalName (found in the items json) of "Daisy" and the flower has an InternalName of "Flower5".

Icon Codes for Items Sharing a Name

		| Daisy = 5283
		| Daisy (Lute) = 5380

Code Required for other templates

These two lines are required for Template:NPC training row, Template:NPC training unlock row, and Template:Recipe to work properly.

		| scroll = 4003
		| Unlock = 109
The above text is transcluded from Template:Item icon/doc; you can change it or view its history.
If you're done making changes, please refresh the text.
Please add categories and interwikis to Template:Item icon/doc. (View all subpages of this page.)