This wiki is a read-only version of the Stardew Valley Wiki. The official editable wiki maintained by ConcernedApe can be found at stardewvalleywiki.com

Modding talk:Crop data

From Stardew Valley Wiki
Jump to: navigation, search
This talk page is for discussing Modding:Crop data.
  • Sign and date your posts by typing four tildes (~~~~).
  • Put new text below old text.
  • Be polite.
  • Assume good faith.
  • Don't delete discussions.

Crop harvest data change?

Just read the Crop.cs and found that as of 1.4, the extra harvest seems to change to the following:

if (this.minHarvest > 1 || this.maxHarvest > 1)
				{
					int max_harvest_increase = 0;
					if (this.maxHarvestIncreasePerFarmingLevel.Value > 0)
					{
						max_harvest_increase = Game1.player.FarmingLevel / this.maxHarvestIncreasePerFarmingLevel;
					}
					numToHarvest = r2.Next(this.minHarvest, Math.Max(this.minHarvest + 1, this.maxHarvest + 1 + max_harvest_increase));
				}

the numToHarvest use "max" instead of "min", which means that the farm level may affect the number to harvest. Fblthp (talk) 05:24, 6 January 2019

update, tested using a save editor, it seems the farminglevel still somehow does not affect the number of harvest for rice, even if its maxHarvestIncreasePerFarmingLevel is 10 in raw data. Fblthp (talk) 06:10, 6 January 2019
This was a confusing change for me too. But it's covered in the Version History page, where it says "Added changes for modders." At the bottom of the modding wishlist, under "Medium Changes", it says "☑ Fix reharvestable crops always dropping the min number of items, instead of a random number between the min and max values. (Stardew Valley 1.4 also adjusts the crop data so the end result for vanilla crops matches the 1.3.36 behavior.)" --margotbean (talk) 14:55, 6 January 2020 (UTC)