View Full Version : Civ III Combat Calculator (.EXE)


BomberEscort
Jan 18, 2004, 05:46 AM
It's finally here... :D

the conversion of my Excel spreadsheet into an EXE file for all those who wanted to use it but didn't have Excel. Also, I will no longer be supporting the spreadsheet.

*** Latest Version 1.35 ***


v1.32

Custom Terrain Bonuses from -99% to +999% in 1% increments.
Defender and Attacker HP increase to a maximum of 20 from 6.
Bombard Rate-of-Fire increased to a maximum of 20 from 6.
New Fields to show cumulative percentages of winning with 6+ HP
for Non-Bombard Attacks and 7+ HP for Bombard Attacks.
Fast Defender/Attacker HP and Experience are no longer tied to one another. Conscripts to Elites with 1 to 20 HP are now possible.
With the use of the new Custom Terrain setting you can achieve any Total Defensive Bonus from -99% to 1174% in 1% increments!
SAM Missile Battery Defenses from 1 to 99 (Default 8)
Interception Percentages from 1% to 100% (Default 50%)
A tool-tip functionality has been incorporated as a rudimentary form of help. Hover over a section and information shall be displayed.
Added Defensive Equivalent Option.
Fixed problem with Bombardment Percentages not showing correctly when lethal bombard was off. The totals were correct, the error was in the HP loss individual Percentages.
Added Default Bombard values for reference when using Offensive Bombard.
Rearranged to make the calculator more compact.


v1.33

Reworked Defensive Equivalent to include all units instead of slow only.
Individual Battle percentages now show for Defensive Bombard, Fast units and Slow units. Totals were not effected.
Added 'help' text for the Defensive Equivalent function.


v1.35

Fixed bug with retreat AHPL/DHPL not showing correctly
Fixed bug with Defensive Bombards not calculating correctly in some instances


Scroll Down past the screenshot for the EXE file ;)

BomberEscort
Jan 18, 2004, 05:47 AM
Screenshot

BomberEscort
Jan 18, 2004, 05:49 AM
Here is the program...

Version 1.00 removed after 21 downloads...
Version 1.01 removed after 58 downloads...
Version 1.10 removed after 83 downloads...
Version 1.15 removed after 1,005 downloads...
Version 1.22 removed after 841 downloads...
Version 1.30 removed after 16 downloads...
Version 1.32 removed after 192 downloads...
Version 1.33 removed after 458 downloads...

Calculator EXE
http://forums.civfanatics.com/uploads/33932/CivIIICombatCalculator_v1.36_.zip

Calculator VB6 Source
http://forums.civfanatics.com/showpost.php?p=4908955&postcount=82

Gogf
Jan 18, 2004, 12:01 PM
NICE!! Great job!

Sparta
Jan 20, 2004, 09:27 AM
sweet! thanks BomberEscort!

Oldenbarnevelt
Jan 21, 2004, 08:49 AM
Congrats on your first VB program! As far as I can see the calculation results are correct. A nice tool! A little nitpicking: "Lethal Bomard" should be "Lethal Bombard".

--
My first post to a Fanatics Forum :)

BomberEscort
Jan 21, 2004, 09:30 AM
Originally posted by Oldenbarnevelt
Congrats on your first VB program! As far as I can see the calculation results are correct. A nice tool! A little nitpicking: "Lethal Bomard" should be "Lethal Bombard".

--
My first post to a Fanatics Forum :)

Thanks... Also, nitpicking is fine, I like to pick nits... :D

Also, welcome to CivFanatics!

BomberEscort
Jan 22, 2004, 05:17 AM
Version 1.01 available...

Fixed some very minor errors, AA still on schedule for the next version release (mid-Feb)

jaafit
Jan 23, 2004, 02:50 AM
Nice job. Another nit: The tool-tip on AHPL is the same as the tool tip on DHPL.

One question: why does a fast attacker have less chance of winning than a non-fast attacker?

socralynnek
Jan 23, 2004, 03:42 AM
Originally posted by jaafit
Nice job. Another nit: The tool-tip on AHPL is the same as the tool tip on DHPL.

One question: why does a fast attacker have less chance of winning than a non-fast attacker?

It's because the fast attacker runs away when reaching 1 HP, while the others fight on. So, if you fight on, you have a small chance to win, so it's a small increase in winning, but also notice the bigger increase in losing...

jaafit
Jan 23, 2004, 04:55 AM
Ahhh, got it. Thanks.

BomberEscort
Jan 23, 2004, 05:24 AM
Originally posted by jaafit
Nice job. Another nit: The tool-tip on AHPL is the same as the tool tip on DHPL...

I believe this was fixed in version 1.01, it is on the copy I have... If it isn't let me know and I will repost.

BomberEscort
Jan 23, 2004, 05:27 AM
Also, the AA section is ahead of schedule, after I get the kinks in the formula straightened out I should have it ready by the end of the month...

Go here...

http://forums.civfanatics.com/showthread.php?postid=1540188#post1540188

for details on the AA Formula...

BomberEscort
Jan 24, 2004, 05:19 AM
The AA formula is now apart of the Civ III Combat Calculator v1.10... Credit to alexman and his work over at Poly in this endeavor and his testing on the formula... Our results and conclusions are in agreement.

jaafit
Jan 24, 2004, 05:41 AM
Originally posted by BomberEscort


I believe this was fixed in version 1.01, it is on the copy I have... If it isn't let me know and I will repost.

I downloaded v 1.10 and it's still the same.

I love this program though! I just used it today in my war against Ottomans, trying to decide if my 4hp calvary with radar tower should attack his 1 hp tank on a hill. I put in the values and it looked like I had about a 50/50 so I went for it. I lost 3 hp, and then... :)
No more tank.

BomberEscort
Jan 24, 2004, 05:46 AM
Ok, I see what you are talking about now, I thought you meant the numbers 0-5 under that... I will fix this in the next version (I'm going to wait to see if any more errors crawl out of the woodwork...)

Civrules
Jan 24, 2004, 11:18 AM
BomberEscort, thank you. I was unable to use your other excel calc but this seems to work fine. Now I can use this!!

Thanks a lot!!! :goodjob:

Pepso
Jan 24, 2004, 09:23 PM
Hi BomberEscort, first of all congrat's for this very nice program.

Secondly as you are an expert in this matter i was thinking if you could explain how the bombardment formula is calculated and if it's the same as the defensive bombardment, or you could just indicate some thread's you know, as i don't want to start a new one over this matter again.

And keep up the good work.

BomberEscort
Jan 26, 2004, 05:40 AM
Originally posted by Pepso
Hi BomberEscort, first of all congrat's for this very nice program.

Secondly as you are an expert in this matter i was thinking if you could explain how the bombardment formula is calculated and if it's the same as the defensive bombardment, or you could just indicate some thread's you know, as i don't want to start a new one over this matter again.

And keep up the good work.

The Bombardment Formula:

(BombardAttack / (BombardAttack + ModifiedDefense))^RateOfFire

e.g.- If the Bombard Attack = 4, Modified D = 6, ROF = 3 then...

Chance the Defender Takes 0 Damage = (6/10)^3 = 0.216
(Defender has to win all 3 battles)

Chance the Defender Takes 1 Damage = (6/10)^2 * (4/10)^1 * nCr(3,1) = 0.36 * 0.4 * 3 = 0.432
(Defender wins 2 battles, Attacker Wins 1, 3 Ways to Happen)

... Same for the other values (Defender takes 2 and 3 damage)

As for Defensive Bombardment, that is something different... ;)

Pepso
Jan 26, 2004, 01:10 PM
Thanks BomberEscort. :)

BomberEscort
Jan 28, 2004, 06:03 AM
Version 1.15 update:

Stealth Ability and SAM Missile Battery options added.

Civrules
Jan 28, 2004, 01:32 PM
Thank you!

Bleser
Jan 29, 2004, 12:06 PM
FANTASTIC!

lordbasl
Jan 30, 2004, 01:07 AM
Very nice!

Bobby Lee
Feb 10, 2004, 04:28 PM
is there sum way you could make this so that the numbers for the attack and defense points go above 99? i am using ur calculater to figure out unit strengths for a mod im working along with help from others, and i need the unit strengths to go above 99....by quite a bit

thanks

oh and BTW nice job :)

Louis XXIV
Feb 16, 2004, 04:22 PM
Finally got a chance to look at it today. It seems that some options keep graying themselves out for no particular reason, so sometimes I have to click to another option and then click back in order to do a particular thing (Like fortified units).

Also, I can't seem to check Lethal Bombard.

Roland Johansen
Feb 16, 2004, 05:29 PM
Very nice program. :goodjob:

And to answer one of Louis' questions.

Lethal bombard is only effective when rate of fire is higher than number of hp of defender left. Good programming on that, i'd say.:goodjob:

I have another questions though.

As you have made this program, I'd expect you to know exactly how every outcome of every combat is calculated. :)

Now I'm wondering if terrain bonusses and civil defence and radar towers and all those kinds of bonusses have any influence on the outcome of air combat (defender intercepting bombarding fighter/bomber unit).

Your program seems to suggest that radar towers and rivers do have an effect and the rest of the bonusses don't. But I can also select fast attacker/defender which is very strange for air units. Can air units retreat? I never tested what happens when you give movement points to air units, but I doubt that they retreat.

Are you correct? Do only radar towers and rivers have any effect on air combat? I'm just curious because I want to balance attack and defence of fighter units for a mod I'm making and thus want to know what effects air combat.

DrSpike
Feb 17, 2004, 11:21 AM
I don't post here much, but I dropped by to say what a nice tool this calculator is. Very easy to use and interpret.

Cheers

Doc

BomberEscort
Feb 23, 2004, 05:08 AM
Originally posted by Louis XXIV
Finally got a chance to look at it today. It seems that some options keep graying themselves out for no particular reason, so sometimes I have to click to another option and then click back in order to do a particular thing (Like fortified units).

Also, I can't seem to check Lethal Bombard.

List some specific examples and I will check it out...

BomberEscort
Feb 23, 2004, 05:14 AM
Originally posted by Roland Johansen
...Now I'm wondering if terrain bonusses and civil defence and radar towers and all those kinds of bonusses have any influence on the outcome of air combat (defender intercepting bombarding fighter/bomber unit)...

No they don't have any effect. The only thing that effects air combat is other air units, AA units, and SAM Missile Battery.

Originally posted by Roland Johansen
...Your program seems to suggest that radar towers and rivers do have an effect and the rest of the bonusses don't. But I can also select fast attacker/defender which is very strange for air units. Can air units retreat? I never tested what happens when you give movement points to air units, but I doubt that they retreat...

Are you selecting 'Air' for your terrain. I don't have a copy of the program with me, but I remember 'Air' greying everything out. If not I will check this out... You can give air units movement points, I know they don't retreat, but I have heard that you can rebase twice with 2 MP, I haven't personally tested this though. But you are correct, radar towers and rivers have no effect, the only units/improvements the effect air combat are listed above.

BomberEscort
Feb 23, 2004, 05:17 AM
Originally posted by Bobby Lee
is there sum way you could make this so that the numbers for the attack and defense points go above 99? i am using ur calculater to figure out unit strengths for a mod im working along with help from others, and i need the unit strengths to go above 99....by quite a bit...

No 99's the limit... :P

Roland Johansen
Feb 23, 2004, 08:25 AM
Originally posted by BomberEscort

Are you selecting 'Air' for your terrain. I don't have a copy of the program with me, but I remember 'Air' greying everything out. If not I will check this out... You can give air units movement points, I know they don't retreat, but I have heard that you can rebase twice with 2 MP, I haven't personally tested this though. But you are correct, radar towers and rivers have no effect, the only units/improvements the effect air combat are listed above.

Thank you for the information. Now I know everything to balance out air combat in my personal mod.

In the utility a lot of things get greyed out when one selects Air, but not everything in the top half of your calculator (radar towers, attacking across a river, fast defender). This is also true for coast/sea/ocean. I don't know if radar towers give bonusses for sea combat, but rivers obviously can't give bonusses at sea ;). Also I'm not sure if fortifying at sea really gives a bonus, but I never tested it.

All of these observations are of course minor details, it's a great calculator. :goodjob:

Shogun Gunner
Feb 24, 2004, 09:57 PM
Very useful utility. Thanks BomberEscort!

Conditional Zenith
Mar 14, 2004, 12:00 AM
Bomber Escort,

It seems that your combat calculator (version 1.15) does not calculate the probability of a retreat correctly.

For example, when a unit with an attack rating of 4 on 3HP with regualr experience attacks a fast unit with a defense rating of 3 on 3HP with regular experience (giving a retreat chance of 0.5), the probability of retreat is as such:

(4/7)^2 * 0.5 + (4/7)^2 * (3/7) * 0.5 * 2
= 0.303207

Your calculator gives an answer of 0.233236 as the chance of a retreat. This is the same answer as the above equation without the final "*2".

The final * 2 is added to account for the fact that there are 2 ways that there could be a 2-1 retreat: attacker wins, defender wins, attacker wins, defender retreats OR defender wins, attacker wins, attacker wins, defender retreats.

In general, there are (defender's starting HP + no. HP attacker loses - 2)C(no. HP attacker loses) ways that a retreat for a given no. of HP attacker loses can occur.

Apart from the above issue, nice calculator.

BomberEscort
Mar 15, 2004, 02:23 PM
Originally posted by Conditional Zenith
Bomber Escort,

It seems that your combat calculator (version 1.15) does not calculate the probability of a retreat correctly.

For example, when a unit with an attack rating of 4 on 3HP with regualr experience attacks a fast unit with a defense rating of 3 on 3HP with regular experience (giving a retreat chance of 0.5), the probability of retreat is as such:

(4/7)^2 * 0.5 + (4/7)^2 * (3/7) * 0.5 * 2
= 0.303207

Your calculator gives an answer of 0.233236 as the chance of a retreat. This is the same answer as the above equation without the final "*2".

The final * 2 is added to account for the fact that there are 2 ways that there could be a 2-1 retreat: [Case #1] attacker wins, defender wins, attacker wins, defender retreats OR [Case #2] defender wins, attacker wins, attacker wins, defender retreats.

In general, there are (defender's starting HP + no. HP attacker loses - 2)C(no. HP attacker loses) ways that a retreat for a given no. of HP attacker loses can occur.

Apart from the above issue, nice calculator.

Bracketed comments in the quote above are mine...

I see it as only one way to retreat... Here is my rationale...

Fast Defender retreats only occur when the attacker has 2 hp and the defender has 1 hp, any other combination of hit points will not retreat. When this combination exists, using the example above, the retreat happens in 50% percent of those cases. The other 50% the battle continues normally (Win or Loss).

Using your example above, eliminating the 'way' we get to the 2-1 requirement, the retreat-round is as follows:

Case #1: ...attacker wins, defender retreats OR
Case #2: ...attacker wins, defender retreats.

There is one and only one potential retreat round in any given encounter, though this potential may never be realized (the retreat is only calculated once)

In the above cases the defender always loses 2hp and the attacker can lose 0 or 1 (if he loses 2 before the defender loses 2 the retreat will not happen), I account for this in my fomula.

Either way, the retreat is triggered by this scenario (attacker wins round THEN defender retreats)

From what I can tell, you include the 'ways' to get to the 2-1 requirement and I do not... I am far from a statistical expert, if you could explain why you include the 'ways' to get to the 2-1 requirement that might help... Also, I will do another sample based on the example above and post the data...

Either way, good check... I appreciate all the help I can get, the perfection of this calculator being the goal... :D

Lambda
Mar 15, 2004, 04:39 PM
this is a great tool....this is THE tool for any civ player.

i'm learning C and C++ and i wanted to do something like this, i never liked the excel calculators they just occupy to much ram and they are just to slow.

you are the man bomber escort!

Conditional Zenith
Mar 16, 2004, 04:29 AM
quote:
--------------------------------------------------------------------------------
Originally posted by Conditional Zenith
Bomber Escort,

It seems that your combat calculator (version 1.15) does not calculate the probability of a retreat correctly.

For example, when a unit with an attack rating of 4 on 3HP with regualr experience attacks a fast unit with a defense rating of 3 on 3HP with regular experience (giving a retreat chance of 0.5), the probability of retreat is as such:

(4/7)^2 * 0.5 + (4/7)^2 * (3/7) * 0.5 * 2
= 0.303207

Your calculator gives an answer of 0.233236 as the chance of a retreat. This is the same answer as the above equation without the final "*2".

The final * 2 is added to account for the fact that there are 2 ways that there could be a 2-1 retreat: [Case #1] attacker wins, defender wins, attacker wins, defender retreats OR [Case #2] defender wins, attacker wins, attacker wins, defender retreats.

In general, there are (defender's starting HP + no. HP attacker loses - 2)C(no. HP attacker loses) ways that a retreat for a given no. of HP attacker loses can occur.

Apart from the above issue, nice calculator.
--------------------------------------------------------------------------------



Bracketed comments in the quote above are mine...

I see it as only one way to retreat... Here is my rationale...

Fast Defender retreats only occur when the attacker has 2 hp and the defender has 1 hp, any other combination of hit points will not retreat. When this combination exists, using the example above, the retreat happens in 50% percent of those cases. The other 50% the battle continues normally (Win or Loss).

Using your example above, eliminating the 'way' we get to the 2-1 requirement, the retreat-round is as follows:

Case #1: ...attacker wins, defender retreats OR
Case #2: ...attacker wins, defender retreats.

There is one and only one potential retreat round in any given encounter, though this potential may never be realized (the retreat is only calculated once)

In the above cases the defender always loses 2hp and the attacker can lose 0 or 1 (if he loses 2 before the defender loses 2 the retreat will not happen), I account for this in my fomula.

Either way, the retreat is triggered by this scenario (attacker wins round THEN defender retreats)

From what I can tell, you include the 'ways' to get to the 2-1 requirement and I do not... I am far from a statistical expert, if you could explain why you include the 'ways' to get to the 2-1 requirement that might help... Also, I will do another sample based on the example above and post the data...


I include the number of ways to get to 2-1 (actually the number of ways to get to 2-2, as there is only 1 way to get to 2-1 from 2-2 as you have already pointed out) as the retreat can happen as in case#1 or as in case#2. Both the cases are mutually exclusive and therefore the probability of case#1 OR case#2 is P(case#1) + P(case#2). I think we agree that P(case#1) = P(case#2) = (4/7)^2 * (3/7) * 0.5
therefore P(case#1 OR case#2) = ((4/7)^2 * (3/7) * 0.5) + ((4/7)^2 * (3/7) * 0.5) = 2 * (4/7)^2 * (3/7) * 0.5

Hope this explains my inclusion of the number of ways to get to 2-1

BomberEscort
Mar 18, 2004, 02:43 PM
Good catch, I have verified your numbers through testing and an update will be forthcoming :goodjob:

Sovereign
Mar 18, 2004, 03:02 PM
Sweet... now I can work out what to do in a game, to attack or to defend... that is the question :D!

daufoi
Mar 19, 2004, 04:23 PM
how come the original combat calculator by Xerxes314 uses playing level (i.e. Regent, Monarch, etc) in its calculations and this one doesn't? does the level of play affect those calculations?

daufoi

Sovereign
Mar 19, 2004, 04:36 PM
Hmm... I dunno... you might be right, well BomberEscort will hopefully say if it does, but I don't think it does.

Sparta
Mar 19, 2004, 04:58 PM
I'm far from a reliable source, but if I had to venture a guess, I'd say that the old combat calculator was giving you odds on barbarian attacks (for which you definitely DO get a bonus based on difficulty level). Probably not much of a concern, as your odds will be better against a barb anyway (unless you're on like sid level or something). AFAIK there are no difficulty modifiers for civ-on-civ attacks, but I could be wrong.

BomberEscort
Mar 22, 2004, 05:18 AM
Level of play does not affect any combat except those against barbarians...

Sovereign
Mar 22, 2004, 07:08 AM
I keep loosing the World War in the Pacific Map... yet the Napoleonic Europe maps are okay... my French troops spit and everything (I edited the files byt recording me spitting). When playing as Russia the barbarians are easy... and the French have got too good Imperial Guards and Imperial Cavalry... but my Cossaks are okay, because they are faster than they are traditionally.

socralynnek
Apr 22, 2004, 07:26 AM
Hello Bomber Escort,
first of all: I really like your program, but I think I found a very small bug:

If a fast defender is fortified in a city, it never retreats, but your program computes a retreat chance.

BomberEscort
Jul 24, 2004, 10:32 AM
Sorry for the update delay, I have been occupied by career concerns...

Version 1.22 update fixes the following
- An error with the retreat calculations (Thanks Conditional Zenith)
- Other very minor misc. errors

Other Issues:
- Army combat will not be added
- There is still a minor error with the AA formula that needs to be addressed...

deeno
Aug 12, 2004, 06:14 AM
Could you make it go above the regular 6 hp's? I need a calculator that makes it go to 15 :(

handy900
Aug 12, 2004, 11:04 AM
Fantabulous! [dance]

So easy to use and it has bombard built in. Very well done!

NP300
Sep 07, 2004, 10:47 PM
I have a modded game with custom defensive bonuses for terrain tiles. Is there any way to manually add in the modified defense for the calculator? For example, I have tiles with a defense bonus of -20%, yes a defensive penalty. And the only way I can calcuate these is by multiplying the defense by 10x and then subtracting 20%. But then I run into the problem that the calculator doesn't allow values greater than 99.

Zeekater
Oct 04, 2004, 04:26 PM
Sorry for the bump, but I wonder if it'd be possible to have the program be able to handle HP above 6?
It's a really good program, and I use it to test out unit stats when I wanna change them, and many units have more then 6 HP :)

Rubruk
Oct 13, 2004, 08:30 AM
Hi BomberEscort!

Your calculator is very good.

BomberEscort
Oct 28, 2004, 07:22 AM
I'm taking an official list of requests for updating the calculator.

So far I have:

1) Increase to allow up to 15 hp battles.
2) Allow custom terrain modifiers from -99% to +999%

If there is anything else let me know, I will try to start on this in early November...

Roland Johansen
Oct 28, 2004, 06:00 PM
What I would like to see are some usefull additions for modmakers. I'm thinking about:
1) The possibility to change the defensive bonusses of terrain, fortresses, barricades, rivers and fortifying or the option to determine the total defensive bonus yourself.
2) The option of the amphibious assault bonus of 25% somewhere added.
3) The option to change the interception chances for normal and stealth bombers.

I realize that adding these functionalities might make the calculator more complicated and less accessible for some people, thus it is a challenge to add functionalities without making the calculator look very complicated.

The present calculator is already a great tool. :goodjob:

As you know a lot about the way combat is handled, you might know the following aspect of combat too. If a bomber attacks, it can hit nothing, a unit, a building or a population point. I've read some studies about this in PTW en Civ3 vanilla where the chances to hit each of the differnet types of targets were determined, but I haven't read any study about the topic in C3C and we know that they made some changes in bombardment as artillery and ships now first target units, but bombers can hit anything. Is something known about this subject? Thanks in advance.

BomberEscort
Oct 29, 2004, 07:12 AM
As you know a lot about the way combat is handled, you might know the following aspect of combat too. If a bomber attacks, it can hit nothing, a unit, a building or a population point. I've read some studies about this in PTW en Civ3 vanilla where the chances to hit each of the differnet types of targets were determined, but I haven't read any study about the topic in C3C and we know that they made some changes in bombardment as artillery and ships now first target units, but bombers can hit anything. Is something known about this subject? Thanks in advance.

I haven't seen anything for this in C3C.


2) The option of the amphibious assault bonusof 25% somewhere added.


I wasn't aware this was included in the C3C final version. Last I heard it was an idea that was never implemented. I'll check though.

BomberEscort
Oct 29, 2004, 07:18 AM
Changes made for Version 1.30


Custom Terrain Bonuses from -99% to +999% in 1% increments.
Defender and Attacker HP increase to a maximum of 20 from 6.
Bombard Rate-of-Fire increased to a maximum of 20 from 6.
New Fields to show cumulative percentages of winning with 6+ HP for Non-Bombard Attacks and 7+ HP for Bombard Attacks.
Fast Defender/Attacker HP and Experience are no longer tied to one another. Conscripts to Elites with 1 to 20 HP are now possible.
With the use of the new Custom Terrain setting you can achieve any Total Defensive Bonus from -99% to 1174% in 1% increments!
SAM Missile Battery Defenses from 1 to 99 (Default 8)
Interception Percentages for SAM Missile Battery range from 1% to 100% (Default 50%)


I tested this thouroughly with extreme values, trying to create overflows, etc. I also tested the comparable results with version 1.22 of this calculator and they tested accurate, no difference between the two. As with any complicated endeavor errors are bound to be hidden in the code. I welcome any comments pertaining to the accuracy of this Combat Calculator. Enjoy :thumbsup:

See page one for downloading...

Roland Johansen
Oct 29, 2004, 01:44 PM
Thank you. That was fast. :goodjob:

I've heard different things about the amphibious assault bonus. I am not sure that it was implemented and have never done any tests to make sure.

BomberEscort
Nov 01, 2004, 06:33 AM
*** Latest Version 1.32 ***

Minor fix to v1.30
Custom Terrain Bonuses from -99% to +999% in 1% increments.
Defender and Attacker HP increase to a maximum of 20 from 6.
Bombard Rate-of-Fire increased to a maximum of 20 from 6.
New Fields to show cumulative percentages of winning with 6+ HP
for Non-Bombard Attacks and 7+ HP for Bombard Attacks.
Fast Defender/Attacker HP and Experience are no longer tied to one another. Conscripts to Elites with 1 to 20 HP are now possible.
With the use of the new Custom Terrain setting you can achieve any Total Defensive Bonus from -99% to 1174% in 1% increments!
SAM Missile Battery Defenses from 1 to 99 (Default 8)
Interception Percentages from 1% to 100% (Default 50%)
A tool-tip functionality has been incorporated as a rudimentary form of help. Hover over a section and information shall be displayed.
Added Defensive Equivalent Option (Explained Below).
Fixed problem with Bombardment Percentages not showing correctly when lethal bombard was off. The totals were correct, the error was in the HP loss individual Percentages.
Added C3C Unit Default Bombard values for reference when using Offensive Bombard.
Rearranged to make the calculator more compact.

BomberEscort
Nov 01, 2004, 06:35 AM
Changes in v1.33

Reworked Defensive Equivalent to include all units instead of slow only.
Individual Battle percentages now show for Defensive Bombard, Fast units and Slow units. Totals were not effected.
Added 'help' text for the Defensive Equivalent function.

Offa
Nov 05, 2004, 05:08 PM
Do you know if the capital city gets an additional defence bonus? I had thought that this was the case, eg rated as a size bigger than it actually is. This actually has some real bearing in how to play the game, and so I would love to find out.

BomberEscort
Nov 08, 2004, 06:43 AM
Do you know if the capital city gets an additional defence bonus? I had thought that this was the case, eg rated as a size bigger than it actually is. This actually has some real bearing in how to play the game, and so I would love to find out.

AFAIK it just a graphical representation only, I do not believe there is a bonus for the capital.

Updated to version 1.33 (see page 1 for download)

eldar
Nov 14, 2004, 04:43 AM
Changing a lot of things (e.g. 'Population Center') unchecks the 'Fortified' box. Just a bit annoying, as you have to re-check it every time.

Neil. :cool:

Offa
Nov 22, 2004, 04:47 PM
For offensive bombardment at present the results are given as the same regardless of whether the defender is outside in the open or in a town. I believe that the actual chance of inflicting damage on a defender inside a town is much lower as the bombardment may get directed against city improvements or population instead.

Arathorn
Nov 30, 2004, 12:37 PM
Somehow, retreats and hps lost aren't being calculated properly. The final attacker wins, defender wins, and draw probabilities also seem to be affected, I think.

Consider a 2 hp veteran knight attacking a 2 hp regular spear fortified in a town on grassland. This means a modified defense of 2.70, we agree. Thus, the attacker wins 4/6.7=59.7% of the rounds. I think we agree on that.

By your calculations with Oystein, the chance of a retreat, should one occur, is exactly 58% -- 58/(50+50), since the knight is vet and the spear regular. I think we agree on that (unless there's been more recent research I've missed...in which case, where is it?).

Let's go through all the possibilities. With only 2 hps, we can list them all out. I'll use A to mean attacker wins a round and D to mean defender wins a round, so AA means attacker wins and then attacker wins. [Note, I used more exact numbers but am only showing a few to save typing time.]
AA - Happens with probability .597^2 = 35.64% (AHPL = 0, attacker wins)
ADA - No retreat chance since defender at 1 hp when attacker reaches 1 hp - Probability .597*.403*.597 = 14.36% (AHPL = 1, attacker wins)
ADD - No retreat chance - Probability .597*.403*.403 = 9.70% (DHPL = 1, defender wins)
D* - The * is a successful retreat - Probability .402*.58 = 23.37% (AHPL=1, DHPL=0, DRAW)
D*AA - The * is a failed retreat. Since the defender still had 2 hps, the knight rolls to retreat. In this case, it failed, leading to this result - Probability .402*.42*.597*.597 = 6.03% (AHPL = 1, attacker wins)
D*AD - * is a failed retreat - Probability .402*.42*.597*.402 = 4.07% (DHPL = 1, defender wins)
D*D - * is a failed retreat - Probability .402*.42*.402 = 6.82% (DHPL = 0, defender wins)

Total probabilities....
A wins - 35.64 + 14.36 + 6.03 = 56.03%
D wins - 9.70 + 4.07 + 6.82 = 20.59%
DRAW - 23.37%

(AHPL = 0) - 35.64%
(AHPL = 1) - 14.36 + 23.37 + 6.03 = 43.76%
(DHPL = 0) - 23.37 + 6.82 = 30.19%
(DHLP = 1) - 9.70 + 4.07 = 13.77%

The A wins, D wins, and DRAW match your combat calculator, but you show 43.972% for (AHPL = 0) and 35.440% for (AHPL=1), for example, which just has to be wrong.

Also, changing the attackers hps changes the odds of (AHPL=0), which is wrong, because that's always just the chance the attacker wins two consecutively and MUST be the same for all values of attacker hps. Indeed, setting attacker hps to 1 gives 35.643%, which is what (AHPL=0) must be for any attacker hp value (changing nothing else).

You need to look at your retreat logic again. If I can help, let me know.

This simple example doesn't show the error in attacker wins, defender wins, DRAW, but I think it's there and probably the same bug. For example, a 4 hp vet knight attacking a 3 hp regular spear with same terrain, I get 78.4% attacker wins and you get 79.4% with our defensive wins off by similar amounts.

Arathorn

BomberEscort
Dec 19, 2004, 01:16 PM
Version 1.35 posted on Page #1.


I reworked the retreat formula (credit to Arathorn). I think this is working correctly now. :D
Fixed a coding error with Defensive Bombard that caused a minor error in the totals.


I don't think I am going to update Offensive Bombard to include damage probabilities when attacking units in cities. Sometimes the bombard hits the pop, unit, or building and this could not be added without extra toggles that will clutter the interface.

dexters
Feb 14, 2005, 07:12 AM
A quick question, I'm not exactly sure how to configure the combat calculator to calculate air vs. air intercept rates. (ie: the chance a bomber will be shot down by a passive fighter on air superiority)

Can you clarify?

Pfeffersack
Mar 25, 2005, 07:16 AM
About the amphibious attack bonus...I found this thread at Apolytons AU forum:

http://apolyton.net/forums/showthread.php?s=&threadid=105787

Quote from Alexman:

OK, the amphibious bonus is actually 25% (confirmed by Firaxis). (...)

BomberEscort
Mar 25, 2005, 03:00 PM
A quick question, I'm not exactly sure how to configure the combat calculator to calculate air vs. air intercept rates. (ie: the chance a bomber will be shot down by a passive fighter on air superiority)

Can you clarify?

ATM, the calculator does not support these calculations.

BomberEscort
Mar 25, 2005, 03:02 PM
About the amphibious attack bonus...I found this thread at Apolytons AU forum:

http://apolyton.net/forums/showthread.php?s=&threadid=105787

Quote from Alexman:

Last I heard this was tentatively in, but was later removed. I did some testing with the latest conquests patch sometime back and I did not notice this bonus. I'll check posts by Alexman on poly and see if he has any new data of which I am unaware.

Eetu Pellonpää
May 01, 2005, 04:12 AM
Fine tool to check the changes of impossible to happen...

:spear:

would-be-addict
May 10, 2005, 10:24 PM
For some odd reason, my very slow computer can't get the calculator. I will download it, but when I try to open it, it comes up with this window that says: "CivIIICombatCalculator.zip could not be opened." and it won't let me get to it. :mad: Monitors will roll!!! :mad:

Himalia
Jun 16, 2005, 10:47 AM
Very nice utility however it has just confirmed to me even more so how dodgy some of the results are the AI keeps getting in its favour. OMG how the hell is my Elite Modern Armour gonna defeat that 2hp Spearman on the grasslands. Im sure many of you know what i mean by this.

socralynnek
Jun 16, 2005, 05:57 PM
Hmmm, it also happens the other way round, the AI does not cheat concerning the Combat calculation.
You don't have a 100% of winning, so sooner or later it happens that you lose a 99% fight.

MSTK
Jul 08, 2005, 12:29 AM
Wait, am I missing something, or does this only calculate the results of one "fight" and not an entire battle? What if I want to compound many units vs many units?

josephstalin
Jul 21, 2005, 02:41 PM
That's good utility. Though I'm not goung to use it often. But you have to check/uncheck too many same boxes too many times, when you changed something...

Simon1995
Aug 12, 2005, 07:23 PM
:confused: Can u tell me how to correctly use this program and does it work for Civ3v1.29f and how do u use it i dont understand :confused:

Ingxoxo
Nov 15, 2006, 11:59 PM
How do I download the program? I clicked onthe "NEW Civ III Combat Cal..." and it takes me to this page, then I scroll down to "Here's the program..." and there is nothing to click on. What's the deal? (I don't think this matters in the slightest, but I am logged on)

BadKharma
Dec 21, 2006, 03:25 PM
"Bump" I really could use this utility if anyone has it could you upload it. There no longer is a link to download it.

socralynnek
Dec 21, 2006, 04:17 PM
Since I don't know whether this is on purpose, I won't just send it to you. Have you tried PMing BomberEscort?

Mirc
Dec 21, 2006, 06:19 PM
What do you mean, if this is on purpose? :)

socralynnek
Dec 21, 2006, 06:29 PM
Sorry, if I was unclear.
I don't know why the program isn't here anymore. So I don't know whether BomberEscort doesn't want to spread this program anymore.
As he is the owner of the program, you might want to ask him whether he wants to distribute it.

Mirc
Dec 21, 2006, 06:30 PM
Ah, ok, I get it now. :)

BomberEscort
Dec 23, 2006, 09:21 AM
Hello all,

Sorry for any delays. I haven't been monitoring this page, so I didn't know about the problems until I was PMed. That said I am officially releasing the calculator into the public domain. Included are all the files I used with Visual Studio 6.0 to create the calculator (If I inadventently missed one, just PM me). It was written with VB 6.0. I tried to comment the code as much as possible, mainly for my benefit at the time, but hopefully it will help everyone now. If anyone finds errors or has improvements feel free to post them here. Although I am no longer making code changes or supporting the program, I'd still be interested in hearing about it. Happy Civ-ing!!! :D

Calculator Source
http://forums.civfanatics.com/uploads/33932/CivIIICombatCalculatorSource.zip

Calculator EXE
http://forums.civfanatics.com/uploads/33932/CivIIICombatCalculator_v1.36_.zip

Civinator
Dec 23, 2006, 11:13 AM
Thanks a lot BomberEscort and merry christmas :D

BadKharma
Dec 23, 2006, 02:45 PM
Thank you so very much and a Merry X-mas to you.

eerr
May 30, 2007, 04:10 PM
"Custom Terrain Bonuses from -99% to +999% in 1% increments."
...........................................^
if a unit has a net strength penalty, the % combat strength is added and then inverted
(1/1.99), or about 1/2 normal strength for -99% defense

or it could be a typo : P

BbarronN
Jun 26, 2007, 08:41 PM
Could you please add bonuses for fights against barbarians according to difficulty levels?

zlatan24
Nov 22, 2007, 08:24 AM
I know not bad tool which may possible work with some files of Visual Studio - unable to read file xls (http://www.recoverytoolbox.com/unable_to_read_xls_xlsx.html), do something help with encounter a problem with your workbook in Microsoft Excel format and you cannot open it, there may be a serious problem, restore document contains only several strings of data, it can be easily recovered manually, but what to do, if your workbook contains tens of worksheets, find best solutions for repairing documents in Microsoft Excel format.

england817
Nov 26, 2007, 08:05 PM
Just wondering, but i've seen that the max HP for the calculator is 20, while I know that having more than that is strange, the naval battles in my WIP Scenario have been spiced up.

You see, the Battleships (I was just testing how some of the battles would play out, statistically) have an 18 pt. bonus (max of 20) so therefore they have 21 HP, more than 20.

I wanted to see if the Battleships could defend against a Submarine -- as the Defense value of the BB is [45] and the attack of the SS is [55], but the BB HP is [21] and the SS HP is only [6], so I was wondering how this would play out.

Just wondering if it could be fixed, not that its a big problem.