:Exclusive

Terraria Wiki
둘러보기로 이동 검색으로 이동
This template uses Lua.
This template uses 모듈:Exclusive, a script written in the Lua programming language. To learn more about Lua, see Terraria Wiki:Lua.
This template is i18n-ready, which means it is easy to localize for different languages. Please see I18n & l10n for templates to learn more.
See 틀:Exclusive/l10n for the localization of this template.
Template-info.svg Documentation The documentation below is transcluded from 틀:Exclusive/doc. (edit | history)

This template displays a banner denoting exclusivity of the content following it (usually an entire article) to one or more versions of Terraria.

Background and concept

Historically, platform exclusivity has been handled statically on the Terraria Wiki. For instance, when the Crimson was first introduced, a {{pc only}} template was put onto its article, since it was exclusive to the Desktop version at that time. When the biome was added to the Console version as well, that template had to be replaced with a {{pc-console only}} template. Similarly, a {{pc icon}} template was used wherever the Crimson was mentioned, e.g. on the article about Hardmode, and had to be replaced when it became available on Console. While this might have been feasible with a small number of articles, the effort to keep the exclusivity information up-to-date grew as the game was updated and ported to other platforms. Therefore, a dynamic system has been put into place that updates all mentions of platform exclusivity automatically.

This dynamic system is based on the idea that the exclusivity information about each entity is stored on its corresponding wiki page. "Entity" is used as a very broad term here, and includes – this is crucial – patch numbers. Once every patch article stores information about the platforms that it was released on, this information can be referenced on the articles that deal with the patch's contents. For example, the Crimson was first released in 1.2, so it is always only available on the platforms on which 1.2 is available. At first, the exclusivity information on the 1.2 article would have read "desktop", and because of the reference, the exclusivity information on the Crimson article would have read "desktop" as well. When 1.2 was made available on Console, its exclusivity information would have been updated to "desktop/console". Thanks to the dynamic system, the exclusivity information about the Crimson would have been updated automatically, because it references 1.2 and 1.2's exclusivity information would have been modified. The line of references can be continued and nested: The Brain of Cthulhu, for instance, can reference the Crimson, the Creeper can reference the Brain of Cthulhu, etc. All of them ultimately refer to 1.2, which is the only page where the exclusivity information needs to be updated.

Usage

{{ exclusive | <entity name> | invert = y/yes/1 | not = <entity name> | section = y/yes/1 | nocat = y/yes/1 | nobanner = y/yes/1 | width = <banner width> | css/style = <custom CSS> | <version parameters> = y/yes/1/n/no/0 | version = <versions> }}

First unnamed parameter

Name of the entity (wiki page name) to reference the exclusivity information from. For example, if set to Moon Lord, then the banner will always display the versions that the Moon Lord is available on. This is often set to a patch number, since there is a clear introduction patch for most entities, but it is sometimes more sensible to set it to another page name, e.g. for items of a group.

Appending a section to the page name is supported, the exclusivity information for the page name will still be gathered (see examples below).

invert

Inverts the exclusivity, i.e. displays the opposite versions. For instance, the opposite of the Moon Lord's exclusivity, which is currently desktop/console/mobile/tmodloader, would be old-gen/3ds. This is useful to refer to versions that do not feature a certain entity, the Moon Lord in this case.

Important note: this disables the Japanese Console version sensor, i.e. a Japanese Console version will never be displayed if $invert is used. This is because exclusivity to this version is separate – all entities that are exclusive to the Japanese Console version are truly exclusive to that version only.

not

Name of a page whose exclusivity information is to be subtracted from the main exclusivity information from the first unnamed parameter. This is useful to refer to versions where the first entity is available, but the second is not. For instance, it could be used when mentioning a feature that was removed from the Slimy Saddle (which was introduced in 1.2.4) in 1.3.0.1. The Slimy Saddle's general exclusivity information is desktop/console/old-gen/mobile/tmodloader, but only old-gen remains when subtracting 1.3.0.1's exclusivity information (which is desktop/console/mobile/tmodloader) from it.

Note that this is evaluated after $invert, i.e. the exclusivity information of the main page is inverted first, and then the exclusivity information of the page from this parameter is subtracted from that.

section

Changes the message text from "This information" to "This section's information", automatically activates nocat=y.

nocat

By default, the template adds the appropriate version content categories if the page is in mainspace. This parameter suppresses that.

nobanner

Prevents displaying the message banner box, thus only categorizes the page. This is usually used on redirect pages.

width

Sets the CSS width of the message banner box.

css or style

Custom CSS for the message banner box.

Version parameters

Override versions from the first unnamed parameter (after $invert and $not are evaluated), or set versions manually if no first unnamed parameter is provided. This is necessary where no reference to another page name is possible, e.g. on articles about patches themselves. Values for all of the following parameters can be y, y, yes, 1, n, no, or 0. $version (see below) can be used alternatively.

Desktop version dsk
desktop
pc
틀:Icon/console cns
console
틀:Icon/old-gen console old
oldgen
old-gen
old-gen console
Mobile version mbl
mobile
틀:Icon/3ds 3DS
3ds
틀:Icon/japanese console jas
japan
japanese
j-console
japanese-console
틀:Icon/switch swt
switch
틀:Icon/tmodloader tml
tmodloader
version

Alternative method to manually override certain versions. The expected format is <platform>-<platform>-<platform>, e.g. desktop-console. Can also be set to all to set all versions. The manual parameters above take precedence over this parameter. 틀:Templatedata

Notes

  • If a page name (first unnamed parameter) is specified and the resulting exclusivity information is all platforms (e.g. due to manual overriding), an {{all versions}} is automatically put on the page.
  • The exclusivity information is stored to the Exclusive Cargo table, which is used as a base for querying the information. This storage only happens on this main wiki (not on language wikis), only if the page is in mainspace, and only if neither $section nor $nocat are set to a positive value.

Examples

Manual versions

Code Result
{{exclusive|desktop=yes}}
Desktop only.png
Desktop-Only Content: This information applies only to the 모듈:Exclusive and Desktop only.png version of Terraria.
{{exclusive|mobile=yes|3ds=yes}}
Mobile only.png3DS.svg
Mobile/3DS-Only Content: This information applies only to the 모듈:ExclusiveDesktop only.pngMobile only.png, and 3DS.svg versions of Terraria.
{{exclusive|japan=yes|mobile=yes|3ds=yes}}
틀:Japanese console 아이콘 Mobile only.png3DS.svg
Japanese console/Mobile/3DS-Only Content: This information applies only to the Mobile only.png3DS.svg틀:Japanese console 아이콘Mobile only.png, and 3DS.svg versions of Terraria.
{{exclusive|desktop=yes|3ds=yes|console=yes}}
Desktop only.pngConsole only.png3DS.svg
Desktop/Console/3DS-Only Content: This information applies only to the Mobile only.png3DS.svgDesktop only.pngConsole only.png, and 3DS.svg versions of Terraria.
{{exclusive|desktop=yes|3ds=yes|console=yes|section=yes}}
Desktop only.pngConsole only.png3DS.svg
Desktop/Console/3DS-Only Content: This section's information applies only to the Console only.png3DS.svgDesktop only.pngConsole only.png, and 3DS.svg versions of Terraria.

Versions based on another page

Code Result
{{exclusive|1.3.0.1}}
Desktop only.pngConsole only.pngMobile only.png
Desktop/Console/Mobile-Only Content: This information applies only to the Console only.png3DS.svgDesktop only.pngConsole only.png, and Mobile only.png versions of Terraria.
{{exclusive|1.3.0.1#Features and Mechanics}}
Desktop only.pngConsole only.pngMobile only.png
Desktop/Console/Mobile-Only Content: This information applies only to the Console only.pngMobile only.pngDesktop only.pngConsole only.png, and Mobile only.png versions of Terraria.
{{exclusive|1.3.0.1|invert=y}}
틀:Old-gen console 아이콘 3DS.svg
Old-gen console/3DS-Only Content: This information applies only to the Console only.pngMobile only.png틀:Old-gen console 아이콘, and 3DS.svg versions of Terraria.
{{exclusive|1.3.0.1|not=1.4.0.1}}
{{exclusive|1.3.0.1|3ds=y}}
Desktop only.pngConsole only.pngMobile only.png3DS.svg
Desktop/Console/Mobile/3DS-Only Content: This information applies only to the 틀:Old-gen console 아이콘3DS.svgDesktop only.pngConsole only.pngMobile only.png, and 3DS.svg versions of Terraria.
{{exclusive|1.3.0.1|3ds=y|dsk=n}}
Console only.pngMobile only.png3DS.svg
Console/Mobile/3DS-Only Content: This information applies only to the Mobile only.png3DS.svgConsole only.pngMobile only.png, and 3DS.svg versions of Terraria.
{{exclusive|1.3.0.1|invert=y|dsk=y}}
Desktop only.png 틀:Old-gen console 아이콘 3DS.svg
Desktop/Old-gen console/3DS-Only Content: This information applies only to the Mobile only.png3DS.svgDesktop only.png틀:Old-gen console 아이콘, and 3DS.svg versions of Terraria.