Beam - Hearthling Stats Customization



Steam Workshop
stonehearth_beam.smod Direct Link
GitHub Repo

Ever wanted to modify your hearthling’s stats or traits at the roster screen? Well, now you can.


  • Allows players to modify hearthling’s stats at the roster screen
  • Redistribution mode for stats, each roll resets the max stats points you can reallocate
  • Unlocked mode for attributes and traits, no restriction
  • Add and Remove Traits

Planned Features

  • Traits customization at roster screen

Compatibility Issues

  • None that are known…

Change Log
  • v0.1.0 - Initial Release
  • v0.1.1 - fixed issue with mind decrement
  • v0.2.0 - refactored code to avoid using overrides
  • v1.0.0 - added the capability to add/remove traits
    added a ‘cheatmode’ for stats
    added logic to initially allow only redistribution of stats
  • v1.0.1 - added debounce to the async command
    added attributeDistribution to client side to determine max/min values
    added trait restriction to max of 2 by default
    added passion_jobs check for incomplete data
  • v1.0.2 - added unlock traits using checkbox


Do you know if it works with ACE?


ACE should be fine.


Ok thanks I’ll give it a try later then.


Fantastic work!! Now all we need is to be able to select bunnies for all 5. :sweat_smile:


can make the same for traits?


From the OP :stuck_out_tongue:


yes please! and thanks for this, mandatory mod right away now XD

could you also put it on the workshop? that way its nice to use on multiplayer games.


Okay. Done. I added steam workshop link in the first post. I realized it would be useful since I plan to try to play stonehearth on another computer over the week. So I just did it immediately.


Thanks! Awsome job :slight_smile:


check out Box O’ Vox mod. @OwlGo did some really cool stuff to give more customization options to the roster select. We’ve been wanting to do traits for the LONGEST time! He was never able to figure out the the way traits get assigned to citizens. If you ever do get to the trait portion, I’m going to be eyeballing the sh*t out it!


I will check it out. Thanks! Sounds like I can’t go the override technique on select roster.html then. Nothing some raw JS code can’t fix. :smile:

I did look into traits briefly. I think it’s possible to add it dynamically at roster screen. We will see whenever I have time to get to it.

<div class="statsLabels">
         <div id="mind" class="stat">
            <div class="decrement arrowButton" {{action "changeIndex" "decrement" "mind" target="view"}}></div>
            <div class="statValue">{{view.model.stonehearth:attributes.attributes.mind.user_visible_value}}</div>
            <div class="whiteBlackOutline label">{{i18n}}</div>
            <div class="increment arrowButton" {{action "changeCitizenStat" "increment" "mind" target="view"}}></div>
         <div id="body" class="stat">
            <div class="decrement arrowButton" {{action "changeCitizenStat" "decrement" "body" target="view"}}></div>
            <div class="statValue">{{view.model.stonehearth:attributes.attributes.body.user_visible_value}}</div>
            <div class="whiteBlackOutline label">{{i18n}}</div>
            <div class="increment arrowButton" {{action "changeCitizenStat" "increment" "body" target="view"}}></div>
         <div id="spirit" class="stat">
            <div class="decrement arrowButton" {{action "changeCitizenStat" "decrement" "spirit" target="view"}}></div>
            <div class="statValue">{{view.model.stonehearth:attributes.attributes.spirit.user_visible_value}}</div>
            <div class="whiteBlackOutline label">{{i18n}}</div>
            <div class="increment arrowButton" {{action "changeCitizenStat" "increment" "spirit" target="view"}}></div>

I noticed the error for mind while peaking at your code. you forgot to change “changeIndex” to “changeCitizenStat” in the mind section. I like what you did. and after looking I’m sure it’s possible, but I don’t know how to code and call the traits.


Thanks! I will fix it.


I took a look at Box O’ Vox mod. With the way the UI is overridden, this won’t be capable with my mod for the time being. I’ll hack together a solution to make it work sometime later. But it won’t be a priority. I would rather get traits customization done. You can then take my code and make it work with yours or wait until I change the code to use raw JS to patch the html.

Most of my changes will appear only in the left section where you can select your hearthlings. Unless I feel like making a popup or a dialog to modify traits.

I still need to do reembarkment because I know there are some UI elements on that screen related to that. Anyone know how re-embarkment works? Do I have to finish a game? Can I trigger it through lua?


You need saved re embarkation data. I think someone can just give you a file for that so you can test with it


Either that, or you can also manually trigger the re-embark encounter to make a re-embark party. I think the encounter is called reembarkation and is in the town_progression campaign.


Thanks. I’ll use that to take a look at the embark screen.


Don’t worry about compatibility with Box O’ Vox. Traits should be more important. I can always look at whatever you do once that gets done. Since traits are in an array, Owl & I couldn’t make out how to call and change them. Also, I don’t think we were able to figure a way to mixinto our file into theirs to avoid overrides :frowning:


I am able to retrieve all the traits and hook it up with the description and all.


Yes. I am re-using the re-embark dialog. It’s just temporarily setup to see whats possible in terms of traits. Add and Removing traits is the easy part once you have all the traits.

Building out the UI will be the longest part for me. Probably get something to mess with in a few days.

I know how to do it. I’ll do it after I get traits the way I want it. It’s actually pretty easy depending on how much you want to replace/inject. But as long as you only touch the top right customization section, everything else is free to be modified/replaced.