Template:GameText/doc

This template is used to retrieve in-game text, based on the game text database which is taken from the source code.

Note: This template is relatively slow, so please use other database templates first, if possible.

Usage
The index key for the text. It is the same as in the in-game language JSON files. See examples below.
 * First unnamed parameter

Language code, defaults to lang. Currently, there are nine languages, as in-game:. All other languages will use the English database.
 * lang

Replacement for placeholders. There are two types of placeholder in the game texts:  and , indexed by   and  , respectively. See examples below.
 * All  and   parameters

By default, the template will fetch its data from the cargo database. If this parameter is set, it will query from the original game language files, stored as JSON in Lua modules. This is a bit more stable and accurate and supports returning all contents of a string array, at the cost of taking up much more resources.
 * json

Cargo
The cargo database is queried if $json is not true, i.e., by default. The following pages are used to store the data to the cargo database:

Lua (JSON)
The Lua database is queried if $json is true. It is comprised of the following modules:

de:Vorlage:GameText fr:Modèle:GameText pt:Predefinição:GameText