Template:Item Sources/doc: Difference between revisions

From The Walkscape Walkthrough
Content deleted Content added
Create documentation
m Update
Line 8: Line 8:
{{Item Sources
{{Item Sources
| Item Sources =
| Item Sources =
{{Item Source
| Name =
| Image = (Recommended)
| Level = (Optional)
| Quantity =
| Chance =
}}
}}
}}
</syntaxhighlight>
</syntaxhighlight>
Line 13: Line 20:
===Empty copy===
===Empty copy===
<syntaxhighlight lang="wikitext">
<syntaxhighlight lang="wikitext">
{{Item Source
{{Item Sources
| Item Sources =
| Item Sources =
{{Item Source
| Name =
| Image =
| Level =
| Quantity =
| Chance =
}}
}}
}}
</syntaxhighlight>
</syntaxhighlight>

Revision as of 03:57, 8 March 2024

Parameters

Item Sources

A list of Template:Item Source templates that detail the sources for the item. This is required as it is the only parameter. This template does not include Level in the table formatting yet. Therefore it is unnecessary in the Template:Item Sources provided to include it as it will break formatting.

Quick Copy

Notated copy

{{Item Sources
| Item Sources = 
  {{Item Source
  | Name = 
  | Image = (Recommended)
  | Level = (Optional)
  | Quantity = 
  | Chance = 
  }}
}}

Empty copy

{{Item Sources
| Item Sources = 
  {{Item Source
  | Name = 
  | Image = 
  | Level = 
  | Quantity = 
  | Chance = 
  }}
}}

Examples

The formatting for Shovel Axe is as follows. Note that one set of Item Source brackets end on the same line as the next begin. This prevents formatting problems in the Chance Column

{{Item Sources
| Item Sources = 
  {{Item Source
  | Image = Mining_chest.png
  | Name = Mining Chests
  | Quantity = 1
  | Chance = 1/1000
  }} {{Item Source
  | Image = Woodcutting_chest.png
  | Name = Woodcutting Chests
  | Quantity = 1
  | Chance = 3/10000
  }}
}}

Yields:

Items

Source Quantity Chance Rate
Mining Chests 1 1/1000 Lua error in Module:1inCalculator at line 6: attempt to perform arithmetic on a nil value.
Woodcutting Chests 1 3/10000 Lua error in Module:1inCalculator at line 6: attempt to perform arithmetic on a nil value.