A Wiki in the Desert
Log in

Difference between revisions of "Template:BuildCost"

From A Wiki in the Desert
m
m
Line 1: Line 1:
<includeonly>{{#vardefine:count|{{trim | {{{1}}} }}}}{{#vardefine:base|{{trim | {{{2}}} }}}}{{#arraydefine:p|{{trim|{{{3|}}}}}|unique, sort=desc}}{{#subobject:|count={{#var:count}} |buildcost={{#var:base}} |verified={{{verified|false}}} |buildcost_property={{#arrayprint:p}}|+sep=}}{{#ifeq:{{{verified|}}}|true|{{#var:count}} [[{{#var:base}}]]{{#ifexpr: {{#arraysize:p}} > 0|&nbsp;-&nbsp;}}{{#arrayprint:p}} <v/>|{{#var:count}} [[{{#var:base}}]]{{#ifexpr: {{#arraysize:p}} > 0|&nbsp;-&nbsp;}}{{#arrayprint:p}} <uv/>}}</includeonly><noinclude><templatedata>
+
<includeonly>{{#set: buildcost=Technology/{{trim|{{{1}}}}}/{{trim|{{{2}}}}}|{{trim|{{{1}}}}} {{trim|{{{2}}}}} (Technology)}}</includeonly><noinclude><templatedata>
 
{
 
{
 
"params": {
 
"params": {
 
"1": {
 
"1": {
"label": "Number",
+
"label": "Technology",
"description": "The number of this item that is required",
+
"description": "Name of the technology",
"example": "1",
+
"example": "Knapping",
"type": "number",
+
"type": "string",
 
"required": true
 
"required": true
 
},
 
},
 
"2": {
 
"2": {
"label": "Item",
+
"label": "Level",
"description": "The base item that is required.",
+
"description": "Level of the required technology",
"example": "Treated Board",
+
"example": "1",
 +
"type": "number",
 
"required": true
 
"required": true
},
 
"3": {
 
"label": "Properties",
 
"description": "The properties of the required item",
 
"example": "Black"
 
},
 
"verified": {
 
"label": "Verified",
 
"description": "If the requirement has been verified or not",
 
"example": "false",
 
"type": "boolean",
 
"default": "false",
 
"suggested": true
 
 
}
 
}
 
},
 
},
"description": "Defines a number of items as being a requirement of the object described by the page."
+
"description": "Adds a requirement on a specific technology at a certain level."
}
+
}</templatedata></noinclude>
</templatedata></noinclude>
 

Revision as of 12:00, 3 June 2023

Adds a requirement on a specific technology at a certain level.

Template parameters

ParameterDescriptionTypeStatus
Technology1

Name of the technology

Example
Knapping
Stringrequired
Level2

Level of the required technology

Example
1
Numberrequired