Stardew Valley
0 of 0

File information

Last updated

Original upload

Created by

Digus

Uploaded by

Digus

Virus scan

Safe to use

About this mod

Framework to add custom rules for producing objects. Supports code and content pack interfaces.

Requirements
Permissions and credits
Translations
  • Polish
  • French
Changelogs
Objective:
To create a simple way to add new producing rules into the game.

Installation:
  1. Install the latest version of SMAPI.
  2. Unzip the Producer Framework Mod into /Stardew Valley/Mods.

Change Log:
1.7.4
  • Fix to bouncing happening when not supposed to.
  • Fix to giving errors when machines had animations but the item supposed to be held diapered.
  • Upgrade to hamony 2 and Stardew Valley 1.5.5
  • Spanish i18n. (Thanks to bpsys)
1.7.3
  • Hungarian i18n. (Thanks to martin66789)
  • Fix to object not stacking properly when the output had a preserved type and the input also had a preservedParentIndex.
1.7.2
  • Fix incompatibility with the way translation worked before.
1.7.1
  • Fix to some output names not working properly when there is no i18n key for the name.
1.7.0
  • Animations can now be different based on the output inside the machine, identified by Name, Index or category.
  • Internationalization of output names aren't restricted to one per index anymore. Will only apply to new produced items.
  • New rule property to make the output index be replaced by the preserved parent index, so you can reverse produce items. (ex. fish from fish roe)
  • New properties to increment stats label on input and output. Status label can be any string and can be used with Mail Framework Mod.
  • New properties AdditionalProducerNames, to let rules and configs work for more than one producer name.
  • Korean i18n. (Thanks to wally232)
  • Turkish i18n. (Thanks to KeDili)
1.6.0
  • Outputs can now have restrictions for Input Stack. The required stack will be the value consumed.
  • New property compatible with Lookup Anything.
  • Fix bug when a "preserved item" parent index could not be found.
  • Fix to input stack not displaying correctly on Lookup Anything.
  • Japanese i18n. (Thanks to TwelveYO)
  • Chinese i18n. (Thanks to irischerish)
1.5.0
  • Outputs can now have restrictions for Mail and Events.
  • New API method to let SMAPI mods to load content packs directly. (Thanks to Amy Nagle)
  • Russian i18n. (Thanks to Dmitrey Kupcov)
  • New property on producer rules to let the creator define the log level that should be used to warn the player about rule conflicts.
  • New config.json file that let you change the default log level of conflict warns for all producer rules.
  • Season condition and requirement now uses the season of the location the machine is placed.
  • Performance improvement when hovering over machines, on certain occasions.
1.4.2
  • Fix to animations not working properly on Stardew Valley 1.5.
  • Fix to SubtractTimeOfDay property not working as intended.
  • Fix to light sources not starting when loading the first save.
  • Fix to animations not stopping if production was on hold because of a season, weather or time condition.
Spoiler:  
Show

For Modders to use content pack:
  • There is a template inside the mod folder with commented instructions on what each property do.
  • The same object used for the content pack is used for the methods in the framework. There should be no difference between using the method or creating a content pack.
  • There is two files for configuration. One for the rules, and another for the new producers added. The rules file cover most things, but stuff like the sprite frame that should be shown when the machine is producing or ready, should be configured per machine, not per producing rule. Vanilla machines are configured by default, but it can be changed.
  • Here is the template for the custom rules as added in the mod file(ProducerRules.json):
Spoiler:  
Show

  • Here is the template for the producers as added in the mod file (ProducersConfig.json):
Spoiler:  
Show

  • Here is the template for the config properties as added in the mod file(Config.json):
Spoiler:  
Show


For Modder to code:

  • Reference the ProducerFrameworkMod.dll on your SMAPI project.
  • Use the ProducerController class to add the rules and configs.
  • The parameters have the same properties as the template from content packs.
  • You can also call the API method "AddContentPack" with the directory where your content pack files are and they will be loaded by the mod.
Special thanks:
  • minervamaga, SpringsSong, ParadigmNomad, Trent, spacechase0 - They were directly involved on the producing of this framework.
  • Everybody at the Stardew Valley Discord #modding channel - They are all very supportive and were the inspiration for this project.

My Other Mods: