Difference between revisions of "Template:Item"

From Wurmpedia
Jump to navigation Jump to search
(Setting creation parameter will display a specific creation entry instead of the crafting steps)
(added canned creation options (farm, fish, botanize, forage, mine, wood, dig, and no) to reduce inconsistencies or copy pasting between item pages. Add more to the switch statement if necessary.)
Line 16: Line 16:
 
|
 
|
 
{{#if:{{{creation|}}}|
 
{{#if:{{{creation|}}}|
{{#ifeq:{{{creation}}}|no|This item can not be created|{{{creation}}}}}
+
{{#switch: {{{creation}}}
 +
| no = This item can not be created.
 +
| farm = Obtained through [[Farming|harvesting]].
 +
| forage = Obtained through [[forage|foraging]].
 +
| botanize = Obtained through [[botanize|botanizing]].
 +
| fish = Obtained through [[fishing]].
 +
| mine = Obtained through [[mining]].
 +
| wood = Obtained through [[woodcutting]].
 +
| dig = Obtained through [[digging]].
 +
}}
 
|
 
|
 
# [[Activate]] a {{{active}}}
 
# [[Activate]] a {{{active}}}
Line 73: Line 82:
 
|name=Huge shod club        *** defaults to {{PAGENAME}} ***
 
|name=Huge shod club        *** defaults to {{PAGENAME}} ***
 
|result=1 '''huge shod club''' (15.00 kg)
 
|result=1 '''huge shod club''' (15.00 kg)
|creation=Troll drop        *** 'no' will result in 'The item can not be created' ***
+
|creation=Troll drop        *** 'no' will result in 'The item can not be created', other options include farm, fish, botanize, forage, mine, wood, dig ***
 
|improve=no
 
|improve=no
 
}}
 
}}

Revision as of 18:56, 29 March 2011

General item template.

The template adds a box with an image of the item and the steps to create the item.

If the creation parameter is set the box will display its contents instead of the creation steps.

Usage examples:

{{item
|name=Hammer         *** defaults to {{PAGENAME}} ***
|image=hammer.jpg    *** defaults to {{PAGENAME}}.jpg or {{PAGENAME}}.png ***
|active=[[hammer head]] (0.4 kg)
|passive=[[shaft]] (1.0 kg)
|group=Tools
|materials=no
|result=1 '''hammer''' - 1.4 kg
|skill=blacksmithing
|improve=smithing
}}
{{item
|name=Huge shod club         *** defaults to {{PAGENAME}} ***
|result=1 '''huge shod club''' (15.00 kg)
|creation=Troll drop         *** 'no' will result in 'The item can not be created', other options include farm, fish, botanize, forage, mine, wood, dig ***
|improve=no
}}