User:GrampaSwood/Help:References

From Team Fortress Wiki
Jump to: navigation, search

References are a core part of documenting information. On the Team Fortress Wiki, references are typically used for reference trivia, information taken from source code (leaked code or Source SDK code), or information taken from a map's VScript files. This help article will help users with using references on the Team Fortress Wiki.

General information

Main article: Help:Cite on the Mediawiki wiki

References are created using the <ref> tags, and they are stored in a "References" section at the very bottom of the article (above the navigational templates). References should be placed after punctuation. An example of a reference taken from Sandman:

After slowing an enemy, it disappears much more quickly - only 4 seconds<ref>src/game/shared/tf/tf_weapon_bat.ccp:L799</ref>

Resulting in:

  • After slowing an enemy, it disappears much more quickly - only 4 seconds[1]
  1. src/game/shared/tf/tf_weapon_bat.ccp:L799

Named references

References can also be used multiple times throughout an article without having to type them again by naming them:

<ref name="ball timer">src/game/shared/tf/tf_weapon_bat.ccp:L799</ref>

Later on, simply typing <ref name="ball_timer"/> automatically places the reference:

  • When the ball disappears after 4[1]-10 seconds [...]
  1. src/game/shared/tf/tf_weapon_bat.ccp:L799

When to use references

References are typically used to provide a source for the previous statement. The following statements typically have a reference attached:

Reference types

SDK code reference

Source code references from the Software Development Kit (SDK) should always start at the "src" folder to distinguish them from VScript and leak references. Optionally, a link to the GitHub repository with the specific line of code. Example: src/game/shared/tf/tf_gamerules.cpp:L7488

Leaked content reference

Recreations, links, or uploading any kind of leaked material is strictly forbidden and will be removed immediately. Instead, references should be used. These references are almost always file paths. For non-code files, such as textures or photoshop files: tf_materialSrc\materialsrc\backpack\player\items\all_class\taunt_flip_large.psd. For code references, exclusively a file path should be used. No links or snippets. Example: game\shared\tf\tf_weapon_wrench.cpp:L31

VScript reference

For VScript, at the top of the reference section should be {{VScript refnote}}. References work identical to leaked code references, plain filepaths.

Trivia references

A reference with an image archived on archive.org of the creator confirming the reference. If a trivia is reached through consensus, it is marked with the {{Consensus trivia}} template and does not require a reference.

Reference section

Reference sections should be the header, titled "References", and <references/>. For simplicity, {{Refsection}} can be substituted to automatically create a section.