0 of 0

File information

Last updated

Original upload

Created by

Tomokisan

Uploaded by

Tomokisan1

Virus scan

Safe to use

About this mod

Allow mod developers to easily add blessings from statues of blessings through json files and/or C#.

Requirements
Permissions and credits
Changelogs
Donations
Allow mod developers to easily add blessings from statues of blessings.

You just need to create a content pack (see : https://stardewvalleywiki.com/Modding:Content_packs) for this mod containing a assets/blessings.json file.

There is a sample :




Documentation :

The configuration consist of an associative array of key -> subarray in the JSON format.

key of the array
  • The id of the custom blessing

Type
  • One of this : "simple", "custom" or "both"
  • "simple" : Apply the effects in "Effects" array
  • "custom" : Call the method in "CustomMethod" and that's all
  • "both": Apply the effects in "Effects" array + Call the method in "CustomMethod"

DisplayName
  • The default name of the blessing if there is no translation for it (see below how translation work)

Description
  • The default description of the blessing if there is no translation for it (see below how translation work)

CustomMethod
  • The custom method to call if "Type" = custom or both in form of "<full type name>: <method name>", else leave it empty

The following parameters are passed to the method : 

  • StardewValley.Object currentStatue -> The current used statue object
  • Farmer who -> The Farmer object
  • GameLocation location -> The location object
  • Dictionary<string, float> blessingEffects -> The array of effects of the json configuration in the "Effects" key


Here is an example of custom method : 





  • The method could return a Buff object or null as you want/need, if you return a Buff object it will be applied as is, if you return null a Buff object will be built using json configuration (with effects if Type = "both", without effects if Type = "custom") 

CustomTexture
  • true or false : define if you will use your own image for the blessing or one of the default one (see TileSheets/BuffsIcons.png on the game datas)

IconTexture
  • Relative path to your png asset used as custom texture for this blessing, used if "CustomTexture" = true, else leave it empty

IconSpriteIndex
  • Index of the sprite on the tilesheet if you use default texture tilesheet (if "CustomTexture" = false), else leave it at -1


Mimic
  • This one let you reuse a native blessing, simply type the name of a native blessing (statue_of_blessings_X, X = 0-6) it will apply it and ignore others configuration, if you don't need it leave it empty
    This key exist because when you use the framework, except if there is an error loading your config (in that case it will fallback to the native behavior and blessings), it will overwrite the defaults blessings

Effects
  • The list of effects to be applied in this blessing if "Type" = simple or both, you can use a negative number to set a debuff

There is a list of all currently supported effects :




Explanation of each effect :


Spoiler:  
Show

"FarmingLevel" => The level of Farming of the player
"FishingLevel" => The level of Fishing of the player
"MiningLevel" => The level of Mining of the player
"LuckLevel" => The level of Luck of the player
"ForagingLevel" => The level of Foraging of the player
"MaxStamina" => The maximum stamina amount of the player
"MagneticRadius" => The radius around the player that attract items on the ground (like monsters loots or wood when you chop a tree)
"Speed" => The movement speed of the player
"Defense" => The defense of the player, better defense means less HP loss when damages occur
"Attack" => The attack of the player
"CombatLevel" => The level of Combat of the player
"Immunity" => It's the player resistance to negative effects
"AttackMultiplier" => A multiplier applied to the attack power of the player
"KnockbackMultiplier" => A multiplier applied to the knockback monsters endure when hit by the player
"WeaponSpeedMultiplier" => A multiplier applied to the player's weapon swing speed
"CriticalChanceMultiplier" => A multiplier applied to the player's critical hit chance
"CriticalPowerMultiplier" => A multiplier applied to the player's critical hit damage
"WeaponPrecisionMultiplier" => A multiplier applied to the player's weapon accuracy.
"MaxHealth" => The maximum health points of the player
"RegenHealth" => Amount of life points regen/lost each second
"RegenStamina" => Amount of stamina points regen/lost each second


You can set only the effects you need, they aren't all required.

Note : The custom blessing (Buff) will have an in in-game id as follow : statue_of_blessings_c_X, where X = the key in the array, except if you use a custom method that return a Buff object, in that case you are responsible to set it's id.

Translation :

The translation configuration consist of an associative array of key (the key must correspond to the key of the blessing you want to translate in the blessings.json file) -> language code -> subarray in the JSON format.

The file must be next to the blessings.json and be named translate.json, there is a sample :



I give you in files section a content pack sample.

Note : Each content pack is taken into account and all json are "merged", but if a key is in common, the one used is the key from the content pack loaded the most lately.

This mod is compatible with my other mod : Better Statue Of Blessings


My mods : 
SWAPI - Stardew Valley Web API : Let your game send events to a custom web server.
highRollerSlots : Add possibility to bet more in slots machines.
geodeCrusherPlus : Add ability to geode crusher to crush any geode, including mysteryboxes, Artifact Trove and golden coconuts.
TV Shopping channel : Add a TV shopping channel.
Prize Machine Custom Prizes : Let you easily fully customize the prize list of Prize Machine.
Better Statue Of Blessings : Allow you to get one blessing by statue per day instead of only one blessing per day.
Custom Blessings Framework : Allow mod developers to easily add blessings from statues of blessings.
Custom Wake Up Time : Let you configure the wake up time for each day.
Anti Tool Exhaustion : Prevent you to become exhausted from an accidental tool use.