Description
3acf045f-448d-4d1b-98af-998629365724
This mod provides a framework for creating custom mounts that spawn from custom stables.
For users, just install this mod like any other mod, it will allow mods that create custom mounts to work.
Creating Custom Mounts
To start, you will need a custom building with the "BuildingType" set to "StardewValley.Buildings.Stable".
Then, you can create a custom mount to associate with that building, using Content Patcher, targetting the dictionary at "aedenthorn.CustomMounts/dict".
For example:
This associates Pinkie the big, pink horse with the Pinkie House building. When a Pinkie House is built, a Pinkie will appear next to it.
Explanation
Stable in the custom mount data should be the dictionary key from Data/Buildings for the mount's stable.
SpawnOffset is the tile offset from the top left tile of the stable on which to spawn the mount (default is 1,1).
Speed has to be an integer (vanilla is 2).
[b]EatSpeedBonus[/b] is the speed boost gained by feeding the mount its special food (vanilla is 0.4).
FrameWidth and FrameHeight are in pixels, vanilla is 32.
HatOffsets and HatScale are for mounts with different proportions than the default horse (can omit).
FluteItem and FluteSound allow for custom summon flute items (can omit).
EatItem and EatSound allow for custom "carrot" items (can omit).
CustomAnimations
The CustomAnimations field allows you to override the random grass eating animation, and optionally have sound play at certain frames.
Chance should be between 0 and 1 (=100%).
You can have multiple possible animations for each facing direction (0 = up, 1 = right, etc.), but each animation should be named differently (Right1, Right2, etc.).
Notes
There is an example content pack in the Optional FIles section.
By default, a single player can own multiple stables and mounts of different kinds. The vanilla game doesn't allow this, and I don't know why that is but if you are afraid of potential consequences, you can disable multiple mount ownership in the config. You will still be able to have multiple mounts of different kinds, but only one will belong to you (affects calling them using the flute, at the least).
The mod also allows you to rename mounts by interacting while holding down a mod key (default LeftAlt). You can change the key in the config.
Source code is at https://github.com/aedenthorn/StardewValleyMods/
This mod provides a framework for creating custom mounts that spawn from custom stables.
For users, just install this mod like any other mod, it will allow mods that create custom mounts to work.
Creating Custom Mounts
To start, you will need a custom building with the "BuildingType" set to "StardewValley.Buildings.Stable".
Then, you can create a custom mount to associate with that building, using Content Patcher, targetting the dictionary at "aedenthorn.CustomMounts/dict".
For example:
{
"Format": "2.7.0",
"Changes": [
{
"LogName": "Pinkie",
"Action": "EditData",
"Target": "aedenthorn.CustomMounts/dict",
"Entries": {
"{{ModId}}/Pinkie": {
"Name": "Pinkie",
"Stable": "{{ModId}}_PinkieHouse",
"SpawnOffset": {
"X": 2,
"Y": 3
},
"Speed": 3,
"FrameWidth": 48,
"FrameHeight": 48,
"FootstepSound": "Duggy",
"FootstepSoundStone": "hammer",
"FootstepSoundWood": "explosion",
"FluteItem": "(O)123",
"FluteSound": "drumkit0",
"EatItem": "(O)233",
"EatSound": "gulp",
"EatSpeedBonus": 0.6,
"HatScale": 1.5,
"HatOffsets": [
{
"X": 16,
"Y": -16
},
{
"X": 32,
"Y": -32
},
{
"X": 16,
"Y": 0
},
{
"X": 0,
"Y": -32
}
],
"CustomAnimations": {
"Left": {
"FacingDirection": 3,
"Chance": 0.002,
"Frames": [
{
"Frame": 21,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 22,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 23,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 24,
"Flip": true,
"SoundChance": 1,
"Sound": "harvest",
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 23,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 24,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 23,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 22,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 21,
"Flip": true,
"MinLength": 100,
"MaxLength": 100
}
]
},
"Right": {
"FacingDirection": 1,
"Chance": 0.002,
"Frames": [
{
"Frame": 21,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 22,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 23,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 24,
"SoundChance": 1,
"Sound": "harvest",
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 23,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 24,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 23,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 22,
"MinLength": 100,
"MaxLength": 100
},
{
"Frame": 21,
"MinLength": 100,
"MaxLength": 100
}
]
},
"Down": {
"FacingDirection": 2,
"Chance": 0.002,
"Frames": [
{
"Frame": 25,
"MinLength": 0,
"MaxLength": 250
},
{
"Frame": 25,
"SoundChance": 1,
"Sound": "harvest",
"MinLength": 250,
"MaxLength": 250
},
{
"Frame": 25,
"MinLength": 0,
"MaxLength": 250
}
]
}
},
"TexturePath": "{{InternalAssetKey: assets/pinkie.png}}"
}
}
},
{
"LogName": "Pinkie House",
"Action": "EditData",
"Target": "Data/Buildings",
"Entries": {
"{{ModId}}_PinkieHouse": {
"Name": "Pinkie House",
"Description": "Pinkie's stable.",
"Texture": "{{InternalAssetKey: assets/pinkie_house.png}}",
"BuildingType": "StardewValley.Buildings.Stable",
"MagicalConstruction": true,
"BuildCost": 15000,
"Size": {
"X": 6,
"Y": 3
},
"BuildMaterials": [
{
"ItemId": "(O)709",
"Amount": 100
},
{
"ItemId": "(O)335",
"Amount": 5
}
]
}
}
}
]
}
This associates Pinkie the big, pink horse with the Pinkie House building. When a Pinkie House is built, a Pinkie will appear next to it.
Explanation
Stable in the custom mount data should be the dictionary key from Data/Buildings for the mount's stable.
SpawnOffset is the tile offset from the top left tile of the stable on which to spawn the mount (default is 1,1).
Speed has to be an integer (vanilla is 2).
[b]EatSpeedBonus[/b] is the speed boost gained by feeding the mount its special food (vanilla is 0.4).
FrameWidth and FrameHeight are in pixels, vanilla is 32.
HatOffsets and HatScale are for mounts with different proportions than the default horse (can omit).
FluteItem and FluteSound allow for custom summon flute items (can omit).
EatItem and EatSound allow for custom "carrot" items (can omit).
CustomAnimations
The CustomAnimations field allows you to override the random grass eating animation, and optionally have sound play at certain frames.
Chance should be between 0 and 1 (=100%).
You can have multiple possible animations for each facing direction (0 = up, 1 = right, etc.), but each animation should be named differently (Right1, Right2, etc.).
Notes
There is an example content pack in the Optional FIles section.
By default, a single player can own multiple stables and mounts of different kinds. The vanilla game doesn't allow this, and I don't know why that is but if you are afraid of potential consequences, you can disable multiple mount ownership in the config. You will still be able to have multiple mounts of different kinds, but only one will belong to you (affects calling them using the flute, at the least).
The mod also allows you to rename mounts by interacting while holding down a mod key (default LeftAlt). You can change the key in the config.
Source code is at https://github.com/aedenthorn/StardewValleyMods/
