Difference between revisions of "Template:Game navbox"

From Worms Knowledge Base

Jump to: navigation, search
(add description)
m (Customisation)
 
(10 intermediate revisions by the same user not shown)
Line 1: Line 1:
{|class="block" border="0" width="550" style="display: block;"
+
<includeonly>{|class="block" border="0" cellspacing="0" width="550" style="display: block;"
 
|-
 
|-
 
|width="60%" style="vertical-align: top"|
 
|width="60%" style="vertical-align: top"|
{{Game navbox/Releases}}
+
{{{1|{{Game navbox/{{{box1|Releases}}}|{{{param1|}}}}}}}}
 
|style="vertical-align: top"|
 
|style="vertical-align: top"|
{{Game navbox/Software}}
+
{{{2|{{Game navbox/{{{box2|Software}}}|{{{param2|}}}}}}}}
 
|-
 
|-
 
|style="vertical-align: top"|
 
|style="vertical-align: top"|
{{Game navbox/Game technology|{{{1|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/Online play}}
+
{{{4|{{Game navbox/{{{box4|Online play}}}|{{{param4|}}}}}}}}
 
|-
 
|-
 
|style="vertical-align: top"|
 
|style="vertical-align: top"|
{{Game navbox/Community}}
+
{{{5|{{Game navbox/{{{box5|Community}}}|{{{param5|}}}}}}}}
 
|style="vertical-align: top"|
 
|style="vertical-align: top"|
{{#ifeq:{{PAGENAME}}|Worms Armageddon|{{Game navbox/FAQs}}}}
+
{{{6|{{#if:{{{box6|}}}|{{Game navbox/{{{box6}}}|{{{param6|}}}}}}}}}}
|}<noinclude>__NOTOC____NOEDITSECTION__
+
|}</includeonly><noinclude>__NOTOC__
 +
{{Game navbox|param1=preview|box6=FAQs}}
 
----
 
----
=== Notes ===
+
=== How to use ===
* This template contains 6 sub-templates:
+
Simply add "<nowiki>{{Game navbox}}</nowiki>" to put a navigation panel (with default items).
:{|
+
 
 +
Note: For first-generation games, use <nowiki>{{Game navbox|param3=First generation}}</nowiki> instead. This will change the "Tricks and glitches" link to the correct one.
 +
 
 +
=== Customisation ===
 +
This panel contains 9 sub-templates:
 +
{|
 
|-
 
|-
| <nowiki>{{</nowiki>[[Template:Game navbox/Releases|Game navbox/Releases]]<nowiki>}}</nowiki>
+
|&#123;&#123;[[Template:Game navbox/Releases|Game navbox/Releases]]&#125;&#125;
| <nowiki>{{</nowiki>[[Template:Game navbox/Software|Game navbox/Software]]<nowiki>}}</nowiki>
+
{{Game navbox/Releases|preview}}
 +
|&#123;&#123;[[Template:Game navbox/Software|Game navbox/Software]]&#125;&#125;
 +
{{Game navbox/Software}}
 +
|-
 +
|&#123;&#123;[[Template:Game navbox/Game technology|Game navbox/Game technology]]&#125;&#125;
 +
{{Game navbox/Game technology}}
 +
|&#123;&#123;[[Template:Game navbox/Online play|Game navbox/Online play]]&#125;&#125;
 +
{{Game navbox/Online play}}
 +
|-
 +
|&#123;&#123;[[Template:Game navbox/Community|Game navbox/Community]]&#125;&#125;
 +
{{Game navbox/Community}}
 +
|&nbsp;
 +
|-
 +
|&#123;&#123;[[Template:Game navbox/FAQs|Game navbox/FAQs]]&#125;&#125; (WA only)
 +
{{Game navbox/FAQs}}
 +
|&#123;&#123;[[Template:Game navbox/Wormopaedia|Game navbox/Wormopaedia]]&#125;&#125; (WWP only)
 +
{{Game navbox/Wormopaedia}}
 +
|-
 +
|&#123;&#123;[[Template:Game navbox/WDC Customisation|Game navbox/WDC Customisation]]&#125;&#125; (WDC only)
 +
{{Game navbox/WDC Customisation}}
 +
|&#123;&#123;[[Template:Game navbox/WDC Emulation|Game navbox/WDC Emulation]]&#125;&#125; (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"
 +
|-
 +
| '''{{{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"
 +
|-
 +
| <nowiki>{{</nowiki>Game navbox/ '''{{{box1}}}''' &#x7C; '''{{{param1}}}''' <nowiki>}}</nowiki>
 +
| <nowiki>{{</nowiki>Game navbox/ '''{{{box2}}}''' &#x7C; '''{{{param2}}}''' <nowiki>}}</nowiki>
 +
|-
 +
| <nowiki>{{</nowiki>Game navbox/ '''{{{box3}}}''' &#x7C; '''{{{param3}}}''' <nowiki>}}</nowiki>
 +
| <nowiki>{{</nowiki>Game navbox/ '''{{{box4}}}''' &#x7C; '''{{{param4}}}''' <nowiki>}}</nowiki>
 +
|-
 +
| <nowiki>{{</nowiki>Game navbox/ '''{{{box5}}}''' &#x7C; '''{{{param5}}}''' <nowiki>}}</nowiki>
 +
| <nowiki>{{</nowiki>Game navbox/ '''{{{box6}}}''' &#x7C; '''{{{param6}}}''' <nowiki>}}</nowiki>
 +
|}
 +
 
 +
====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"
 
|-
 
|-
| <nowiki>{{</nowiki>[[Template:Game navbox/Game technology|Game navbox/Game technology]]<nowiki>}}</nowiki>
+
! Preview of the example above
| <nowiki>{{</nowiki>[[Template:Game navbox/Online play|Game navbox/Online play]]<nowiki>}}</nowiki>
+
 
|-
 
|-
| <nowiki>{{</nowiki>[[Template:Game navbox/Community|Game navbox/Community]]<nowiki>}}</nowiki>
+
| {{Game navbox|1={{Game navbox/Releases|preview}}|2={{Template:Game navbox/Sample}}}}
| <nowiki>{{</nowiki>[[Template:Game navbox/FAQs|Game navbox/FAQs]]<nowiki>}}</nowiki>
+
 
|}
 
|}
* For first-generation games, use <nowiki>{{Game navbox|First generation}}</nowiki> instead. This will change the "Tricks and glitches" link to the correct one.
+
 
 +
====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>
 
</noinclude>

Latest revision as of 11:48, 23 September 2010

Releases Releases


Software Software
Game technology Game technology
Online play Online play
Community Community
FAQs FAQs

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}}
Releases Releases


{{Game navbox/Software}}
Software Software
{{Game navbox/Game technology}}
Game technology Game technology
{{Game navbox/Online play}}
Online play Online play
{{Game navbox/Community}}
Community Community
 
{{Game navbox/FAQs}} (WA only)
FAQs FAQs
{{Game navbox/Wormopaedia}} (WWP only)
Wormopaedia Wormopaedia
{{Game navbox/WDC Customisation}} (WDC only)
Customisation Customisation
{{Game navbox/WDC Emulation}} (WDC only)
Worms DC Emulation Emulating Worms DC

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}}

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.

Worms Knowledge Base Sample
  • Text1
  • Text2
  • Text3
Personal tools