As part of the Unified Community Platform project, your wiki will be migrated to the new platform in the next few weeks. Read more here.

Szablon:Value

Z Terraria Wiki
Skocz do: nawigacja, szukaj

Template for showing prices. Correctly fits inside a sentence or bullet lists.

Usage[edytuj kod]

{{value
| platinum
| gold
| silver
| copper
| [[link = {{yes/'''no'''}}]]
| [[text = {{yes/'''no'''}}]]
}}
{{value|platinum|gold|silver|copper|option1|option2}}

Notes[edytuj kod]

  • Values of "0", "" or null are not displayed.
  • The values can also be a range.
  • The template is inside a nowrap.
This Gives
{{Value|1}} 1 Platinum Coin.png
{{Value|0|1}} 1 Gold Coin.png
{{Value|0|0|1|}} 1 Silver Coin.png
{{Value|0|0|0|1}} 1 Copper Coin.png
{{Value|1|2|0|4}} 1 Platinum Coin.png 2 Gold Coin.png 4 Copper Coin.png

Inside a sentence:

Further Options[edytuj kod]

There are two optional option fields:

  • "link" specifies wether you want to link to the icon page. "yes" means there are links. "no" means there are no links. Anything else, or blank, will use the template's current default of "no"
    • It is recommended to use links for the first use of the template in a page, but not afterwards.
  • "text" option allows specifying wether the values are icons, or raw text. "yes" means text will be used. "no" means icons will be used. Anything else, or blank, will use the template's current default of "no" (use icons).
This Gives
{{Value|0|1|1|link=yes}} 1 Gold Coin.png 1 Silver Coin.png
{{Value|0|1|1|text=yes}} 1 Gold 1 Silver
{{Value|0|1|1|link=yes|text=yes}} 1 Gold 1 Silver

zh-cn:模板:Value