Template:Infobox food: Difference between revisions
(added "reduce_infection_power" parameter) |
mNo edit summary |
||
Line 50: | Line 50: | ||
| data22 = {{{alcohol_power|}}} | | data22 = {{{alcohol_power|}}} | ||
| label23 = Reduce infection | | label23 = Reduce infection | ||
| data23 = {{#if:{{{reduce_infection_power|}}}|{{{reduce_infection_power}}} | | data23 = {{#if:{{{reduce_infection_power|}}}|{{{reduce_infection_power}}}%}} | ||
| label24 = Packaged | | label24 = Packaged | ||
| data24 = {{{packaged|}}} | | data24 = {{{packaged|}}} | ||
| class_name = {{{class_name|}}} | | class_name = {{{class_name|}}} | ||
}}</includeonly><noinclude>{{Documentation}}[[Category:Infobox]]</noinclude> | }}</includeonly><noinclude>{{Documentation}}[[Category:Infobox]]</noinclude> |
Revision as of 11:38, 24 July 2018
This template is used to create an infobox in an article about food items.
Usage
To use this template in an article, copy the template below, then paste the template into an article.
All parameters are optional – those you do not populate with data will not show up in the infobox when the article is saved.
It is strongly advised to only include variables that are relevant to the specific item in question, i.e. parameters that do not display as false or 0 (excluding nutrition values).
{{Infobox food |name = |image= |image_width= |alternate_image= |alternate_name= |alternate_link= |alternate_image2= |alternate_name2= |alternate_link2= |alternate_image3= |alternate_name3= |alternate_link3= |alternate_image4= |alternate_name4= |alternate_link4= |alternate_image5= |alternate_name5= |alternate_link5= |alternate_image6= |alternate_name6= |alternate_link6= |alternate_image7= |alternate_name7= |alternate_link7= |alternate_image8= |alternate_name8= |alternate_link8= |alternate_image9= |alternate_name9= |alternate_link9= |alternate_image10= |alternate_name10= |alternate_link10= |alternate_image11= |alternate_name11= |alternate_link11= |alternate_image12= |alternate_name12= |alternate_link12= |alternate_image13= |alternate_name13= |alternate_link13= |alternate_image14= |alternate_name14= |alternate_link14= |alternate_image15= |alternate_name15= |alternate_link15= |alternate_image16= |alternate_name16= |alternate_link16= <!--GENERAL--> |category= |weight= |function= |max_units= |days_fresh= |days_rotten= |cant_be_frozen= |packaged= <!--NUTRITION--> |hunger_change= |thirst_change= |calories= |lipids= |proteins= |carbohydrates= <!--EFFECT--> |unhappy_change= |boredom_change= |stress_change= |fatigue_change= |endurance_change= |flu_change= |pain_change= |sick_change= |reduce_infection_power= |alcohol_power= |poison_power= <!--COOKING--> |cook_minutes= |burn_minutes= |dangerous_uncooked= |bad_microwaved= |good_hot= |bad_cold= |spice= <!--TECHNICAL DETAILS--> |item_id = }}
Parameters
Heading/Image
- display_name
- The display name of the item as it appears in-game. Leaving blank will display the pagename.
- name_colour
- The background colour for the display name. Codes can be found at Template:Infobox nc.
- name_text_colour
- The text colour for the display name. Codes can be found at Template:Infobox nc.
- image
- An image of the icon displayed at 128px by default. An image of the static model should be used if available.
- image_width
- Customise the width of the
image
. - alternate_image
- An alternate image displayed at 32px. Can be an empty, packaged, open or any other variant.
- alternate_name
- The name of the alternate item image. Leaving blank will display no name when the image is hovered over.
- alternate_link
- An optional link to the alternate image page. Leaving blank will have no link.
General
- weight
- The base weight of the item.
- category
- The in-game category the item is displayed in in the inventory.
- function
- What the item is used for. Can usually be removed if the item isn't considered a tool by the wiki. (remove if value is empty)
- max_units
- The maximum units in a full item. Calculated using the "UseDelta" value:
1 / UseDelta
. - packaged
- Whether this item is considered to be "packaged", displaying the item's nutritional values. (remove if value is false)
- cant_be_frozen
- Whether this item can be frozen, delaying time before the food rots. (remove if value is false)
- days_fresh
- The amount of days this item is recognised as "fresh". The unit "days" is appended after the value. This value can be taken from
DaysFresh
in the scripts file. (remove if value is empty) - days_rotten
- The amount of days before this item is recognised as "rotten". The unit "days" is appended after the value. This value can be taken from
DaysTotallyRotten
in the scripts file. (remove if value is empty)
Nutritional values
- hunger_change
- The value of hunger that is changed from using/consuming this item. (remove if value is empty)
- thirst_change
- The value of thirst that is changed from using/consuming this item. (remove if value is empty)
- calories
- The value of calories.
- lipids
- The value of lipids.
- proteins
- The value of proteins.
- carbohydrates
- The value of carbohydrates.
Effect
- unhappy_change
- The value of unhappiness that is changed from using/consuming this item. (remove if value is empty)
- boredom_change
- The value of boredom that is changed from using/consuming this item. (remove if value is empty)
- stress_change
- The value of stress that is changed from using/consuming this item. (remove if value is empty)
- fatigue_change
- The value of fatigue that is changed from using/consuming this item. (remove if value is empty)
- endurance_change
- The value of endurance that is changed from using/consuming this item. (remove if value is empty)
- flu_change
- The value of flu/cold that is changed from using/consuming this item. (remove if value is empty)
- pain_change
- The value of pain that is changed from using/consuming this item. (remove if value is empty)
- sick_change
- The value of sickness that is changed from using/consuming this item. (remove if value is empty)
- reduce_infection_power
- How much the item reduces wound infection. (remove if value is empty)
- alcohol_power
- The alcohol power of this item when used on wounds. (remove if value is empty)
- poison_power
- The value of poison power attached to this item. (remove if value is empty)
Cooking
- cook_minutes
- How long it takes before this item is "cooked". The unit "minutes" is appended after the value. (remove if value is empty)
- burn_minutes
- How long it takes before this item is "burnt". The unit "minutes" is appended after the value. (remove if value is empty)
- dangerous_uncooked
- Whether this item is dangerous if it is consumed before cooking it. (remove if value is false)
- bad_microwaved
- Whether this item is of a poorer quality if it is cooked in a microwave. (remove if value is false)
- good_hot
- Whether this item is of a superior quality if it is consumed hot. (remove if value is false)
- bad_cold
- Whether this item is of a poorer quality if it is consumed cold. (remove if value is false)
- spice
- Whether this item is considered a "spice" in cooking recipes. (remove if value is false)
Technical details
- class_name
- The item's 'Item ID'.
Examples
Hot Cuppa infobox
{{Infobox food |name =Hot Cuppa |image=MugBlue_Model.png |image_width=220px |alternate_image=MugFulll.png |alternate_name=Hot Drink |alternate_link= |weight=0.5 |category=Food |hunger_change=-5 |thirst_change=-50 |calories=4 |lipids=0 |proteins=0.12 |carbohydrates=0.75 |unhappy_change=-5 |stress_change=-10 |fatigue_change=-5 |cant_be_frozen=True |item_id =Base.Mugfull }}
Pot of Soup infobox
{{Infobox food |name =Pot of Soup |image=CookingPot_Model.png |image_width=160px |alternate_image=PotFull.png |alternate_name=Pot of Soup |alternate_link=Pot of Soup |weight=4 |category=Food |hunger_change=-30 |thirst_change=-30 |calories=202 |carbohydrates = 25 |proteins = 14 |lipids = 4.5 |unhappy_change=-20 |cook_minutes=50 |burn_minutes=100 |days_fresh=3 |days_rotten=5 |item_id =Base.PotOfSoup }}
Lollipop infobox
{{Infobox food |name =Lollipop |image=Lollipop_Model.png |image_width=150px |alternate_image=Lollipop.png |alternate_name=Lollipop |alternate_link=Lollipop |alternate_image2=CandyPackagei.png |alternate_name2=Candy Package |alternate_link2=Candy Package |weight=0.1 |category=Food |hunger_change=-5 |unhappy_change=-10 |calories=40 |carbohydrates = 10 |proteins = 0 |lipids = 0.5 |item_id =Base.Lollipop }}
Meat Patty infobox
{{Infobox food |name =Meat Patty |image=MeatPatty__Model.png |image_width=150px |alternate_image=MeatPatty.png |alternate_name=Meat Patty |alternate_link= |alternate_image2=MeatPattyRotten.png |alternate_name2=Meat Patty (Rotten) |alternate_link2= |alternate_image3=Cookedmeatpatty.png |alternate_name3=Meat Patty (Cooked) |alternate_link3= |alternate_image4=Burnedmeatpatty.png |alternate_name4=Meat Patty (Burnt) |alternate_link4= |weight=0.3 |category=Food |hunger_change=-40 |calories=380 |carbohydrates = 0 |proteins = 26 |lipids = 30 |cook_minutes=50 |burn_minutes=70 |bad_microwaved=True |good_hot=True |bad_cold=True |days_fresh=2 |days_rotten=4 |item_id =Base.MeatPatty }}
Bourbon infobox
{{Infobox food |name =Bourbon |image=WhiskeyBottle_Model.png |image_width=200px |alternate_image=WhiskeyFull.png |alternate_link=Bourbon |alternate_name=Bourbon |alternate_image2=WhiskeyEmpty.png |alternate_link2=Water Bottle (Bourbon) |alternate_name2=Empty Bottle |weight=0.7 |category=Food |packaged_True |cant_be_frozen=True |hunger_change=-20 |thirst_change=-20 |calories=1500 |carbohydrates = 0 |proteins = 0 |lipids = 0 |unhappy_change=-10 |alcohol_power=2 |item_id =Base.WhiskeyFull }}
Bleach infobox
{{Infobox food |name =Bleach |image=Bleach_Model.png |image_width=200px |alternate_image=Bleach.png |alternate_name=Bleach |alternate_link= |alternate_image2=Bleach.png |alternate_name2=Empty Bleach Bottle |alternate_link2= |weight=0.3<br>Empty: 0.1 |category=Household |thirst_change=-60 |unhappy_change=99 |poison_power=120 |use_for_poison=38 |item_id =Base.Bleach }}
Editors can experiment in this template's sandbox (create)