Actions

Template

Difference between revisions of "Item"

From P6 Spheres

 
Line 1: Line 1:
 
<noinclude>
 
<noinclude>
 
This is the "Item" template.
 
This is the "Item" template.
 +
 +
'''Name'''=Real name of item<br>
 +
'''SortName'''=Name for use when sorting; "Climbing Kit, Basic" and "Climbing Kit, Deluxe"<br>
 +
'''ItemType'''=The major category of item: Weapons, Dungeoneering, Alchemy, etc<br>
 +
'''ItemSubType'''=The subcategory of item: Alchemical Weapons, Alchemical Boosters, Alchemical Tools<br>
 +
'''TreasureUse'''=Weapon, Protection, Magical, Consumable, Gear<br>
 +
'''Tags'''=Any further tags used for filtering<br>
 +
'''Price'''=Buying price in gp (Float)<br>
 +
'''Weight'''=Weight of the item in lbs. (Float)<br>
 +
'''Short'''=Short summary of benefits/use for tables<br>
 +
'''Fluff'''=Fluff description<br>
 +
'''Description'''=Full description<br>
 +
'''CraftRequirements'''=Workshop, feats, materials, talents<br>
 +
'''CraftDC'''=The Craft DC for the item (Integer)<br>
 +
'''CraftSkill'''=The Craft skill used for the item or Spellcraft<br>
 +
'''CraftCost'''=Cost in sp/gp (Float)<br>
 +
'''Source'''=OGL Codes<br>
 +
'''Campaigns'''=Filtering. "All" by default
 +
 
It should be called in the following format:
 
It should be called in the following format:
 
<pre>
 
<pre>
Line 6: Line 25:
 
|Name=
 
|Name=
 
|SortName=
 
|SortName=
|Category=
+
|ItemType=
|Subcategory=
+
|ItemSubType=
 
|TreasureUse=
 
|TreasureUse=
 
|Tags=
 
|Tags=
Line 15: Line 34:
 
|Fluff=
 
|Fluff=
 
|Description=
 
|Description=
 +
|CraftRequirements=
 +
|CraftDC=
 +
|CraftSkill=
 +
|CraftCost=
 
|Source=
 
|Source=
 
|Campaigns=
 
|Campaigns=
Line 20: Line 43:
 
</pre>
 
</pre>
 
Edit the page to see the template text.
 
Edit the page to see the template text.
{{#cargo_declare:_table=Base_Items|Name=Text|SortName=Text|Category=List (,) of String|Subcategory=List (,) of String|TreasureUse=String (allowed values=Weapon,Protection,Magical,Consumable,Gear)|Tags=List (,) of String|Price=Float|Weight=Float|Short=Wikitext|Fluff=Wikitext|Description=Wikitext|Source=List (,) of String|Campaigns=List (,) of String}}
+
{{#cargo_declare:_table=Base_Items|Name=Text|SortName=Text|ItemType=List (,) of String|ItemSubType=List (,) of String|TreasureUse=String (allowed values=Weapon,Protection,Magical,Consumable,Gear)|Tags=List (,) of String|Price=Float|Weight=Float|Short=Wikitext|Fluff=Wikitext|Description=Wikitext|CraftRequirements=Wikitext|CraftDC=Integer|CraftSkill=String|CraftCost=Float|Source=List (,) of String|Campaigns=List (,) of String}}
</noinclude><includeonly>{{#cargo_store:_table=Base_Items|Name={{{Name|}}}|SortName={{{SortName|}}}|Category={{{Category|}}}|Subcategory={{{Subcategory|}}}|TreasureUse={{{TreasureUse|}}}|Tags={{{Tags|}}}|Price={{{Price|}}}|Weight={{{Weight|}}}|Short={{{Short|}}}|Fluff={{{Fluff|}}}|Description={{{Description|}}}|Source={{{Source|}}}|Campaigns={{{Campaigns|}}} }}{| class="wikitable"
+
</noinclude><includeonly>{{#cargo_store:_table=Base_Items|Name={{{Name}}}|SortName={{{SortName|}}}|ItemType={{{ItemType|}}}|ItemSubType={{{ItemSubType|}}}|TreasureUse={{{TreasureUse|}}}|Tags={{{Tags|}}}|Price={{{Price|}}}|Weight={{{Weight|}}}|Short={{{Short|}}}|Fluff={{{Fluff|}}}|Description={{{Description|}}}|CraftRequirements={{{CraftRequirements|}}}|CraftDC={{{CraftDC|}}}|CraftSkill={{{CraftSkill|}}}|CraftCost={{{CraftCost|}}}|Source={{{Source|}}}|Campaigns={{{Campaigns|}}} }}<!--
! Name
+
 
| {{{Name|}}}
+
--><h3>{{{Name|}}}</h3>
 +
 
 +
{{{ItemType|}}}{{#if: {{{ItemSubType|}}}|({{{ItemSubType}}})}}{{#if: {{{SortName|}}}|: {{{SortName|}}}}} ({{#if: {{{TreasureUse|}}}|{{{TreasureUse}}}|None}})<br><!--
 +
-->{{#if: {{{Tags|}}}|({{#arraymap:{{{Tags|}}}|,|x|[[x]]}})}}<!--
 +
-->''{{#arraymap:{{{Campaigns|}}}|,|x|[[x]]}}''
 +
 
 +
{{#!:{| class="wikitable"
 
|-
 
|-
! SortName
+
! Cost !! Weight {{#if:{{{CraftDC|}}}|!! Craft DC|}}
| {{{SortName|}}}
 
 
|-
 
|-
! Category
+
| {{{Price|—}}} gp}}} || {{{Weight|—}}} {{#if:{{{CraftDC|}}}|{{!}}{{!}} {{{CraftDC}}}|}}
| {{#arraymap:{{{Category|}}}|,|x|[[x]]}}
+
|}}}<!--
  
|-
+
-->'''Short:''' {{{Short|}}}<!--
! Subcategory
+
 
| {{#arraymap:{{{Subcategory|}}}|,|x|[[x]]}}
+
-->{{#if: {{{Fluff|}}}|''{{{Fluff}}}''
 +
 
 +
<wbr>|}}<!--
 +
 
 +
-->{{#if: {{{Description|}}}|{{{Description}}}
  
|-
+
<wbr>|}}<!--
! TreasureUse
 
| {{{TreasureUse|}}}
 
|-
 
! Tags
 
| {{#arraymap:{{{Tags|}}}|,|x|[[x]]}}
 
  
|-
+
-->{{#if: {{{CraftDC|}}}|'''Craft''' ({{{CraftType|}}}): {{{CraftDC}}}<br>'''Cost:''' {{{CraftCost|Undefined}}}}}{{#if: {{{CraftRequirements|}}}|<br>'''Requirements:''' {{{CraftRequirements}}}|}}{{#if: {{{CraftDC|}}}|
! Price
 
| {{{Price|}}}
 
|-
 
! Weight
 
| {{{Weight|}}}
 
|-
 
! Short
 
| {{{Short|}}}
 
|-
 
! Fluff
 
| {{{Fluff|}}}
 
|-
 
! Description
 
| {{{Description|}}}
 
|-
 
! Source
 
| {{#arraymap:{{{Source|}}}|,|x|[[x]]}}
 
  
|-
+
<wbr>|}}<!--
! Campaigns
 
| {{#arraymap:{{{Campaigns|}}}|,|x|[[x]]}}
 
  
|}
+
-->'''Sources:''' {{{Source|}}}
 
</includeonly>
 
</includeonly>

Revision as of 10:55, 14 March 2020

This is the "Item" template.

Name=Real name of item
SortName=Name for use when sorting; "Climbing Kit, Basic" and "Climbing Kit, Deluxe"
ItemType=The major category of item: Weapons, Dungeoneering, Alchemy, etc
ItemSubType=The subcategory of item: Alchemical Weapons, Alchemical Boosters, Alchemical Tools
TreasureUse=Weapon, Protection, Magical, Consumable, Gear
Tags=Any further tags used for filtering
Price=Buying price in gp (Float)
Weight=Weight of the item in lbs. (Float)
Short=Short summary of benefits/use for tables
Fluff=Fluff description
Description=Full description
CraftRequirements=Workshop, feats, materials, talents
CraftDC=The Craft DC for the item (Integer)
CraftSkill=The Craft skill used for the item or Spellcraft
CraftCost=Cost in sp/gp (Float)
Source=OGL Codes
Campaigns=Filtering. "All" by default

It should be called in the following format:

{{Item
|Name=
|SortName=
|ItemType=
|ItemSubType=
|TreasureUse=
|Tags=
|Price=
|Weight=
|Short=
|Fluff=
|Description=
|CraftRequirements=
|CraftDC=
|CraftSkill=
|CraftCost=
|Source=
|Campaigns=
}}

Edit the page to see the template text. This template defines the table "Base_Items". View table.