Stardew Valley

File information

Last updated

Original upload

Created by

pepoluan

Uploaded by

pepoluan

Virus scan

Safe to use

About this mod

Customize your own Silo Size! Also, daily report on how many hay you've stored in your silo!

Requirements
Permissions and credits
Translations
  • Russian
Changelogs
Donations
Silo size mods already made are either (1) hardcoded new silo size to a huge number that I don't like, or (2) does not provide enough granularity to modify the silo size due to how they work.

This mod changes the per-silo size instead. By default (configurable through config.json) it will set the size to 1000, but of course you can change it to, say, 123456, or 420, or 6969, or whatever size you want.

(You'll have to edit the file manually; due to how this mod patches the game [see Technical Details below] it is unable to change the silo size without restarting the game, so there's no point in making a Mod Config Menu for this.)


Technical Details

This mod does its job by patching 3 places in the game code:
  • Farm.tryToAddHay -- this is the actual limiter of silo size
  • Buildings.Building.doAction -- this provides report of (total hay / max hay) when right-clicking on a silo, and
  • Object.checkForAction -- this affects the Farm Computer device
To the best of my knowledge, none of the existing silo resizer mods do this.

This patching happened before the game started, and the patches are designed to be as non-intrusive as possible, to greatly reduce the chances of conflicting with other mods that want to patch the above methods.

Because of this, it is not possible to change the Silo Size value while the game is running; you'll have to exit and restart the game.


Installation - Main Mod

To install:
  • Make sure you have the latest SMAPI
  • Download the newest "SiloSize" zip file from the 'Files' tab
  • Extract the mod into the Mods directory as usual
  • Run the game once, and exit before loading a savegame
  • Edit the config.json to your liking


Installation - Content Patcher content pack

Also provided in the 'Files' tab is a zip file named "SiloSizeOnTV" ; it is Content Patcher content pack to 'correct' the description for the silo in the "Living off the Land" show. This is optional, you do NOT have to install this, at all.

To install:
  • Make sure you have the latest Content Patcher
  • Download the newest "SiloSizeOnTV" zip file from the 'Files' tab
  • Extract the mod into the Mods directory as usual
  • Done.


The "SiloSizeOnTV" content pack does NOT have any customization; since version 0.1.0 it automatically pulls the values it needs from the main mod.


Customization - config.json

This mod provides several knob to customize:
  • SiloSize -- sets the size of each silo. Must be an integer greater than 0 and less than 2,147,483,648
  • MorningReport -- if true, then each morning you will be told how many hay sheaves are stored in the silo(es). Report will only appear if you have one or more silo(es); if you don't have any silo, the report will not appear.

(config.json will be created with default values after you (1) install the mod, and (2) start the game once -- no need to load a save.)

Support for "Generic Mod Config Menu" will NOT be added, please don't ask for that.



Source Code

Source code is available on SourceForge; it is released under the MPL-2.0 license.