Template:Bug

From NWN Lexicon
Red bug icon.png Warning: This function has a known bug and may not work as expected in some situations. See Known Bugs for details.

[edit] [purge] Template info icon.png Template Documentation

Warning icon orange.png This template is used on a large number of pages.

In order to prevent unnecessary server load, edits should be kept to a minimum. Please experiment in your user page, and consider discussing your changes on the talk page before applying them.

Information icon.png Editing a template causes all pages that use the template to be re-rendered. If the template is used often, this can put a lot of load on the server since it fills up the job queue.

Contents

[edit] Usage

This template places a banner noting that the script or function documented in the article has a known bug. Use this template at the top of the article so readers will be alerted to the bug. Use this only for bugs that are already documented on the Lexicon, and do not use it for bugs that are really "features". If you are unsure about the existence of the bug or whether any unexpected behavior is truly unintended, do not use this template. Instead, start a discussion on the article's talk page.

Information icon.png It's possible for a function or script to have both "features" and bugs. In these cases, use both the bug template and the {{feature}} template.

Using this template on a page will add it to either Category:Functions with known bugs or Category:Scripts with known bugs, as determined by the type parameter.

[edit] Parameters

[edit] type

The type parameter can take a value of "script" or "function". This will change the template slightly to account for whether the bug is in a function or in a script (*.nss file) and change which category the article is filed into. If you do not set this parameter, its default value is "function".

In an article about a bugged function, either of these variants would be acceptable:

{{bug}}
{{bug|type=function}}

Both of these examples produce:

Red bug icon.png Warning: This function has a known bug and may not work as expected in some situations. See Known Bugs for details.


However, in an article about a script, this would be the proper format:

{{bug|type=script}}

This produces:

Red bug icon.png Warning: This script has a known bug and may not work as expected in some situations. See Known Bugs for details.


[edit] doc

The doc parameter can take a link to the location of the documentation about the bug. If you leave this parameter blank, it will default to the "Known Bugs" section of the page, but in the unlikely event that the proper documentation is in a different section or on another page entirely, you should set this parameter. Its content should be the wiki markup that would generate the desired link.

For example, if the documentation is on the article's talk page, you could use the following:

{{bug|doc=the [[{{TALKPAGENAME}}|talk page]]}}

This produces:

Red bug icon.png Warning: This function has a known bug and may not work as expected in some situations. See the talk page for details.


Alternatively, you can elect to not use a link at all:

{{bug|doc=below}}
Red bug icon.png Warning: This function has a known bug and may not work as expected in some situations. See below for details.


[edit] See Also

{{feature}}

Personal tools
Categories