Plantilla:Time
Ir a la navegación
Ir a la búsqueda
Documentation The documentation below is transcluded from Plantilla:Time/doc. (edit | history)
[purge]
This template is used to include a time in a standardized, localized format, exactly as it is displayed by watches and their upgrades in-game. It also supports ticks as input and will convert them according to Terraria's source code.
Usage
{{ time | <time to display> | ticks = <time in ticks> | day = y/yes/n/no }}
- First unnamed parameter
Time to display. This can be in any format recognized by the {{#time:}} parser function (i.e. any valid PHP strtotime() input), such as 19:45:33 or noon.
- ticks and day
Time representation as in the source code, i.e. the float and the bool Terraria.Main.time. Terraria.Main.dayTime defaults to false, but should always be specified for clarity. The first unnamed parameter always overwrites these two parameters.
$day
Examples
| Code | Result |
|---|---|
{{time|20:00}} |
8:00 P. M. |
{{lang/set|es}}{{time|20:00}} |
Set language to Spanish 8:00 P. M. |
{{lang/set|fr}}{{time|20:00}} |
Set language to French 8:00 après-midi |
{{lang/set|pl}}{{time|20:00}} |
Set language to Polish 8:00 PM |
{{lang/set|ru}}{{time|20:00}} |
Set language to Russian 8:00 вечера |
{{lang/set|zh}}{{time|20:00}} |
Set language to Chinese 8:00 下午 |
{{time|ticks=48972|day=y}} |
6:06 PM |
{{time|ticks=6485.8023|day=n}} |
9:18 PM |