Difference between revisions of "Template:ArtifactTable/row"

From Stoneshard wiki
Jump to navigation Jump to search
(Test Item, Inv & Price working. Effect & Description still blank. Needs ArtifactDescription to be added + fallback condition.)
m (Add "#tag"s, to keep the formatting accordingly.)
Line 7: Line 7:
     -->{{#vardefine:InvSlots|{{#explode: {{#var:Datastring}}|;|2}}}}<!--
     -->{{#vardefine:InvSlots|{{#explode: {{#var:Datastring}}|;|2}}}}<!--
     -->{{#vardefine:Price|{{#explode: {{#var:Datastring}}|;|3}}}}<!--
     -->{{#vardefine:Price|{{#explode: {{#var:Datastring}}|;|3}}}}<!--
     -->{{vardefine:ItemEffect|{{#explode: {{#var:Datastring}}|;|4}}}}<!--
     -->{{#vardefine:ItemEffect|{{#explode: {{#var:Datastring}}|;|4}}}}<!--
     -->{{#vardefine:ItemDescription|{{#explode: {{#var:Datastring}}|;|5}}}}<!--
     -->{{#vardefine:ItemDescription|{{#explode: {{#var:Datastring}}|;|5}}}}<!--
     --- Load translations that are used multiple times into variables. ---
     --- Load translations that are used multiple times into variables. ---
     -->{{#vardefine:TranslateName|{{Translate|{{{1}}}|ArtifactNames}}}}<!--
     -->{{#vardefine:TranslateName|{{Translate|{{{1}}}|ArtifactNames}}}}<!--
    -->{{#vardefine:TranslateEffect|{{Translate|{{#var:ItemEffect}}|ArtifactDescriptions}}}}<!--
    -->{{#vardefine:TranslateDescription|{{Translate|{{#var:ItemDescription}}|ArtifactDescriptions}}}}<!--
     --- Define "Link" var, with a subpage verification. If subpagename = pagename, we are not on a subpage, therefore URL becomes "item name". If we are on a subpage, URL becomes "item name/subgpagename". Used for other languages. ---
     --- Define "Link" var, with a subpage verification. If subpagename = pagename, we are not on a subpage, therefore URL becomes "item name". If we are on a subpage, URL becomes "item name/subgpagename". Used for other languages. ---
     -->{{#vardefine:Link|{{#ifeq:{{SUBPAGENAME}}|{{PAGENAME}}|{{{1}}}|{{{1}}}/{{SUBPAGENAME}}}}}}
     -->{{#vardefine:Link|{{#ifeq:{{SUBPAGENAME}}|{{PAGENAME}}|{{{1}}}|{{{1}}}/{{SUBPAGENAME}}}}}}
Line 21: Line 23:
     | {{slots|{{#explode: {{#var:InvSlots}}|x|0}}|{{#explode: {{#var:InvSlots}}|x|1}}}}
     | {{slots|{{#explode: {{#var:InvSlots}}|x|0}}|{{#explode: {{#var:InvSlots}}|x|1}}}}
     | {{#var:Price}} [[File:Gold.png|27x27px]]
     | {{#var:Price}} [[File:Gold.png|27x27px]]
     | {{#if:{{Translate|{{#var:ItemEffect}}|ArtifactDescriptions}}}}
     | {{#if:{{#var:TranslateEffect}}|{{#tag:span|{{#var:TranslateEffect}}|style="white-space: pre-wrap;"}}|{{#tag:span|{{#var:ItemEffect}}|style="white-space: pre-wrap;"}}}}
     | {{#if:{{Translate|{{#var:ItemDescription}}|ArtifactDescriptions}}}}<!--
     | {{#if:{{#var:TranslateDescription}}|{{#tag:span|{{#var:TranslateDescription}}|style="white-space: pre-wrap;"}}|{{#tag:span|{{#var:ItemDescription}}|style="white-space: pre-wrap;"}}}}<!--
--></includeonly>
--></includeonly>
<noinclude>{{doc}}[[Category:Templates]]</noinclude>
<noinclude>{{doc}}[[Category:Templates]]</noinclude>

Revision as of 01:23, 23 January 2025

Template-info.png Documentation

This article is a stub. You can help Stoneshard wiki by expanding it.

This Template replicates the logic used for the Template:ValuableTable/row.

Syntax

{{ArtifactTable/row|Blessed Aquamanile}}

Usage

It should be used with a 'header', right before it.
{{ArtifactTable/head}}
{{ArtifactTable/row|Blessed Aquamanile}}.

Any Artifacts added in Artifact Data, can be used with the '/row' template.

Examples

Item Inv. Slots Price Gold Icon Effect Description
Blessed Aquamanile
Blessed Aquamanile
2×2 600 Gold.png


Barbador the Lame's Atlas of Aldor
Barbador the Lame's Atlas of Aldor
3×2 600 Gold.png