TalentDef - Grim-/Talented GitHub Wiki
TalentDefs define what bonuses a character receives when spending talent points. These are referenced by UpgradeTreeNodes to determine what upgrades are available at each point in the talent tree.

<Talented.TalentDef>
<defName>ArmorUpgrade</defName>
<label>Enhanced Defense</label>
<description>Improves overall armor effectiveness by 5%.</description>
<levelRequired>4</levelRequired>
<statEffects>
<li>
<statDef>ArmorRating_Sharp</statDef>
<value>1.05</value>
<operation>Add</operation>
</li>
<li>
<statDef>ArmorRating_Blunt</statDef>
<value>1.05</value>
<operation>Add</operation>
</li>
</statEffects>
</Talented.TalentDef>You can define three types of effects in your upgrades:
Allows for modification of a Pawns stats, this includes custom (modded) stats.
Add health conditions or modifications to the character. Useful for adding straight stat buffs, health conditions, or other effects that are normally applied through hediffs.
Grant new abilities to the character. If you want your upgrade to give the character new abilities (like psycasts), use this.
Add or modify organs. Use this when you want to give characters new organs or modify existing ones. Can be used for both simple organ additions and complex modifications.
-
defName: Unique identifier for your upgrade -
label: What shows up in the UI -
levelRequired: Minimum parasite level needed for this upgrade - At least one effect type (hediff, ability, or organ)
-
prerequisites: Other upgrades that must be taken first -
uiIconPath: Custom icon for the upgrade -
pointCost: How many talent points it costs (defaults to 1) -
description: Custom description (if not provided, one will be generated based on the effects)
The description will automatically list what hediffs, abilities, or organs are being added unless you provide a custom one.
You can have an upgrade grant the character either a stat increase, a hediff, a specific organ or an ability.
Stat Upgrade
<Talented.TalentDef>
<defName>ArmorUpgrade</defName>
<label>Enhanced Defense</label>
<description>Improves overall armor effectiveness by 5%.</description>
<levelRequired>4</levelRequired>
<statEffects>
<li>
<statDef>ArmorRating_Sharp</statDef>
<value>1.05</value>
<operation>Add</operation>
</li>
</statEffects>
</Talented.TalentDef>Hediff Upgrade
<?xml version="1.0" encoding="utf-8" ?>
<Defs>
<!-- Auxiliary Heart -->
<Talented.TalentDef>
<defName>AuxiliaryHeartUpgrade</defName>
<label>Auxiliary Heart</label>
<uiIconPath>DragonBall1</uiIconPath>
<description>Grows an additional heart to improve blood circulation and stamina.</description>
<levelRequired>4</levelRequired>
<organEffects>
<li>
<addedOrganHediff>AuxiliaryHeart</addedOrganHediff>
<isAddition>true</isAddition>
</li>
</organEffects>
</Talented.TalentDef>
<HediffDef ParentName="ImplantHediffBase">
<defName>AuxiliaryHeart</defName>
<label>auxiliary heart</label>
<description>An additional parasitic heart has grown to support the circulatory system.</description>
<defaultLabelColor>(0.5, 0.8, 0.5)</defaultLabelColor>
<addedPartProps>
<solid>true</solid>
<partEfficiency>1.0</partEfficiency>
<betterThanNatural>true</betterThanNatural>
</addedPartProps>
<stages>
<li>
<statOffsets>
<MoveSpeed>0.15</MoveSpeed>
<WorkSpeedGlobal>0.1</WorkSpeedGlobal>
</statOffsets>
<capMods>
<li>
<capacity>BloodPumping</capacity>
<offset>0.5</offset>
</li>
</capMods>
</li>
</stages>
</HediffDef>
</Defs>
AbilityUpgrade
<Talented.TalentDef>
<defName>ShadowStrikeUpgrade</defName>
<label>Shadow Strike</label>
<description>Grants the ability to briefly become invisible and perform a powerful strike.</description>
<levelRequired>4</levelRequired>
<abilityEffects>
<li>
<abilities>
<li>
<abilityDef>ShadowStrikeAbility</abilityDef>
</li>
</abilities>
</li>
</abilityEffects>
</Talented.TalentDef>
<AbilityDef>
<defName>ShadowStrikeAbility</defName>
<label>shadow strike</label>
<description>Briefly become invisible and gain bonus damage on your next attack.</description>
<iconPath>Abilities/ShadowStrike</iconPath>
<targetRequired>False</targetRequired>
<verbProperties>
<verbClass>Verb_CastAbility</verbClass>
</verbProperties>
</AbilityDef>