Villager random stats question


Is there a way to tell the game to make starting villagers with custom stats and not random?


i’m assuming you mean via a mod, in which case I am (fairly) sure that’s possible… perhaps some of our modding elite can chime in on where you can locate villager stats… :+1:


However it could be done, it’s just sad to get a 1,2,1 or even 1,1,1 and they face a goblin/zombie and p0of! sometimes even with others helping, would like to tell the game nothing below 3,3,3 or the like.


I think they should make it so nothing generates with less than 10 or 9points combined that means you could still end up getting a 6,2,1 or 6,3,1


Even that would be ok :smile:


Go to your Steam files to Stonehearth/mods, rename the stonehearth.smod to and unpack it in the same folder, so that you have a folder “stonehearth” instead the “stonehearth.smod” in the mods folder.

After that, go to “mods/stonehearth/mixins/base_human” and open “base_human.json” with any text-editor.
Now search for mind and you will find the following code:

  "stonehearth:attributes" : {
     "mind": {
        "type" : "random_range",
        "base" : 1,
        "max"  : 6

Here you can change the start-values in range (base = min, max = max). If you want your villagers to have constant values, just use the same value for base and max. Just do the same for the other values and you’re done.

Save the file and start Stonehearth again and your new villagers will be the mediaeval space marines :smiley:


Thank you! worked great!


I like this idea, but I would also want a “max number” as well, so like the addition of stats must be between 7 and 15, that way you don’t just have a guy who is the best at everything.


Not sure I understand what your suggesting, max setting is 6 for each of the 3 stats “mind” “body” and “spirit”, the configuration default is “base” : 1 “max” : 6, by altering the base to 3 each of the villagers spawning are all random within that limitation of 3 to 6, so a villager can spawn with a score of 3,3,3, at the minimum.

Are you saying the total of the 3?


yea we were both talking about the total of the three

to me the stats are something that they improve by making them go up when a villiger levels up as for not having a max 15 would be fine sense 18 is the most so max would be 6,6,3 that only allows 2 excellent stats and one moderate 7 would be the bare minimum I would want for the minimum so lowest you could get it 3,2,2


That’s a bit more tricky… :S
So download these files and copy/overwrite them to the following paths:
base_human.json: as before into "mods/stonehearth/mixins/base_human"
attributes_component.luac: as before into “mods/stonehearth/components/attributes”

If you start a new game, the sum of the 3 Main-Attributes (mind, body, spirit) will be in range between 7 and 15.
If you still want a bigger minimum for one of the attributes, you can change it in the new base_human.json, as shown above.

Have fun!

PS: These files are hardcoded, so they may not work in future versions of the game!


Thanks for the guidance :smiley:


this currently is not working anymore, any new idea’s?


This mod will work if you check the “randomize hearthling stats” setting. Go to Settings -> Gameplay and there will be a checkbox



yeahh it worked :slight_smile: Will this also change the stats of every new villager or only the starting ones?