Effidian
Recruit
Since we have our own forum now and this file is getting asked about more and more, I figured I'd separate the info from the attackable peasants thread for easy reference.
Here is a complete entry from troops.txt:
Disecting this into separate lines:
borcha = name
Borcha = text
Borcha = text (don't know what the difference between the two are)
528 = unit flags
393304 = location
0 = unit flags2
1 = faction (although this doesn't seem to matter much)
unit flags have the following bits:
0-3: Unit type (0 = male, 1 = female, 2 = undead)
4: Hero
5: Inactive
6: Unkillable
7: Always die
8: Can't capture
9: Shielded
10: mounted (used for movement speed calculation)
11: ranged item required (will get a ranged weapon from item list)
16-23: 2nd upgrade option (index in troops.txt)
24-31: 1st upgrade option (index in troops.txt)
location has the following bits and is used to place an NPC in a town:
0-15: index in sites.txt
16-23: unique number for that site
unit flags2
0-3: Merchant Type (1 = horse, 2 = weapon, 3 = armor, 4 = goods)
4: force helm
5: force boots
6: force armor
7: force horse
8-15: (unused)
16-23: hire base unit (index in troops.txt)
24-31: hire party (index in parties.txt)
The equipment line consists of 64 pairs of values. The first is an index in item_kinds1.txt, the second is always 0. -1 indicates no item. In the case of troops, the equipment they get seems to be randomized from their list. Otherwise, they'd always have the same thing. Either that or they just use a random item from their equipment. Not really sure.
7 = strength
13 = agility
14 = intelligence
4 = charisma
13 = level
These will get modified based on how many points the unit would get at the specified level (but only upward). These seem to be the minimum values and may exceed what the unit would normally have for the level.
Proficiencies:
76 = one-handed
82 = two-handed
84 = polearem
77 = archery
77 = crossbow
77 = thrown
18016606659543040 = skill set 1
4194818 = skill set 2
0 = skill set 3
Set 1 and 2 sometimes have values above bit 32. I have no idea what they are for. Not including them doesn't seem to do anything.
skill set 1 is as follows:
0-3: trade
4-7: leadership
8-11: prisoner_management
12-15: first_aid
16-19: surgery
20-23: wound treatment
24-27: inventory_management
28-31: spotting
32-?: ?
skill set 2 is as follows:
0-3: pathfinding
4-7: tactics
8-11: tracking
12-15: trainer
16-19: horse_archery
20-23: riding
24-27: athletics
28-31: shield
33-?: ?
skill set 3 is as follows:
0-3: weapon master
4-7: power draw
8-11: power_throw
12-15: power_strike
16-19: ironflesh
529 = hair_start
77618924032622 = face_start
0 = hair_end
0 = face_end
Here is a complete entry from troops.txt:
Code:
borcha Borcha Borcha 528 393304 0 1
52 0 43 0 37 0 40 0 -1 0 -1 0 ....
7 13 14 4 13
76 82 84 77 77 77
18016606659543040 4194818 0
529 77618924032622 0 0
Disecting this into separate lines:
Code:
borcha Borcha Borcha 528 393304 0 1
borcha = name
Borcha = text
Borcha = text (don't know what the difference between the two are)
528 = unit flags
393304 = location
0 = unit flags2
1 = faction (although this doesn't seem to matter much)
unit flags have the following bits:
0-3: Unit type (0 = male, 1 = female, 2 = undead)
4: Hero
5: Inactive
6: Unkillable
7: Always die
8: Can't capture
9: Shielded
10: mounted (used for movement speed calculation)
11: ranged item required (will get a ranged weapon from item list)
16-23: 2nd upgrade option (index in troops.txt)
24-31: 1st upgrade option (index in troops.txt)
location has the following bits and is used to place an NPC in a town:
0-15: index in sites.txt
16-23: unique number for that site
unit flags2
0-3: Merchant Type (1 = horse, 2 = weapon, 3 = armor, 4 = goods)
4: force helm
5: force boots
6: force armor
7: force horse
8-15: (unused)
16-23: hire base unit (index in troops.txt)
24-31: hire party (index in parties.txt)
Code:
52 0 43 0 37 0 40 0 -1 0 -1 0 ....
The equipment line consists of 64 pairs of values. The first is an index in item_kinds1.txt, the second is always 0. -1 indicates no item. In the case of troops, the equipment they get seems to be randomized from their list. Otherwise, they'd always have the same thing. Either that or they just use a random item from their equipment. Not really sure.
Code:
7 13 14 4 13
7 = strength
13 = agility
14 = intelligence
4 = charisma
13 = level
These will get modified based on how many points the unit would get at the specified level (but only upward). These seem to be the minimum values and may exceed what the unit would normally have for the level.
Code:
76 82 84 77 77 77
Proficiencies:
76 = one-handed
82 = two-handed
84 = polearem
77 = archery
77 = crossbow
77 = thrown
Code:
18016606659543040 4194818 0
18016606659543040 = skill set 1
4194818 = skill set 2
0 = skill set 3
Set 1 and 2 sometimes have values above bit 32. I have no idea what they are for. Not including them doesn't seem to do anything.
skill set 1 is as follows:
0-3: trade
4-7: leadership
8-11: prisoner_management
12-15: first_aid
16-19: surgery
20-23: wound treatment
24-27: inventory_management
28-31: spotting
32-?: ?
skill set 2 is as follows:
0-3: pathfinding
4-7: tactics
8-11: tracking
12-15: trainer
16-19: horse_archery
20-23: riding
24-27: athletics
28-31: shield
33-?: ?
skill set 3 is as follows:
0-3: weapon master
4-7: power draw
8-11: power_throw
12-15: power_strike
16-19: ironflesh
Code:
529 77618924032622 0 0
529 = hair_start
77618924032622 = face_start
0 = hair_end
0 = face_end