I am currently working on a combat calculator that will calculate the odds for each outcome of a given combat. To do so I need to know all the combat rules precisely.
Here is what I know:
The combat is divided into rounds. These round continue until one of the following outcomes happens:
-Attacker hp reduced to zero
-Defender hp reduced to zero
-Attacker retreats
-Defender retreats
For each round, the following results are possible:
-Attacker damages defender by one hp
-Defender damages attacker by one hp
-Attacker retreats (if possible)
-Defender reatreats (if possible)
Known: Attacker has a chance to retreat if it has a movement rating > 1 and the defender has a movement rating = 1. The chance of retreating is dependent only on the attackers rank.
Question: I am pretty sure that the attacker can never retreat on the opening round. Also, I am pretty sure that the attacker must have one hp left, and the defender must have more than one. Is this right?
Question: how does defender retreat work? I know that you have to have the defender movement >1 and attacker movement = 1. Does the defender have to have a movement point left? A full movement point? In other words, suppose the defender, a cavalry, had used 2 full movement points plus two road movements the previous turn. Can it retreat into mountains when attacked on the next turn?
Known: Assuming that a retreat did not occur, either the attacker or the defender takes one hp of damage. The chance of the attacker taking damage is:
D/(A+D)
where A=modified attacker attack rating, and D=modified defender defend rating.
Similarly, the chance of a defender taking damage is
A/(A+D).
Let chance of attacker retreat be AR, and chance of defender retreat be DR. If I am right about the rules of defender retreat, then only one of these is not zero. So the chance of retreat is AR+DR.
Now we have all the odds for each round:
Attacker damages defender: A/(A+D)*(1-(AR+DR))
Defender damages attacker: D/(A+D)*(1-(AR+DR))
Attacker retreats: AR
Defender retreats: DR
The modified attack and defense ratings are pretty straightforward. I am aware of that the bonuses are added linearly, not geometrically. I have included things like advantages vs. barbarians based on playing level.
Another question: how does rank effect the combat. Here is what I think I know:
-Higher rank = higher potential hp
-Higher rank = better chance of retreat
Anything else?
I know that this is a bit disjointed, so sorry in advance. Any clarifications and additions are welcome.
By the way, I am only doing it for land battles without armies. Armies seriously complicate things, and are not used as much anyway. I also am not taking into account the artillery shot at this time. I realize that is a shortcoming. Anyone know the rules for it?
Here is what I know:
The combat is divided into rounds. These round continue until one of the following outcomes happens:
-Attacker hp reduced to zero
-Defender hp reduced to zero
-Attacker retreats
-Defender retreats
For each round, the following results are possible:
-Attacker damages defender by one hp
-Defender damages attacker by one hp
-Attacker retreats (if possible)
-Defender reatreats (if possible)
Known: Attacker has a chance to retreat if it has a movement rating > 1 and the defender has a movement rating = 1. The chance of retreating is dependent only on the attackers rank.
Question: I am pretty sure that the attacker can never retreat on the opening round. Also, I am pretty sure that the attacker must have one hp left, and the defender must have more than one. Is this right?
Question: how does defender retreat work? I know that you have to have the defender movement >1 and attacker movement = 1. Does the defender have to have a movement point left? A full movement point? In other words, suppose the defender, a cavalry, had used 2 full movement points plus two road movements the previous turn. Can it retreat into mountains when attacked on the next turn?
Known: Assuming that a retreat did not occur, either the attacker or the defender takes one hp of damage. The chance of the attacker taking damage is:
D/(A+D)
where A=modified attacker attack rating, and D=modified defender defend rating.
Similarly, the chance of a defender taking damage is
A/(A+D).
Let chance of attacker retreat be AR, and chance of defender retreat be DR. If I am right about the rules of defender retreat, then only one of these is not zero. So the chance of retreat is AR+DR.
Now we have all the odds for each round:
Attacker damages defender: A/(A+D)*(1-(AR+DR))
Defender damages attacker: D/(A+D)*(1-(AR+DR))
Attacker retreats: AR
Defender retreats: DR
The modified attack and defense ratings are pretty straightforward. I am aware of that the bonuses are added linearly, not geometrically. I have included things like advantages vs. barbarians based on playing level.
Another question: how does rank effect the combat. Here is what I think I know:
-Higher rank = higher potential hp
-Higher rank = better chance of retreat
Anything else?
I know that this is a bit disjointed, so sorry in advance. Any clarifications and additions are welcome.
By the way, I am only doing it for land battles without armies. Armies seriously complicate things, and are not used as much anyway. I also am not taking into account the artillery shot at this time. I realize that is a shortcoming. Anyone know the rules for it?
Comment