Template:Version: Difference between revisions

From Official Barotrauma Wiki
Jump to: navigation, search
mNo edit summary
mNo edit summary
Line 21: Line 21:
|style="width:{{#if:{{{spoiler|}}}|5|10}}%; padding-left:0; padding-right:0;{{#if:{{{spoiler|}}}|border-left: 1px solid #303436}}" rowspan="2"|[[File:{{#ifeq:{{#var:match}}|Legacy|icon-outdated-bt|Version Checkmark {{#var:match}}}}.png|60px]]
|style="width:{{#if:{{{spoiler|}}}|5|10}}%; padding-left:0; padding-right:0;{{#if:{{{spoiler|}}}|border-left: 1px solid #303436}}" rowspan="2"|[[File:{{#ifeq:{{#var:match}}|Legacy|icon-outdated-bt|Version Checkmark {{#var:match}}}}.png|60px]]
|style="width:{{#if:{{{spoiler|}}}|45|90}}%; padding:0; border-bottom: 1px solid #303436"|<big>'''{{#switch:{{#var:match}}|True=Data is up-to-date|Legacy=This page is a [[Version History/Legacy|Legacy]] article|False=Data is potentially outdated}}'''</big>
|style="width:{{#if:{{{spoiler|}}}|45|90}}%; padding:0; border-bottom: 1px solid #303436"|<big>'''{{#switch:{{#var:match}}|True=Data is up-to-date|Legacy=This page is a [[Version History/Legacy|Legacy]] article|False=Data is potentially outdated}}'''</big>
{{#if:{{{toc|}}}|{{!}}rowspan="2"{{!}}__TOC__}}
|-
|-
{{#if:{{{spoiler|}}}|{{!}}style="padding:0{{!}}''Do not read {{#if:{{{spoilersection|}}}| [[{{FULLPAGENAME}}#{{{spoilersection|}}}{{!}}{{{spoilersection|}}}]]|this page}} if you don't want to be spoiled.''}}
{{#if:{{{spoiler|}}}|{{!}}style="padding:0{{!}}''Do not read {{#if:{{{spoilersection|}}}| [[{{FULLPAGENAME}}#{{{spoilersection|}}}{{!}}{{{spoilersection|}}}]]|this page}} if you don't want to be spoiled.''}}
Line 51: Line 50:
| cleanup = {{{cleanup|}}}
| cleanup = {{{cleanup|}}}
| cleanupnote = {{{cleanupnote|}}}
| cleanupnote = {{{cleanupnote|}}}
}}}}</includeonly></onlyinclude>
}}}}{{#if:{{{toc|}}}|{{!}}rowspan="2"{{!}}__TOC__}}</includeonly></onlyinclude>

Revision as of 06:23, 14 July 2022

Documentation

This template is used to easily keep track of page content versions, as well as other flags. It should be placed at the very start of an article.


All of the collected information can be found in the Page Status template.


All parameters are optional.
If using 'delete', 'stub', or 'cleanup', "yes" must be added after an "=" sign, otherwise it might be interpreted as an "anonymous parameter". See examples below.


This template searches changelogs using the FindInChangelog template, to see if the page name has been mentioned in a newer version than the page was last updated for. If it wasn't, the page is considered up to date, even if the page version is lower than current game version. Configuration details in the table below.


Field Note Example Default
1 Version
  • If the page version is equal to current game version, it's considered up to date.
  • If the page version is lower than current game version, but it's name or keywords have only been found in an older changelog, it's considered up to date.
  • If the page version is lower than current game version, and it's name or keywords have been found in a more recent changelog, it's considered outdated.
  • If the page version is lower than current game version, and it's name or keywords have not been found in any changelog:
    • Above 1.0.0.0: It's considered up to date.
    • Under 1.0.0.0: It's considered outdated, instead of up to date.
  • If the page version equals 0.8.2.3, it's considered a legacy article.
1.0.7.0
2 Note Outdated images.
stub Is the article a stub yes
stubnote Note regarding stub status Add more content, images.
cleanup Is the article marked for cleanup yes
cleanupnote Note regarding cleanup status Page layout is hard to follow.
deletion Is the article marked for deletion yes
deletionnote Note regarding deletion status Duplicate page.
search Adds additional keywords to search for in changelogs (Example for Structures page) Wreck,Thalamus,Beacon,Outpost,Ruin
nosearch Disables search functionality. Page will default to outdated unless it's exactly at the current game version yes
debug Displays debug info yes
name Overrides the pagename that the template searches for in the changelogs. For debug/demonstration usage. screwdriver
{{PAGENAME}}

Syntax

{{Version|<version number>|<what is outdated?>|deletion=yes|deletionnote=<why should the page be deleted?>|stub=yes|stubnote=<what needs to be added?>|cleanup=yes|cleanupnote=<what needs to be improved?>}}

Examples


{{Version}} gives:

Data is potentially outdated
Last updated for an unknown version
The current game version is 1.2.8.0

{{Version|0.10.0.0|Outdated images.}} gives:

Data is potentially outdated
Last updated for version 0.10.0.0
The current game version is 1.2.8.0
Notes: Outdated Images

{{Version|1.2.8.0|Partially outdated images.}} gives:

Data is up-to-date
Last updated for version 1.2.8.0
The current game version is 1.2.8.0
Notes: Partially outdated images

{{Version|deletion=yes|deletionnote=Duplicate page.}} gives:

Data is potentially outdated
Last updated for an unknown version
The current game version is 1.2.8.0

{{Version|0.8.2.3}} gives:

This page is a Legacy article
Features described on this page are no longer in the game.

{{Version|1.0.7.0|name=Screwdriver}} gives:

Data is potentially outdated
Last updated for version 1.0.7.0
The current game version is 1.2.8.0

{{Version|1.0.7.0|name=Mudraptor}} gives:

Data is potentially outdated
Last updated for version 1.0.7.0
The current game version is 1.2.8.0

{{Version|1.1.18.0|name=Mudraptor}} gives:

Data is potentially outdated
Last updated for version 1.1.18.0
The current game version is 1.2.8.0

{{Version|0.20.16.1|name=I Am That Guy|debug=y|nosearch=y}} gives:

Data is potentially outdated
Last updated for version 0.20.16.1
The current game version is 1.2.8.0

{{Version|1.0.0.0|name=PageNameNotInChangelogs|search=search1,search2,search3,traitors|debug=y}} gives:

Data is potentially outdated
Last updated for version 1.0.0.0
The current game version is 1.2.8.0

This template defines the table "PageStatus". View table.