##Preface
Since there doesn’t really seem to be a lot of documentation on what all we can do, and I assume we’re all just reading through code and figuring it out on our own. I thought it would be a good idea to have a collection of collective knowledge posts that are 1/2 tutorial, 1/2 list of available ‘options’ that are available for us to use.
The first one I decided to tackle was the abilities file associated with each job/class. I tried to make this as easy to read as possible, and obviously everything here is how I interpreted each one works by looking though code, and what I have observed in the game. I implore anyone to expand on and correct the information listed here. I combined the list by reading through the abilities file of each job.
##Abilities File
A JSON file typically named [JobName]_abilities.json, and stored in [ModName]\jobs\[JobName]\[JobName]_abilities, and called in [JobName]_description.json.
worker_abilities.json example:
{ "type": "entity", "components" : { "stonehearth:equipment_piece" : { "injected_ai" : { "actions" : [ "stonehearth:actions:light_firepit" ], "ai_packs" : [ "stonehearth:ai_pack:mining", "stonehearth:ai_pack:place_item", "stonehearth:ai_pack:construction", "stonehearth:ai_pack:ladders", "stonehearth:ai_pack:town_alert", "stonehearth:ai_pack:wimpy", "stonehearth:ai_pack:panic", "stonehearth:ai_pack:panic:flee", "stonehearth:ai_pack:panic:cower" ] } } }, "entity_data" : { "stonehearth:panic_threshold" : 0.75 } }
We’ll break these down into 3 main sections:
- actions
- ai_packs
- entity_data
#Actions
filters:fabricate_wooden_structure
Seems it might be redundant to AI Packs->Construction because it is present in Carpenter, but not Mason or Worker. Appears to allow the multiple types of wood to be used for construction, just not sure why only the carpenter has it. See here for more discussion.
filters:teardown_wooden_structure
Same notes as fabricate_wooden_structure.
light_firepit
Character can bring a piece of wood to a fire pit and set it on fire.
ai Packs
backpack
Allows use of the character’s backpack.
combat_control
Can hold a position, and wait.
construction
Can build and tear down structures.
crafting
Required for any job that crafts items.
farming
Allows all farming actions.
healing
Can heal a sleeping character.
healing_combat
Can heal a character in combat.
ladders
Can build and tear down ladders.
mining
Can mine and dig foundation during construction.
panic
Should be declared on non-combat classes, character will fight to the death if not declared.
panic:flee
Always declared, allows character to flee when the threshold is met.
panic:cower
Should be declared on non-combat classes, allows character to cower when unable to flee.
patrolling
Allows character to patrol, patrol in a party, and walk in formation with party.
place_item
Can move entities.
ranged_combat
Allows character to attack from a distance, ie: Archer.
repairing
Allows character to repair entities that have ai_pack:repairable_item. (Also See: Entity Data->combat:siege_repair_data)
shepherding
Allows all shepherding actions.
town_alert
Should be declared on non combat classes, causes character to run to a safety point and stay there when a town alert is activated, if not assigned to militia.
trapping
Allows trapping actions.
wimpy
Avoids threatening entities.
##Entity Data
combat:melee_defenses - Set melee defense paramaters.
Example from Footman:
"stonehearth:combat:melee_defenses": [ { "name": "combat_1h_dodge", "effect": "combat_1h_dodge", "active_frame": 8, "cooldown": 12000, "priority": 1, "chance_of_success": 0.25, "defense_attribute": "dodge_chance" } ]
combat:melee_attacks - sets melee attack type paramaters. (Only found it in trapper, paramaters were empty)
combat:siege_repair_data - I can’t find where this is actually put to use, I assume it points to a coming feature.
@Oldra - allows the person to replace traps and turrets that have expended their use(s).
Example from Engineer
"stonehearth:combat:siege_repair_data": { "can_repair": true }
panic_threshold
- A number <1, the higher it is, the quicker the character will run from combat.
- Defaults to 0.5 if not set.
- Determines when the character should panic in combat.
- Whenever that character gets hit, the observer checks to see if their hitpoints are below their panic threshold.
- If their health/max_health is <= threshold, the stonehearth.combat service will record that the entity is panicking from the person who lowered their HP to below the threshold, and cause them to flee/cower.