Template:Item/Food/Category/doc
From Vintage Story Wiki
< Template:Item | Food | Category
Revision as of 15:56, 11 December 2023 by Nyuhnyash (talk | contribs) (Created page with "<noinclude><languages /></noinclude> <templatedata> { "params": { "1": { "label": "Food category id", "example": "protein", "default": "unknown", "required": true, "description": "case-insensitive", "type": "string" } }, "description": "Returns food category name by it's id. Support translations." } </templatedata> == Usage == <pre>{{Item/Food/Category|category id}}</pre> === Examples === {| class="wikitable" |+ Allowed food category ids |- !...")
Returns food category name by it's id. Support translations.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Food category id | 1 | case-insensitive
| String | required |
Usage
{{Item/Food/Category|category id}}
Examples
id | Code | Result |
---|---|---|
fruit | {{Item/Food/Category|fruit}} |
Fruit |
vegetable | {{Item/Food/Category|vegetable}} |
Vegetable |
grain | {{Item/Food/Category|grain}} |
Grain |
protein | {{Item/Food/Category|protein}} |
Protein |
grain | {{Item/Food/Category|grain}} |
Grain |
dairy | {{Item/Food/Category|dairy}} |
Dairy |
nonutrition | {{Item/Food/Category|nonutrition}} |
No nutrition |
unknown | {{Item/Food/Category|unknown}} |
Unknown |