Difference between revisions of "Template:ItemText"

From Animal Crossing: Pocket Camp Wiki
Jump to: navigation, search
m
(Optimize?)
Line 3: Line 3:
 
| Leaf Ticket = {{#vardefine:image|Leaf_Ticket}}
 
| Leaf Ticket = {{#vardefine:image|Leaf_Ticket}}
 
| Caps = {{#vardefine:image|Caps}}
 
| Caps = {{#vardefine:image|Caps}}
| #default = {{#ifeq: {{#cargo_query:tables=Entities|where=_pageName="{{{1|}}}"|default=No}} | No
+
| #default = {{#vardefine:image|{{#cargo_query:tables=Entities|fields=Image|where=_pageName="{{{1|}}}"|default=Error-image|no html}}}}
| {{#ifeq: {{#cargo_query:tables=CraftMaterials|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=Snacks|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=Maps|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=Tools|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=Seeds|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=FortuneCookies|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=Cargo|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=CampsiteTerrain|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#ifeq: {{#cargo_query:tables=Gift|where=_pageName="{{{1|}}}"|default=No}} | No
 
| {{#vardefine:image|Error-image}}
 
| {{#vardefine:image|{{#cargo_query:tables=Gift|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=CampsiteTerrain|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=Cargo|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=FortuneCookies|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=Seeds|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=Tools|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=Maps|fields=IconImage|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=Snacks|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=CraftMaterials|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
| {{#vardefine:image|{{#cargo_query:tables=Entities|fields=Image|where=_pageName="{{{1|}}}"|no html}}}}}}
 
 
}}[[File:{{#var:image}}.png|{{{size|24px}}}|link={{{1|}}}]] {{#if:{{{link|}}} | [[{{{1|}}}]] | {{{1|}}} }}</includeonly><noinclude>{{doc}}[[Category:Templates]]</noinclude>
 
}}[[File:{{#var:image}}.png|{{{size|24px}}}|link={{{1|}}}]] {{#if:{{{link|}}} | [[{{{1|}}}]] | {{{1|}}} }}</includeonly><noinclude>{{doc}}[[Category:Templates]]</noinclude>

Revision as of 11:58, 24 January 2021

Template-info.png Documentation

Description

Template to be used to display item icon and text.

Usage

{{ItemText|ITEM|size=SIZE|link=}}

Example

{{ItemText|Request Ticket}}

Request Ticket.png Request Ticket

{{ItemText|Shark|size=50px}}

Fish fst0203.png Shark

{{ItemText|Stardust Gift+|size=32px|link=yes}}

Friendgift reg fc002.png Stardust Gift+

{{ItemText|OK Motors Acorn Tree|link=y}}

Int tre15 photospot cmps.png OK Motors Acorn Tree