Hans Lemurson
Prince
So, I've been searching a while to see if anybody had figured out the Civ6 combat formula and, finding nothing, I took it upon myself to have fun with spreadsheets so you don't have to.
I have long suspected that the damage formula was Exponential in nature, given that the relative Power of units is based on their difference in strength rather than the ratio. But to actually test this I needed to gather a LOT of combat data from various unit-strength pairings in order get a large enough data set to yield believable answers. I would need to record the data from each and every combat in my game, minimizing after every battle so I could enter the data in a spreadsheet before I forgot what the message said. And do that 100 times. BOOORING!!!!.
Say hello to my little friend here: Documents/My Games/Sid Meier's Civilization VI/Logs/CombatLog.csv
And with that, I was off to the races.
A little bit of spreadsheet manipulation and...
Yep, looks exponential to me.
Also noteworthy is the fairly large variance, but also that it appears to be directly proportional to the amount of damage dealt, flaring out like a trumpet as the damage increases. This suggests that there is a simple random multiplier to the final damage. Judging by eyeball, the upper limit seems to be 125% and the lower limit 75%.
I tried to use clean and easy to understand numbers, and I arrived at this approximate formula for what each unit does to each other in combat:
Damage = 30 * e^(StrengthDifference / 25) * Random(0.75, 1.25)
The base damage is 30, doubles every ~17 strength, and then gets a +/-(0-25)% damage bonus/penalty.
The random factor is applied to each unit independently.
I might be wrong about the magnitude of the Random Factor, and may not have gotten the exponent exactly right (and I wish I could have converted it into more intuitive numbers), but this is probably close enough to get a picture of what's going on.
For the purposes of "rules of thumb" I will make a chart for the expected damage at various intervals.
From these bonuses, we can see what we already knew: Combat strength differences are only relevant from 0-30, after that it's all 1-hit kills.
+10 is a good solid bonus where you deal 150% damage and take only 67%.
An easier to use formula might be: 30 * 1.041^StrengthDifference
(since only nerds like me know that e = 2.71828)
I have added the CombatLog.csv file that I used as my source of data.
I have long suspected that the damage formula was Exponential in nature, given that the relative Power of units is based on their difference in strength rather than the ratio. But to actually test this I needed to gather a LOT of combat data from various unit-strength pairings in order get a large enough data set to yield believable answers. I would need to record the data from each and every combat in my game, minimizing after every battle so I could enter the data in a spreadsheet before I forgot what the message said. And do that 100 times. BOOORING!!!!.
Say hello to my little friend here: Documents/My Games/Sid Meier's Civilization VI/Logs/CombatLog.csv
And with that, I was off to the races.
A little bit of spreadsheet manipulation and...
Yep, looks exponential to me.
Also noteworthy is the fairly large variance, but also that it appears to be directly proportional to the amount of damage dealt, flaring out like a trumpet as the damage increases. This suggests that there is a simple random multiplier to the final damage. Judging by eyeball, the upper limit seems to be 125% and the lower limit 75%.
I tried to use clean and easy to understand numbers, and I arrived at this approximate formula for what each unit does to each other in combat:
Damage = 30 * e^(StrengthDifference / 25) * Random(0.75, 1.25)
The base damage is 30, doubles every ~17 strength, and then gets a +/-(0-25)% damage bonus/penalty.
The random factor is applied to each unit independently.
I might be wrong about the magnitude of the Random Factor, and may not have gotten the exponent exactly right (and I wish I could have converted it into more intuitive numbers), but this is probably close enough to get a picture of what's going on.
For the purposes of "rules of thumb" I will make a chart for the expected damage at various intervals.
Code:
+0 30 30 1.00x
+1 31 29 1.04x
+3 34 27 1.13x
+5 36 25 1.22x
+10 45 20 1.49x
+17 59 15 1.97x
+30 99 10 3.32x
+10 is a good solid bonus where you deal 150% damage and take only 67%.
An easier to use formula might be: 30 * 1.041^StrengthDifference
(since only nerds like me know that e = 2.71828)
I have added the CombatLog.csv file that I used as my source of data.
Attachments
Last edited: