Difference between revisions of "Template:Game navbox"
From Worms Knowledge Base
Explorer09 (Talk | contribs) (description text) |
Explorer09 (Talk | contribs) m (→Customisation) |
||
(3 intermediate revisions by the same user not shown) | |||
Line 2: | Line 2: | ||
|- | |- | ||
|width="60%" style="vertical-align: top"| | |width="60%" style="vertical-align: top"| | ||
− | {{Game navbox/{{{box1|Releases}}}|{{{param1|}}}}} | + | {{{1|{{Game navbox/{{{box1|Releases}}}|{{{param1|}}}}}}}} |
|style="vertical-align: top"| | |style="vertical-align: top"| | ||
− | {{Game navbox/{{{box2|Software}}}|{{{param2|}}}}} | + | {{{2|{{Game navbox/{{{box2|Software}}}|{{{param2|}}}}}}}} |
|- | |- | ||
|style="vertical-align: top"| | |style="vertical-align: top"| | ||
− | {{#if:{{{box3|}}}|{{Game navbox/{{{box3}}}|{{{param3|}}}}}|{{Game navbox/Game technology|{{{param3|Second generation}}}}}}} | + | {{{3|{{#if:{{{box3|}}}|{{Game navbox/{{{box3}}}|{{{param3|}}}}}|{{Game navbox/Game technology|{{{param3|Second generation}}}}}}}}}} |
|style="vertical-align: top"| | |style="vertical-align: top"| | ||
− | {{Game navbox/{{{box4|Online play}}}|{{{param4|}}}}} | + | {{{4|{{Game navbox/{{{box4|Online play}}}|{{{param4|}}}}}}}} |
|- | |- | ||
|style="vertical-align: top"| | |style="vertical-align: top"| | ||
− | {{Game navbox/{{{box5|Community}}}|{{{param5|}}}}} | + | {{{5|{{Game navbox/{{{box5|Community}}}|{{{param5|}}}}}}}} |
|style="vertical-align: top"| | |style="vertical-align: top"| | ||
− | {{#if:{{{box6|}}}|{{Game navbox/{{{box6}}}|{{{param6|}}}}}}} | + | {{{6|{{#if:{{{box6|}}}|{{Game navbox/{{{box6}}}|{{{param6|}}}}}}}}}} |
|}</includeonly><noinclude>__NOTOC__ | |}</includeonly><noinclude>__NOTOC__ | ||
{{Game navbox|param1=preview|box6=FAQs}} | {{Game navbox|param1=preview|box6=FAQs}} | ||
Line 24: | Line 24: | ||
=== Customisation === | === Customisation === | ||
− | This panel contains | + | This panel contains 9 sub-templates: |
+ | {| | ||
+ | |- | ||
+ | |{{[[Template:Game navbox/Releases|Game navbox/Releases]]}} | ||
+ | {{Game navbox/Releases|preview}} | ||
+ | |{{[[Template:Game navbox/Software|Game navbox/Software]]}} | ||
+ | {{Game navbox/Software}} | ||
+ | |- | ||
+ | |{{[[Template:Game navbox/Game technology|Game navbox/Game technology]]}} | ||
+ | {{Game navbox/Game technology}} | ||
+ | |{{[[Template:Game navbox/Online play|Game navbox/Online play]]}} | ||
+ | {{Game navbox/Online play}} | ||
+ | |- | ||
+ | |{{[[Template:Game navbox/Community|Game navbox/Community]]}} | ||
+ | {{Game navbox/Community}} | ||
+ | | | ||
+ | |- | ||
+ | |{{[[Template:Game navbox/FAQs|Game navbox/FAQs]]}} (WA only) | ||
+ | {{Game navbox/FAQs}} | ||
+ | |{{[[Template:Game navbox/Wormopaedia|Game navbox/Wormopaedia]]}} (WWP only) | ||
+ | {{Game navbox/Wormopaedia}} | ||
+ | |- | ||
+ | |{{[[Template:Game navbox/WDC Customisation|Game navbox/WDC Customisation]]}} (WDC only) | ||
+ | {{Game navbox/WDC Customisation}} | ||
+ | |{{[[Template:Game navbox/WDC Emulation|Game navbox/WDC Emulation]]}} (WDC only) | ||
+ | {{Game navbox/WDC Emulation}} | ||
+ | |} | ||
+ | There are 2 methods to change the sub-templates. | ||
+ | |||
+ | ====Method 1==== | ||
+ | (Recommended) Using ''1''-''6'' parameters. Specify which template to use by using a template tag (like this: <code><nowiki>{{template|params}}</nowiki></code>). | ||
:{| border="1" | :{| border="1" | ||
|- | |- | ||
− | | | + | | '''{{{1}}}''' |
− | | | + | | '''{{{2}}}''' |
|- | |- | ||
− | | | + | | '''{{{3}}}''' |
− | | | + | | '''{{{4}}}''' |
|- | |- | ||
− | | | + | | '''{{{5}}}''' |
− | | | + | | '''{{{6}}}''' |
|} | |} | ||
− | |||
− | |||
− | + | ====Method 2==== | |
+ | |||
+ | Using ''boxN'' and ''paramN'' parameters. ''boxN'' specifies the '''name''' of the sub-templates, while ''paramN'' are their '''parameters'''. | ||
:{| border="1" | :{| border="1" | ||
|- | |- | ||
Line 50: | Line 80: | ||
| <nowiki>{{</nowiki>Game navbox/ '''{{{box5}}}''' | '''{{{param5}}}''' <nowiki>}}</nowiki> | | <nowiki>{{</nowiki>Game navbox/ '''{{{box5}}}''' | '''{{{param5}}}''' <nowiki>}}</nowiki> | ||
| <nowiki>{{</nowiki>Game navbox/ '''{{{box6}}}''' | '''{{{param6}}}''' <nowiki>}}</nowiki> | | <nowiki>{{</nowiki>Game navbox/ '''{{{box6}}}''' | '''{{{param6}}}''' <nowiki>}}</nowiki> | ||
− | |}</noinclude> | + | |} |
+ | |||
+ | ====Example==== | ||
+ | Both of the following replace the upper-right cell (box2) with [[Template:Game navbox/Sample]]: | ||
+ | *(method 1) <code><nowiki>{{Game navbox|2={{Template:Game navbox/Sample}} }}</nowiki></code> | ||
+ | *(method 2) <code><nowiki>{{Game navbox|box2=Sample}}</nowiki></code> | ||
+ | {| class="toc collapsible collapsed" | ||
+ | |- | ||
+ | ! Preview of the example above | ||
+ | |- | ||
+ | | {{Game navbox|1={{Game navbox/Releases|preview}}|2={{Template:Game navbox/Sample}}}} | ||
+ | |} | ||
+ | |||
+ | ====To create new sub-templates==== | ||
+ | You can create new sub-templates on your own, simply copy the code in [[Template:Game navbox/Sample]] to a new page and change the text within. | ||
+ | {{Game navbox/Sample}} | ||
+ | </noinclude> |
Latest revision as of 11:48, 23 September 2010
|
| ||||
|
| ||||
|
|
How to use
Simply add "{{Game navbox}}" to put a navigation panel (with default items).
Note: For first-generation games, use {{Game navbox|param3=First generation}} instead. This will change the "Tricks and glitches" link to the correct one.
Customisation
This panel contains 9 sub-templates:
{{Game navbox/Releases}}
|
{{Game navbox/Software}}
| ||||
{{Game navbox/Game technology}}
|
{{Game navbox/Online play}}
| ||||
{{Game navbox/Community}}
|
|||||
{{Game navbox/FAQs}} (WA only)
|
{{Game navbox/Wormopaedia}} (WWP only)
| ||||
{{Game navbox/WDC Customisation}} (WDC only)
|
{{Game navbox/WDC Emulation}} (WDC only)
|
There are 2 methods to change the sub-templates.
Method 1
(Recommended) Using 1-6 parameters. Specify which template to use by using a template tag (like this: {{template|params}}
).
{{{1}}} {{{2}}} {{{3}}} {{{4}}} {{{5}}} {{{6}}}
Method 2
Using boxN and paramN parameters. boxN specifies the name of the sub-templates, while paramN are their parameters.
{{Game navbox/ {{{box1}}} | {{{param1}}} }} {{Game navbox/ {{{box2}}} | {{{param2}}} }} {{Game navbox/ {{{box3}}} | {{{param3}}} }} {{Game navbox/ {{{box4}}} | {{{param4}}} }} {{Game navbox/ {{{box5}}} | {{{param5}}} }} {{Game navbox/ {{{box6}}} | {{{param6}}} }}
Example
Both of the following replace the upper-right cell (box2) with Template:Game navbox/Sample:
- (method 1)
{{Game navbox|2={{Template:Game navbox/Sample}} }}
- (method 2)
{{Game navbox|box2=Sample}}
Preview of the example above | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
To create new sub-templates
You can create new sub-templates on your own, simply copy the code in Template:Game navbox/Sample to a new page and change the text within.
Sample
|