Template:Rulebook
From AmtWiki
Revision as of 20:07, 11 February 2025 by Ignius Alexander (talk | contribs)
This template generates a link to a rulebook page based on the provided edition number. It uses a switch statement to map edition numbers to their respective pages.
Usage
{{rulebook|edition_number|optional_custom_text}}
- Parameter 1:
edition_number
(required) - The version of the rulebook (e.g., `7.1`). - Parameter 2:
optional_custom_text
(optional) - The displayed text for the link (defaults to the edition number).
Examples
Edition | WikiCode (inside ) |
Result |
---|---|---|
1.0 | {{rulebook|1.0}} |
1.0 |
2.0 | {{rulebook|2.0}} |
2.0 |
6.1 | {{rulebook|6.1}} |
6.1 |
7.1 | {{rulebook|7.1}} |
7.1 |
8.6.2 | {{rulebook|8.6.2}} |
8.6.2 |
7.5 (Custom Text) | {{rulebook|7.5|Seventh Edition Update}} |
Seventh Edition Update |
5.A (Invalid) | {{rulebook|5.A}} |
Invalid Rulebook Version |