# The Golden Rules

1. Please refer to the MediaWiki formatting manual if you are unsure of how to do something.
2. Please use the sandbox page to do any tests so that regular pages are not disrupted.

# Posting Conventions

## All Edits

• When posting code, be sure to enclose all code blocks with <syntaxhighlight> or <source> tags. See the Syntax Highlighting section for more information.
• When posting ASCII art, wrap it in <pre></pre> tags. This will cause your text to be displayed in a fixed-width font, with all whitespace preserved.
• When referring to variables and other technical terms, be sure to use the "Technical Terms" tag: <TT></TT>. This will display the term in a typewriter-style font, emphasizing that it is a technical term.
• Posts must be made in the English language. Links to non-English content is permitted, but only if the link text itself is in English, and if the linked content is somehow useful to English speaking readers. (ie. Source code is useful, regardless of language.)
• When attempting to call attention to a specific word or phrase, do not use the standard HTML bold or italics tags. Instead use the wiki markup emphasis tags. Simply surround the word or phrase in double, triple, or quintuple single quotes: ''Like'' '''this''' '''''or this'''''. The results look like this or this.
• To create subject headings or subheadings, do not use emphasis tags. Instead use the wiki heading tags. Surround the heading with equals symbols, and place it on a new line:

=This would be a major heading.=

• New. Be sure to use templates where applicable; this keeps the wiki clean and consistant. For a list of templates, click here.
• If you're not confident in your wiki markup abilities and would like to practice, please do so on the sandbox page. Any edits you make on the sandbox page cannot harm the wiki, so feel free to test things out there!

• The easiest way to create a new page is to create a link to it from an appropriate page, and then clicking on that link. Links to uncreated pages will show in a different colour than other links (usually red) and will allow you to create and edit that page directly. Alternatively, simply type the new page name in the URL bar of your browser like this: http://content.gpwiki.org/index.php/YOUR_PAGE_NAME_HERE.
• Be sure to add your page to the proper category! This helps keep the wiki organised and helps others find what they are looking for. For a list of categories you can add an article, click here.
• If you've added an entirely new article to the wiki, feel free to post on the Current events page to let everyone know what's new.
• When creating templates, always start the page with the following code:
<noinclude>
{{Warning_Template}}
{{Note:Use|use=INSTRUCTIONS FOR USE}}
</noinclude>

This will keep the wiki consistent, automatically add the new template to the template category, and tell others what purpose your template can be used for

## Modifying an Existing Page

• When making minor modifications to an article (such as a spelling or grammar correction), please be sure to check the "This is a minor edit" checkbox, above the Save page button. This will ensure that users who are watching for major page changes will not be flooded with minor edits.
• If you wish to make a major modification to an article that conflicts or disagrees with content already contained within the article, please use the Discussion page attached to the article to explain yourself. (Each article page has a Discussion tab at the top.) Once you've made your case on the discussion page, please visit the forums to inform other users of your intentions. If you do not see a response within a reasonable amount of time, then you may go ahead and make your changes.
• In order to organize our content, and avoid duplication of information, we use templates to store some of the information. You can recognize a reference to a template in the code by the {{curly braces}}. Please add appropriate changes you make to these existing templates.
• If you notice that there is a large amount of data duplicated on two or more pages, make a note of it on the discussion page of one of the pages, and also mention it in the Content Issues forum for further investigation.

# Game Programming Wiki Features

GPWiki has some special extra features in addition to the standard MediaWiki markup.

## Syntax Highlighting

When posting code, be sure to enclose all code blocks with <syntaxhighlight type="language"> or <source type="language"> tags. This will cause your code block to be displayed with syntax highlighting.

Example:

<syntaxhighlight type="java">
Guy bob = new Guy();
if (somethingHappened == false) {
bob.yawn();
}
</syntaxhighlight>


Or

<source type="java">
Guy bob = new Guy();
if (somethingHappened == false) {
bob.yawn();
}
</source>


Result:

Guy bob = new Guy();
if (somethingHappened == false) {
bob.yawn();
}

In the language parameter you can select from an extensive list of languages such as:

• "asm"
• "c"
• "csharp"
• "cpp"
• "dos"
• "ini"
• "java"
• "lisp"
• "lua"
• "pearl"
• "php"
• "python"
• "qb"
• "ruby"
• "vb"
• "vbnet"
• "xml"
• and many more.

See the Generic Syntax Highlighter website for the complete list.

## Math

GPWiki uses LaTeX to generate images for better representation of mathematical formulae as images.

Example:

$\begin{Bmatrix} x & y & a\\ y & u & b\\ z & v & c \end{Bmatrix}$



Result
$\begin{Bmatrix} x & y & a\\ y & u & b\\ z & v & c \end{Bmatrix}$

Another Example

$\sum_{k=1}^N k^2$


Result
$\sum_{k=1}^N k^2$

The resulting image is cached after being rendered for the first view. You may have to force a browser refresh when adjusting the markup to see the result.

See MediaWiki's Formula Help for advanced techniques.

## Templates

Templates are a powerful feature of MediaWiki. Some are simple chunks of markup, some take arguments and some simply modify the way pages are handled.

All templates are invoked by using the {{TEMPLATE_NAME|ARGUMENTS}} syntax.

The following templates are available for use:

### Stub

Use Stub if a page needs to have more information added. This will automatically put the page in the stubs category.

Example:

{{Stub}}


Result:

### Markup Fix

Use this template to add a page to the Category:Pages with Broken Markup category.

Example:

{{MarkupFix}}


Result:

### Deprecated

Use this template to highlight out of date code. The information in the article may still be useful, but it should be highlighted if code or techniques are out-of-date.

Example:

{{Deprecated}}


Result:

If there is an updated page, we can leave the old page for reference and direct people to the latest information.

Example:

{{DeprecatedWithLink|BETTER_PAGE}}


Result:

### Forum Banners

Example:

{{GPWiki User|FORUM_ID_HERE}}


Result:

 This user is also a GPWiki forums user.

Example:

{{Gamedev User|FORUM_ID_HERE}}


Result:

 This user is also a gamedev.net user.

### TipBox

Example:

{{TipBox|Peanut butter goes well with strawberry jam.}}


Result:

Tip
Peanut butter goes well with strawberry jam.

### InformationBox

Example:

{{InformationBox|Snapples provide an entire day's worth of your recommended tin intake.}}


Result:

Information
One snapple provides an entire day's worth of your recommended tin intake.

### NoticeBox

Example:

{{NoticeBox|Never mix coffee and relish.}}


Result:

Notice
Never mix coffee and relish.

### Icons

GPWiki has a range of icons that are used to keep table sizes down and add a splash of colour to articles. Using the icons templates rather than linking to images means that updating the icons across the whole wiki is much easier.

• Yes {{Yes}}
• No {{No}}
• Yes {{YesInfo|Text=I'm some custom information|Link=Main_Page}}
• No {{NoInfo|Text=I'm some custom information|Link=Main_Page}}

• Windows {{Windows}}
• Linux {{Linux}}
• Android {{Android}}
• BSD {{BSD}}
• BeOS {{BeOS}}
• iOS {{IOS}}
• {{InfoRollover|Text=This text appears in the tooltip}}
• OSX {{MacOS}}
• Playstation {{Playstation}}
• Solaris {{Solaris}}
• Wii {{Wii}}
• XBox {{Xbox}}

### Amazon Book Info Lookup

GPWiki's Amazon Book Info lookup feature produces an info box using Amazon web services when given an ASIN-10 ID number as an argument. This number is listed on the product details on each Amazon page.

Example:

{{#AmazonBookInfo:0735619670}}
Code Complete: A Practical Handbook of Software Construction, Second Edition
Author: Steve McConnell
Publisher: Microsoft Press
Published: 2004-06-19
Pages: 960
Edition: 2nd
View at Amazon

Note, this template will normally float to the right of the page.

If the book title is very long and spoils the layout, you can specify a shorter title as a second argument.

{{#AmazonBookInfo:0735619670|Code Complete 2}}
Code Complete 2
Author: Steve McConnell
Publisher: Microsoft Press
Published: 2004-06-19
Pages: 960
Edition: 2nd
View at Amazon