Template:Servebox: Difference between revisions
(Created for infoboxes on service buildings' pages) |
m (added category; added deprecated at top) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
<includeonly>{{#invoke: Servebox| | <includeonly>{{#invoke: Servebox|renderServebox | ||
| name= {{{name| {{{1|}}} }}} | | name= {{{name| {{{1|}}} }}} | ||
}}</includeonly><noinclude> | }}</includeonly><noinclude> | ||
{{c|Red|'''IMPORTANT''' This template is now deprecated. Please use [[Template:Buildingbox]] instead.}} | |||
<hr /><br /><br /><br /> | |||
{{Servebox|name=Market}} | {{Servebox|name=Market}} | ||
Line 45: | Line 49: | ||
{{Servebox|name=Monastery}} | {{Servebox|name=Monastery}} | ||
</noinclude> | |||
[[Category:Templates/Deprecated]]</noinclude> |
Latest revision as of 04:07, 2 October 2024
IMPORTANT This template is now deprecated. Please use Template:Buildingbox instead.
Lua error in Module:Servebox at line 151: attempt to call field 'getAllDataForInstitution' (a nil value).
Servebox is a template that creates an infobox on the page by displaying data provided by template parameters and loading data from the data template Template:Institutions_csv. The infobox to the right on this page is an example.
Overview
This template should be used for all Service Buildings on the wiki, that is, buildings that provide services through consumable items. The template requires only the name
parameter, which tells the code behind the scenes which building you want an infobox for.
Parameters
Only the first, name
is required, and it must be spelled correctly to match the in-game name of the building.
Parameter | Type | Description |
---|---|---|
name | string | Required. The in-game name of the building for which you want to display the infobox. Will also serve as the header of the box. |
Errors
When the template is called without a name, the template reminds you that it is required.
Example:
{{Servebox}}
Yields:
You must specify the name of the service building. See Template:Servebox for examples.
When providing the name of a building, it is important that it is spelled correctly, including any punctuation. Otherwise, an error will return from the data module.
Example:
Broken: {{Servebox|name=Monestary}}
Lua error in Module:Servebox at line 151: attempt to call field 'getAllDataForInstitution' (a nil value).
Fixed: {{Servebox|name=Monastery}}
Lua error in Module:Servebox at line 151: attempt to call field 'getAllDataForInstitution' (a nil value).