/crop_planner

Stardew Valley Crop Planner

Primary LanguageJavaScriptMIT LicenseMIT

Stardew Valley Crop Planner

A tool for planning crop schedules in the Stardew Valley game.

####Live version on github.io

Reddit thread


Crop Info

Crop info is stored in config.json. This data is retrieved from game files in [install dir]/Content/Data/, specifically Crops.xnb and ObjectInformation.xnb. I use XNBNode by Draivin to decompress these files and parse them with a Python script to save into the config.json file.


Item Prices

All items have a base price which the game uses to calculate the sell price (when you ship items) and buy price (when you buy items from stores) of that item. Buy price is simply Base Price * 2.

The calculation for sell price of an item (without added Profession bonuses) is below. The Quality of an item is used numerically as a multiplier: 0 for regular; 1 for silver; 2 for gold.

(int) Sell Price = Base Price * (1 + (Quality * 0.25))

Note: some items have sell/buy prices that deviate from the above formulas. These prices are likely hard-coded into the game.


Profit-per-day

Crop profits-per-day are calculated using the minimum sell price of a crop.
Profit per day: ((Total Yields * Sells For) - (Seed Price * Total Plantings)) / (Final Harvest Date - 1)

Example 1 - Parsnip
Parsnips take 4 days to grow after the day they are planted. In Spring, they can be planted 6 times and yield a total of 6 Parsnips, assuming replanting occurs on the same day of harvesting. The last harvest occurs on Day 25. Seeds cost 20g, and Parsnips sell for a minimum of 35g.

((6 * 35g) - (20g * 6)) / (25 - 1)
90g / 24
= 3.75g/day

Example 2 - Corn
Corn takes 14 days to grow after the day it is planted. In Spring and Fall, it is planted once and can yield a total of 11 Corn. The last harvest occurs on Day 55. Seeds cost 150g, and Corn sells for a minimum of 50g.

((11 * 50g) - (150g * 1)) / (55 - 1)
400g / 54
= 7.4g/day

March 19th, 2016 - Project Reuploading

Due to an error on GitHub, I unfortunately had to delete this repository and recreate it. All previous watches, stars, and forks will have been lost. There aren't any more issues now, so feel free to watch/star/fork the project again. The github.io page itself was unaffected by this.

Thank you for your support.