Template:Spell/doc
From Archaelund Wiki
Description
This is the main template for all spell pages. It determines the layout of the individual page and provides functionality for extracting specific spell information for use in other pages.
Usage
{{Spell
|Mode = {{{1|Page}}}
|Param1 = {{{2|}}}
|Param2 = {{{3|}}}
<!-- Quick Facts -->
|Name =
|Pagename =
|Status =
|Type =
|Version =
|VersionUpdate =
|Attributes =
<!-- Media -->
|Image =
|Icon =
<!-- Info -->
|Description =
|Notes =
<!-- Category -->
|Discipline =
|Rank =
<!-- Usage -->
|APcost =
|WPcost =
<!-- Stats -->
|Target =
|Range =
|Duration =
|Resist =
}}
Parameters
| Name | Required | Description | Values |
|---|---|---|---|
| Mode | Yes | Determines the mode of execution of the template (see below). Changing the predefined value may lead to unexpected behavior. | {{{1|Page}}} (should not be changed) |
| Param1 | Yes | Used for routing a selection parameter to the template in certain modes (see below). Changing the predefined value may lead to unexpected behavior. | {{{2|}}} (should not be changed) |
| Param2 | Yes | Used for routing a selection parameter to the template in certain modes (see below). Changing the predefined value may lead to unexpected behavior. | {{{3|}}} (should not be changed) |
| Quick Facts | |||
| Name | Yes | The name of the spell as used in the game. Will be displayed in the infobox of the page. | arbitrary text |
| Pagename | Yes | The title of the spell page, needed for linking purposes. Note: Do not use magic words such as {{PAGENAME}} here, as this prevents proper linking when transcluding information from this page on other pages. | arbitrary text |
| Status | No | If the page has a special status, it can be set here. A corresponding box will be displayed at the top of the page. | one of the values defined in Template:PageStatus |
| Type | Yes | The specific type of the spell. Will be displayed in the infobox of the page. | one of the values defined in Template:SpellType (other values are ignored): Combat • Explore • Universal |
| Version | Yes | The game version in which the spell was first introduced. Will be displayed in the infobox of the page. | version number in the form X.Y.Z |
| VersionUpdate | No | The game version in which the spell was last updated. Will be displayed in the infobox of the page. | version number in the form X.Y.Z |
| Attributes | No | One or more attributes which describe certain aspects of the spell. Will be displayed in the infobox of the page. A list of predefined attributes can be found in Template:SpellAttributes (if new attributes are introduced, they should also be added there). | a semicolon-separated list of the values defined in Template:SpellAttributes (other values are ignored): Heal • Damage • Buff • Debuff • Disable • Summon • Environment |
| Media | |||
| Image | Yes | The image (PNG or JPG) to be displayed in the infobox of the page. | image name (including file extension) |
| Icon | No | The image (PNG or JPG) to be displayed as an icon in spell tables, lists, etc. If nothing is specified, a small version of Image is used instead. | image name (including file extension) |
| Info | |||
| Description | Yes | A concise description of the spell itself. Is used as an introductory paragraph and should ideally contain the same information as the in-game description. | arbitrary text |
| Notes | No | Any kind of ancillary information (which does not seem appropriate anywhere else) can be provided here. | arbitrary text, ideally formatted as a bullet list (using *) |
| Category | |||
| Discipline | Yes | The magical Discipline to which this spell belongs. | one of the values defined in Template:SpellDiscipline (other values are ignored): Animism • Auspice • Conjuration • Gateway • Impetus • Malediction • Mentalism • Order • Piety |
| Rank | Yes | The rank of the spell. | positive number |
| Usage | |||
| APcost | No | The amount of Action Points (AP) needed for using this spell. Defaults to "None". | positive number |
| WPcost | No | The amount of Willpower (WP) needed for using this spell. Defaults to "None". | positive number |
| Stats | |||
| Target | Yes | The type of target(s) to which this spell can be applied. | arbitrary text |
| Range | No | The casting range of the spell, usually expressed in tiles. | arbitrary text |
| Duration | No | The duration of the spell's effects, expressed in rounds (for turn-based combat) and/or real time (for exploration mode). | arbitrary text |
| Resist | No | If the spell's effects can be resisted by the target, the resistance type can be given here. Defaults to "None". | arbitrary text |
Extracting specific spell information for use in other pages
Syntax
You can transclude information from a spell page in any other page by using the following syntax:
{{:<pagename>|<mode>|<param1>|<param2>}}
Here, <pagename> is the spell's full page name (in main namespace), <mode> determines the type of information to be transcluded, and <param1> & <param2> represent selection parameters required by certain modes.
Modes and parameters
| Mode | Description | Parameter 1 | Parameter 2 |
|---|---|---|---|
| Page | Outputs the full spell page. This is the default mode. | none | none |
| TableHead | Outputs the header of a spell table (intended for constructing overview tables). | none | none |
| TableEntry | Outputs a table row containing specific spell information (intended for constructing overview tables). If a selector is specified in <param1>, output is only generated if the selector of a specific spell matches the value of <param2>. If no selector is specified, output is always generated. | one of the following selectors: Type • Discipline • Attribute | one of the possible values of the specified selector |