I believe the chance_to_hit formula is this:
Code:
chance_to_hit = dlf * const * 1.1 ^ (attack-defense)
It's essentialy the same as chance_to_kill, but not involving lethality (which makes sense).
Also, I think there is no separate chance_to_knockdown formula. The knockdown percentile is 1-lethality, so knockdowns happen only when the chance_to_hit is successful and the chance_to_kill is not. A dummy-formula, I guess, would be this:
Code:
chance_to_knockdown= dlf * const * (1-lethality) * 1.1 ^ (attack-defense)
The game checks for a hit (is chance_to_hit another formula?). If the test fails, it's a miss and the unit is unaffected. If the test succeeds, the defense ratings are reduced in some manner by the total value of the attack - in this case, 7. (Is there a priority of reduction? Is it split between applicable ratings? Is shield rating inviolable and never reduced?)
As it reduces the ratings by 7, the engine checks to see if the damage exceeds the remaining armor. In the above case, the attacked man would retain a defense skill of 7 and still be okay. However, say he only had 5 left, leaving a difference of 2 "extra damage." Is this when chance_to_kill is checked? Or does it only check chance_to_kill if the current total defense value is 0?
I am not certain of anything regarding this theory, and since I've not yet tested any of that, what follows is purely my assumption.
If what you describe above was the case, then in a battle with an attacker of attack power 63 and a defender of total defense 62 we would have crazy-fast battles, because whenever a single hit took place, the defender's defense would instantly drop to 0 (if capped there or else -1) and then the to_kill_chance would be like that: chance_to_kill = dlf * const * lethality * 1.1 ^ (63-0)
This would mean that 3 out of 4 successfuls hits would lead to a fatality and 63atk-VS-62def battles would be over in a matter of seconds. But even if the attack was 2 and the defense 1, we would still have the exact same chance_to_hit formula, the exact same result of the defender's defense droping to 0 (or -1), but we'd have a much smaller chance_to_kill (0.21%), which would lead to veeeery slow battles. But the duration of 63atk-VS-62def fights is the same or very close to that of 2atk-VS-1def fights, which leads me to conclude that what you describe above is not correct.
I hope my rumblings are semi-coherent and that I am making sense... If you spot a flaw in my rationale, plz correct me.
So, how I think things work:
It's been empirically observed that soldiers who are knocked-down tend to get killed a lot easier afterwards. So, a logical assumption about how things go is:
A) chance_to_hit checked. If it fails, then nothing happens. If it succeeds, then we have B.
B) chance_to_kill checked. If it succeeds, then defending soldier is killed. If it fails, then the defending soldier gets knocked-down and we have C.
C) defending soldier's defense is reduced by attacking soldier's attack (bonuses and stuff calculated in) each time he's knocked-down. My best guess is that there is no separate 'damage' done to skill, armour or shield, but rather a unified penalty applied to the soldier's overall defense. Defense-penalty >= 0
I must stress once again that all these are my speculations only and nothing hs been test-confirmed so far (at least by me or Xerex).
The point is:
These things are extremely interesting and sorting them out would benefit balancers enormously. Unfortunately, a very great deal of testing is involved, on an engine that is made to torture testers and even uses the same root for it's 'random' function in subsequent CBs...
If anyone has any test results or solid assumptions that could be of help here, we would all be delighted to see them! :)
Sry for the looong post...
Bookmarks