Difference between revisions of "Template:Infobox"
Jump to navigation
Jump to search
Margotbean (talk | contribs) (show fruit, veg, wheat, hops, honey artisan goods in 2 columns) |
Margotbean (talk | contribs) (Show tiller profession prices in 2nd column, next to base prices (if only profession = tiller)) |
||
Line 76: | Line 76: | ||
|{{{edibility}}} | |{{{edibility}}} | ||
|{{Edibility|{{{edibility|0}}}|quality={{{quality|true}}}|iridium={{{iridium|}}} }} }} }} | |{{Edibility|{{{edibility|0}}}|quality={{{quality|true}}}|iridium={{{iridium|}}} }} }} }} | ||
− | }}{{#ifeq:{{#arrayprint:qualities to show}}|normal||{{#if:{{{profession|{{{type|}}}}}}|<nowiki/> | + | }} |
+ | {{#ifeq:{{lc:{{{profession|}}}}} | tiller | ||
+ | |<!-- Tiller Profession only --> | ||
+ | {{!}}- | ||
+ | {{!}}colspan="4" id="infoboxsection" style="text-align:center;"{{!}}Sell Prices | ||
+ | {{!}}- | ||
+ | {{!}}id="infoboxsection"{{!}}Base Price: | ||
+ | {{!}}id="infoboxsection"{{!}}[[File:Tiller.png|24px|link=]] Tiller Profession<br />''(+10% Sell Price)'' | ||
+ | {{!}}- | ||
+ | <!-- Base Prices --> | ||
+ | {{!}}id="infoboxdetail"{{!}}{{#if:{{{sellprice|}}} | ||
+ | | {{#iferror:{{#expr:{{{sellprice|0}}}>0}} | ||
+ | | {{{sellprice|}}} | ||
+ | | {{#ifeq:{{#arrayprint:qualities to show}}|normal | ||
+ | | {{price|{{{sellprice|0}}}}} | ||
+ | | {{Qualityprice|{{{name|{{PAGENAME}}}}}|{{{sellprice|}}}|{{#if:{{{iridium|}}}|iridium=true|}}|hide={{#arrayprint:qualities to hide}} }} | ||
+ | }} | ||
+ | }} | ||
+ | <!-- Tiller Profession Prices --> | ||
+ | {{!}}id="infoboxdetail"{{!}}{{#ifeq:{{#arrayprint:qualities to show}}|normal | ||
+ | | {{price| {{#expr:trunc({{{sellprice|0}}}*(1.1))}} }} | ||
+ | | {{Qualityprice|{{{name|{{PAGENAME}}}}}|{{#expr:trunc({{{sellprice|0}}}*(1.1))}}|{{#if:{{{iridium|}}}|iridium=true|}}|hide={{#arrayprint:qualities to hide}} }} | ||
+ | }} | ||
+ | }} | ||
+ | <!-- Other than just Tiller profession --> | ||
+ | |{{#ifeq:{{#arrayprint:qualities to show}}|normal||{{#if:{{{profession|{{{type|}}}}}}|<nowiki/> | ||
{{!}}- | {{!}}- | ||
{{!}}colspan=2 id="infoboxsection" style="text-align:center;"{{!}}Sell Prices | {{!}}colspan=2 id="infoboxsection" style="text-align:center;"{{!}}Sell Prices | ||
}}}} | }}}} | ||
− | + | {{!}}- | |
− | + | {{!}}id="infoboxsection"{{!}}{{#ifeq:{{#arrayprint:qualities to show}}|normal | |
|Sell Price: | |Sell Price: | ||
|{{#if:{{{profession|}}}|Base Price:|Sell Price:}} | |{{#if:{{{profession|}}}|Base Price:|Sell Price:}} | ||
− | + | }} | |
− | + | {{!}}id="infoboxdetail"{{!}}{{#if:{{{sellprice|}}} | |
| {{#iferror:{{#expr:{{{sellprice|0}}}>0}} | | {{#iferror:{{#expr:{{{sellprice|0}}}>0}} | ||
| {{{sellprice|}}} | | {{{sellprice|}}} | ||
Line 110: | Line 135: | ||
}}}}<nowiki/> | }}}}<nowiki/> | ||
{{!}}- | {{!}}- | ||
− | {{!}}id="infoboxsection"{{!}}{{#ifexist:File:{{ucfirst:@@@}}.png|{{#switch:{{ucfirst:@@@}}|Tapper=[[File:Tapper Icon.png|24px|link=]]|Blacksmith=[[File:Blacksmith Icon.png|24px|link=]]|Angler=[[File:Angler Icon.png|24px|link=]]|#default=[[File:{{ucfirst:@@@}}.png|24px|link=]]}}|}} @@@ Profession:''<br /><span style="white-space: nowrap; padding-right: 5px;">(+{{#expr:{{#arrayprint:prof_mod}} *100}}% Sell Price)''</span> | + | {{!}}id="infoboxsection"{{!}}{{#ifexist:File:{{ucfirst:@@@}}.png|{{#switch:{{ucfirst:@@@}}|Tapper=[[File:Tapper Icon.png|24px|link=]]|Blacksmith=[[File:Blacksmith Icon.png|24px|link=]]|Angler=[[File:Angler Icon.png|24px|link=]]|#default=[[File:{{ucfirst:@@@}}.png|24px|link=]]}}|}} {{ucfirst:@@@}} Profession:''<br /><span style="white-space: nowrap; padding-right: 5px;">(+{{#expr:{{#arrayprint:prof_mod}} *100}}% Sell Price)''</span> |
{{!}}id="infoboxdetail"{{!}}{{#ifeq:{{#arrayprint:qualities to show}}|normal | {{!}}id="infoboxdetail"{{!}}{{#ifeq:{{#arrayprint:qualities to show}}|normal | ||
| {{price| {{#expr:trunc({{{sellprice|0}}}*(1+{{#arrayprint:prof_mod}}))}} }} | | {{price| {{#expr:trunc({{{sellprice|0}}}*(1+{{#arrayprint:prof_mod}}))}} }} | ||
Line 117: | Line 142: | ||
}} | }} | ||
}} | }} | ||
+ | }}<!-- end if tiller only --> | ||
{{#switch:{{lc:{{{type|{{PAGENAME}}}}}}} | {{#switch:{{lc:{{{type|{{PAGENAME}}}}}}} | ||
|fruit|fruits|vegetable|vegetables|wheat|hops|honey= | |fruit|fruits|vegetable|vegetables|wheat|hops|honey= |
Revision as of 19:53, 22 April 2017
Under Construction This article or section is under construction. It may be in the process of an expansion or major restructuring. Last edited by Margotbean on 2017-04-22 19:53:26. |
==Description==
This template displays a generic infobox for a wide variety of items. Do not use this on your user page. It is reserved for content pages.
Parameters
All parameters are optional. If omitted, nothing will display.
Parameter | Notes |
---|---|
eng | Name of the image to display, in English, without the ".png" extension. If the image has an extension other than ".png", then the "ext" parameter must be used. |
ext | Extension of image specified in "eng" parameter, without the period (e.g., "gif", "jpg", etc.) |
name | Name of item (Page name if omitted) For use on pages like Trash (item) where the name of the item is different from the page name. |
image2 image3 image4 image5 |
Name of additional images to display Must be of type ".png" Omit the extension (e.g., Tiger Slime Egg) |
image2spacing | Set to "true" to add extra space between the images specified in "eng" and "image2" |
description | In-game item description (Populated by Template:Description if omitted). It is preferable to omit this parameter and update Template:Description instead. |
source | How to obtain the item (e.g., [[Crafting]], [[Artisan Goods]], [[Slime Egg-Press]]) |
location | Location(s) of item (e.g., [[Cindersap Forest]], [[The Beach]], Bushes throughout the valley, etc.) |
seed | Name of seed (e.g., {{Name|Corn Seeds}}) |
growth | Number of days the crop takes to grow to maturity (e.g., 4 days) |
buff | Name of buff(s) given by the item (e.g., {{Name|Farming|+4}}) |
buffduration | Length of time buff(s) are active |
season | Name of season when the item can be obtained or grown Can be plain text (e.g., Spring, Summer, All, etc.) or can use Template:Season (e.g., {{Season|Summer}} • {{Season|Winter}}) |
weather | Weather required to obtain the item Can use plain text (e.g., Rain) and this template will automatically apply Template:Weather inline formatting |
xp | Experience points gained for harvesting or otherwise obtaining the item |
edibility | Found in Data\ObjectInformation.xnb Note that inedible items have an edibility of -300, and poisonous items have a negative edibility greater than -300 |
sellprice | Found in Data\ObjectInformation.xnb If the item cannot be sold, then "N/A" and "Cannot be sold" are valid values |
quality | Set to "false" to suppress silver, gold, and iridium qualities |
recipe | How to obtain the recipe to craft the item (e.g., [[Farming]] Level 7) |
craftingstation | Equipment used to craft the item (e.g., {{Name|Preserves Jar}}) |
crafttime | How long does the item process in its equipment (e.g., 4 hours) |
ingredients | Ingredients needed to craft the item (e.g., {{Name|Copper Bar|2}}{{Name|Sap|10}}) |
tingredients | Ingredients with the Trapper profession Used on the Crab Pot page |
produces | Item produced via crafting, artisan goods, or harvesting (e.g., 5 Deluxe Fertilizer per craft) |