Difference between revisions of "Template:Qualityprice"

From Stardew Valley Wiki
Jump to navigation Jump to search
m (Unfortunately it sorts alphabetically instead of numerically so I'm going to try putting a space between the number and g.)
(Nope, this is the best I can do. it goes 100, 200, 30, 300, 40, 50, 500, etc. If you guys can figure out how to sort it by a number value instead, or try to manipulate it so it reads the amount of digits or something, be my guest.)
Line 1: Line 1:
 
<includeonly><div class="qualitycontainerprice">
 
<includeonly><div class="qualitycontainerprice">
 
<table>
 
<table>
<td>{{{2|}}} g</td>
+
<td>{{{2|}}}g</td>
 
<td>[[File:{{{1|}}}.png|16px|link=]]<br></td>
 
<td>[[File:{{{1|}}}.png|16px|link=]]<br></td>
<tr><td>{{#expr:floor({{{2|}}}*1.25) round 0}} g</td>
+
<tr><td>{{#expr:floor({{{2|}}}*1.25) round 0}}g</td>
 
<td><div id="qualityprice">[[File:{{{1|}}}.png|16px|link=]][[File:Silver_Quality_Icon.png|16px|link=]]</div></td></tr>
 
<td><div id="qualityprice">[[File:{{{1|}}}.png|16px|link=]][[File:Silver_Quality_Icon.png|16px|link=]]</div></td></tr>
<tr><td>{{#expr:floor({{{2|}}}*1.50) round 0}} g</td>
+
<tr><td>{{#expr:floor({{{2|}}}*1.50) round 0}}g</td>
 
<td><div id="qualityprice">[[File:{{{1|}}}.png|16px|link=]][[File:Gold_Quality_Icon.png|16px|link=]]</div></td></tr></table></div></includeonly><noinclude>{{{{FULLPAGENAME}}/doc}}</noinclude>
 
<td><div id="qualityprice">[[File:{{{1|}}}.png|16px|link=]][[File:Gold_Quality_Icon.png|16px|link=]]</div></td></tr></table></div></includeonly><noinclude>{{{{FULLPAGENAME}}/doc}}</noinclude>

Revision as of 07:12, 10 March 2016

Description

This template displays prices for items of specified qualities, formatted appropriately for the language where they appear. The image of the item is included (with any quality stars) instead of the gold icon. The size of the image is always 24px.

Parameters

Parameter Notes
First (unnamed) parameter Name of image (minus ".png")
Second (unnamed) parameter Normal/base sell price of item (can be found in ObjectInformation.xnb)
or
Normal/base sell price of item used to make Artisan Good (see examples below)
Note: also accepts non-numbers such as "3x base fruit price" without throwing an error
quality Single quality to display.
Defaults to all qualities (normal, silver, gold, iridium) if omitted.
Items that exist in normal quality only do not have to specify quality=normal (i.e., Cave Carrot, Ginger, Green Tea, Honey, Jelly, Juice, Oil, Pickles, Qi Fruit, and Tea Leaves)
Note: Other items may be added in the future. In the meantime, specifying quality=normal will work.
hide Qualities to hide
(e.g., hide=silver,gold)
pm Profession modifier
Tiller gives a 10% bonus, so specify pm=1.1
Angler gives a 50% bonus, so specify pm=1.5
etc.
dsv data-sort-value
Set to false if the quality price(s) are displayed in a non-sortable structure (like an infobox)
Default value is true (the entire parameter can be omitted if a data-sort-value is desired).

Examples

Template Call Result
{{Qualityprice|Melon|250}}
250g Melon.png
312g
Melon.pngSilver Quality Icon.png
375g
Melon.pngGold Quality Icon.png
{{Qualityprice|Parsnip|35|pm=1.1}}
35g Parsnip.png
43g
Parsnip.pngSilver Quality Icon.png
52g
Parsnip.pngGold Quality Icon.png
{{Qualityprice|Ginger|60}}
60g Ginger.png
75g
Ginger.pngSilver Quality Icon.png
90g
Ginger.pngGold Quality Icon.png
{{Qualityprice|Goat Cheese|400|hide=normal,silver}}
400g Goat Cheese.png
500g
Goat Cheese.pngSilver Quality Icon.png
600g
Goat Cheese.pngGold Quality Icon.png
{{Qualityprice|Large Goat Milk FR|345}}
345g Large Goat Milk FR.png
431g
Large Goat Milk FR.pngSilver Quality Icon.png
517g
Large Goat Milk FR.pngGold Quality Icon.png
{{Qualityprice|Juice|260}}
(The base sell price of Red Cabbage is 260,
and the base sell price of Red Cabbage Juice is 585)
260g Juice.png
325g
Juice.pngSilver Quality Icon.png
390g
Juice.pngGold Quality Icon.png
{{Qualityprice|Wine|750|pm=1.4}}
(The base sell price of Starfruit is 750,
and the Artisan base sell price of Starfruit Wine is 3,150)
750g Wine.png
937g
Wine.pngSilver Quality Icon.png
1125g
Wine.pngGold Quality Icon.png
{{Qualityprice|Honey|30}}
(The base sell price of a Tulip is 30,
and the base sell price of Tulip Honey is 160)
30g Honey.png
37g
Honey.pngSilver Quality Icon.png
45g
Honey.pngGold Quality Icon.png