[DONE] Soldier ranks give bonuses
Soldier ranks available as variables for accuracy, damage bonus, regeneration and all other instances where other soldier stats (like strength, health, healthCurrent etc.) are available as variables.
- type: STR_KNUCKLES
damageBonus:
# strength: 0.6
# melee: 0.2
rank: [0.0, 10.0] # 10*rank^2
fatalWounds: [10.0, 2.0]
PS: also added number of fatal wounds as possible parameter
[DONE] Unhardcode rank system
Allow setting how many of lower rank are needed for higher rank to appear.
soldiersPerSergeant: 5
soldiersPerCaptain: 11
soldiersPerColonel: 23
soldiersPerCommander: 30
Also allow to set % monthly wages bonus depending on rank.
- type: STR_SOLDIER_S
costBuy: 20000
costSalary: 5000 # rookie base salary 5'000
costSalarySquaddie: 5000 # squaddie salary 10'000
costSalarySergeant: 10000 # sergeant salary 15'000
costSalaryCaptain: 15000 # captain salary 20'000
costSalaryColonel: 50000 # colonel salary 55'000
costSalaryCommander: 500000 # commander salary 505'000
PS: If there are dynamic salaries, Monthly Costs GUI shows sum of all salaries of all soldier types (and cost per unit is empty)
I would like to add some bonus to soldiers depending on their rank, let's say 2 * rank for:
- some stats
- damageBonus
- meleeBonus
As I think it's not possible to mod that at soldier definition level, I could simulate that at armor definition level, given that any soldier has an armor.
For instance, is it possible to define a TU bonus for armors depending on rank?
Example:
What currently works: depending on armor type, not on rank => +10 TUWhat I try to do: - type: STR_JUMP_ARMOR_UC
...
# stats:
# tu: 10
tu:
rank: 2 #add 2*rank as a bonus
I did that for all armor types, there is no failure at startup, but when I check my soldiers stats, it does not make any change
I made an attempt with strength instead of tu, with same result
And I did not find any mod using this feature to modify stats
I probably misunderstand the possibilities and don't understand properly what is said by Meridian
