The Big Question - How Does The AI Choose Which Units To Build?

Ah ha! Very good work Rocoteh. :goodjob:
Does not your experiment #4b show that reducing the defensive bombardment also reduces the chances of succeeding in getting that one hit point loss?

I wonder if I could trouble you to do a further experiment..... :)
* two 'red' stacks of say 6 units each (let's call them 'nomads' for now), each unit with an attack of 2 but a defence of say 10, and 4 hit points each.
* one 'blue' stack of say 6 units (called 'slingers' for this experiment), with attack 2, defence 1, 4 hit points, and a defensive bombardment of only 1.
* another 'blue' stack of say 6 units (let's just call them 'mortars'), with exactly the same stats as the 'slingers', but with a defensive bombardment of say 20.
Now let each 'red' stack assult each 'blue' stack....which 'blue' stack will survive?

According to CivLackey's excellent combat calculator, the result should be as follows:-
Attack 2 (with 4 hit points) versus a fortified defence of 1 (with 4 hit points) = 70% success.
Attack 2 (with 3 hit points) versus a fortified defence of 1 (with 4 hit points) = 54% success.

IF the value of the defensive bombardment is used, then the 'slingers' will have very little chance of getting that hit (bombard of only 1 against the 'nomads' defence of 10), and so should be massacred.
The 'mortars' on the other hand have a higher chance of getting that hit, and so should do much better.

BUT, I am begining to suspect that 'defensive bombardment' uses the same subroutine as 'ZOC', and so will cause one hit point loss no matter what the bombardment value is set at (we already know that the hit point loss is always one, no matter what the 'rate-of-fire').

(Forgive me for asking for this little test, but I am currently up to my neck creating new units....which just happens to be a bundle of skirmishers such as Javelinmen, Numidian Horsemen, Republican Roman Velites, Celtic Slingers, Baleric Slingers, Indian Bowmen, and Dark Age Shortbowmen....all of which have defensive bombardment. So, as you can see, I am VERY interested in the results of the above proposed experiment. :D )
 
Kryten,

Thank you for the positive words.

With regard to experiment #4b I agree with you.

The experiment you mention sounds very interesting,
I will try to find time to do it tomorrow.

Rocoteh
 
Kryten,

Here are the results of the test you proposed:

10 rounds were made. Numbers= surviving defenders

"Slingers" 0,2,1,2,1,2,0,1,1,1, =11, 1,1
"Mortars" 1,1,2.0,3,2,2,0,2,2, =15 1,5
"Lightning" 3,2,1,2,5,3,2,2,2,0 =22 2,2

This experiment 5 confirms 4b.
The question is: Are modders in general aware
of these numbers when setting shield-costs?
Edit:
The Lightning unit added had 200 in Bombard Strenght.


Rocoteh
 
@ Last Conformist and all. This might not be the place but I thought it might be of interest about Navies :

These are some screenshots of a standrad PTW game I have been playing on Emperor level.
As you can see Chine (n#1) and Iroquois (n#4) have a much better navy tham me (n#2). n#3 is Germany but so far I have failed to establish a spy. England that was OK a power before being put down to two cities still has around 15 destroyers, which is still higher than me.
Now I am really lacking in techs and units because I have been entangled in long, destructive wars and I have few productive harbors (though that changes).
The only "important" power without a navy is Americans :confused:
I have shown most figures for army, navy and airforce of the Chinese, and there is no competitor by far in the field.
China passed along my coast to attack England (I am the Celts) and always escorted its carriers with battleships and one or two subs around (trust me about the subs). Now I don't know how it fared when attacking with planes on the carrier or not.

China destroyed India on its island pretty quiclky so the interest of a navy was probably obvious in that case and it is likely a pangea map would have given different results. But at least you can see a "powerful" navy. Not 1/3 of their troops but as the British used to do, more powerful than the combined forces of the next two powers at least (Germany seems much more a land power because I have not seen many of its ships attacking England (yet again :) ) and actually more than the three next powers. Chiina also has 3 nuclear subs that don't appear here !


China.GIF


ChinaTroops1.GIF


ChinaTroops2.GIF


ChinaTroops3.GIF


NavyIroquois.GIF
 
LouLong,

Why do you qoute me on a comment made on
artillery and then start to talk about navies?

Where is the logic?

Rocoteh
 
Originally posted by Rocoteh
ozymandias,

What will be your next experiments?

Rocoteh

I'm of two minds about this, and trying to figure out the best ways to approach both -- input / advaice is certainly appreciated.

Mind you, I write all this in the context of my only ever-increasing belief that the AI is designed to be offered a limited number of choices per force pool.

1. Is it worth seeing what sorts of flags the AI most likes to use and will pay for? -- given that movement almost seems an irrelevancy in its calculations, the ones I'm considering are trying to benchmark cost/benefit against amphibious, paradrop, invisible, and hidden nationality ... we all know the AI "likes" these but how much?

If the results of (1) are at all encouraging I might even try a mini-mod, insurgency / counter-insurgency: three Civs, one "neutral" (Agression = 1) armed with Ye Old Benchmark 5/5/1; and two with Aggresion =5: the first of these latter would have recourse to the 5/5/1 as well as "counter-insurgency" units (let's face it - the ultimate "Black Ops" team would use ALL the flags I mention) whereas the second aggressive Civ would the benchmark as well as "guerilla" units utilizing hidden nationality and/or invisible flags.

2. My other idea is to attempt to discover what the ultimate (i.e., largest possible) "menu" of force pool items is for the AI, once again concentrating on land-only, non-bombard units. Given the inherent (and real-world, logically bizarre) nature of some of the force pool picks, I'll begin with the "knowledge" that the AI did choose reasonably well in the test utilizing three units where A+D=10, with one flagged O, one O/D (ironic: in American medecine, "OD" is a medical abbreviation, for "Over-Dose", as in a potentially lthal amount of drugs ...) and one marked "D".

I think I would begin this SEVEN units with:

6/4/1 HP=1 = O
7/3/1 HP=1 = O
3/2/1 HP=2 = O
5/5/1 HP=1 = O/D
4/6/1 HP=1 = D
3/7/1 HP=1 = D
2/3/1 HP=2 = D

I know there are arguments for and against this approach, but it has the virtues of (i) staying within the very little we know = e.g., A=D, etc.; (ii) offering a wide enough range of units to see what sort of (hopefully) curve is generated.

-- Thoughts, feedback, etc.?

Best,

Oz
 
I read most of the posts and I came across one about a dive bomber with precision bombing ability. Is it possible to make the Arty/Cannon/Catapult air units, not immobile, and have precision ability. Would they then function as well as AI bombers (which at the least is better than AI bombard units)... They would be destroyed instead of being captured by ground units. I can't test this now, because I'm at work... The only problem with this is they might be able to travel over the sea, but they could be flagged as wheeled and you could make coast/sea/ocean Impassible to wheeled... I'm hoping we could at least have the same results as the dive-bomber. I wonder if this would cause the Artillery to fly across the screen, like it was a bombing mission.... :hmm: Maybe this would not work... Let me know what you think...
 
LouLong,

Why do you qoute me on a comment made on
artillery and then start to talk about navies?

Where is the logic?
I always appreciate when people answer when I
talk to them.

----------------



I am still frustrated by AI:s inability to
use Artillery in a relevant way.

My next experiments will be directed toward that.
I think there is still some work to do here.


Rocoteh
 
I am interested in this artillery bombarding problem... It is now a vendetta... I will know the AI secrets on why it does not like to bombard offensively :devil2:

I've taken the time to recap what we know about AI bombarding...

  • It seems to make no difference in AI unit choice if bombardment is set to 1, range 0 OR 100, range 0. Defensive bombard strength is not a factor in AI Bombarding...
  • Defensive/Attack values greater than 0 have no effect on AI Artillery Bombardment use...
  • The AI tends to mass the majority of its artillery in cities to repel invasions. But will not bombard enemy units outside its cities even though there is no risk to doing so...
  • high ROF with lethal bombard has no effect on AI artilley bombardment...
  • Increasing or lowering the bombard range has no effect on AI artillery bombardment...
  • AI Artillery will offensively bombard ships, but does not seem to do the same with land units...
  • Multirole AI Artillery (A/D + Bombard) values does not effect AI bombarding...
  • Defensive bombarding is always 1hp and seems unmoddable...

Would it be possible to increase the strength of tile improvements and buildings in cities, so that the AI would be more apt to bombard units instead of cities. This would force land units to almost exclusively do the pillaging or destroying of tile improvements and city buildings would remain virtually untouched until the discovery of precision bombing. Maybe this with my idea above about making arty air units might work... If no one wants to test this I will in about a week, since now most of my attention is going to my retreat study over in GD
 
BomberEscort,

I agree 100% with you.

In fact I have decided to allocate all my experiment-time
to artillery. I will proceed with that until I reach a point
where I think there is nothing more to do.


Rocoteh
 
Defensive bombardment and modding is an intresting issue... and the sooner it's resolved, the sooner Kryten can focus all his attention on all those ancient light infantry animations I'd like to download... :D

So, I decided to do a little test on my own, and got some good, and some pretty wierd results. I lined up the following:
The defenders:
Egyptians (defenders on grassland, 10% def bonus)
50 warriors 1/1/1 (the test "base case" without Defencive bomb.)
50 "archers" 1/1/1, bomb 1/0/1 (i.e. range 0, firepower 1, RoF 1)
50 "longbows" 1/1/1, bomb 100/0/1 (i.e. range 0, firepower 100, Rof 1)

The attackers:
Romans (attacking from grassland)
150 warriors 1/1/1

They were all lined up, so no stacking producing promotions. All units were set to exactly two (2) hit points. Why? Well, the theory is that when a unit with Defence "1" gets shot at by a unit with bombardment "1" there should be about 50% chance of him losing 1 hp. The more hitpoints a unit has, the less important is the defensive bombardment, so therefore -> low hitpoints.

(at first I tested with only one hp with wierd results - I hadn't checked "leathal bombardment"!:lol: )

Ok, here are the results, in the format uninjured attacker/injured attacker/injured defender/uninjured defender:

50W vs 50W: 7/18/15/10 i.e. 50% wins for the attacker, but the attacking units on the average somewhat more injured. Fits well with A1 vs D1 on grassland.

50W vs 50A : 7/12/16/15 i.e. 38% wins for the attacker, with winning attacker s somewhat more injured than winning defenders. This fits well with defensive bombardment 1 having 50% chance of injuring an attacker on the way in. Half the attackers will be down to one HP when the fight starts, which corresponds to 25% chance of winning, the other half will be at full health, corresponding to 50% chance of winning (ignoring grasslands 10% def mod). The average of 25% & 50% is 37,5%.

50W vs 50Lb: 7/11/20/12. This is where it gets wierd. As you recall, I'd given the Longbows exactly the same stats as the warriors/Archers, except for a whopping 100 defensive bombardment! The result? Almost exactly the same as for defensive bombardment 1! :eek: :confused:
How can this be? I can only think of two possible reasons:
1) Defensive bombardment has a approx.50% chance of succeding straight up, all the time. (hope not!)
2) My test has missed something. For instance, what if (defencive) bombardment is based on bombardment strength vs Defence but that there is a "probability cap" of some sort, say at 50%?

So, I'll run another test with unit strengths at 10/10/1, the archers still at def bomb "1", the longbows at def bomb "100". If there is a loss of efficiency for the archers, we shall know that defence hase some importwance at least...
 
Originally posted by Rocoteh
LouLong,

Why do you qoute me on a comment made on
artillery and then start to talk about navies?

Where is the logic?
I always appreciate when people answer when I
talk to them.

Answer : the fact you posted a message does not mean I will be responding within the 5 next minutes because I don't spend all my time here (though I come quite often) and I have not registered threads.

Now what is wrong. I replied within a post to
1 -your message about NAPP artillery where I acknowledged the fact you mentionned.
2 - since there had been some posts about navies (% of troops, etc...) I gave these examples that show a nice AI navy. Since the last conformist raised the topic of it, I put @ last conformist and all (because others might be interested in that).
It seems you use one message per topic which I used to do but my post counts would rocket skyhigh.
So basically there are two parts in the post and you definitely did not have to feel attacked by it.
Now what is wrong here is that the pictures failed to show so I guess I am still wrong with that feature.
 
Now, please can someone tell me how to make the pics show ?
Normally I don't use multi-picture in one post but it seems the upload (bottom of the page) process did not work for me.
 
Clarification,

Due to the insults directed against me by LouLong
in 2 threads I have decided to stop communicate
with him.

I have never been interested in throwing dirt at others.

-----------

Back to topic, I will resume experiments with artillery.


Rocoteh
 
Originally posted by LouLong
Now, please can someone tell me how to make the pics show ?
Normally I don't use multi-picture in one post but it seems the upload (bottom of the page) process did not work for me.

In the lower left hand of the scren you will see this box

You may post new threads
You may post replies
You may post attachments
You may edit your posts HTML code is OFF
vB code is ON
Smilies are ON
(IMG) code is ON

click on the (img) for a quick tutorial... it is fairly simple, but you need the right file types.... gifs or jpg's I think.

Also, when making a link of any type remmeber the files are case sensitive, and if you used a common name, (say Germannavy.gif, it may have been used before, so check the files if you ised a name that may have already been used.
 
Originally posted by Rocoteh
Kryten,
Here are the results of the test you proposed:
10 rounds were made. Numbers= surviving defenders
"Slingers" 0,2,1,2,1,2,0,1,1,1, =11, 1,1
"Mortars" 1,1,2.0,3,2,2,0,2,2, =15 1,5
"Lightning" 3,2,1,2,5,3,2,2,2,0 =22 2,2
This experiment 5 confirms 4b.
The question is: Are modders in general aware
of these numbers when setting shield-costs?
Edit: The Lightning unit added had 200 in Bombard Strength.
Rocoteh

Thanks very much Rocoteh. :)
So 'defensive bombardment' does depend upon the bombard factor verses the target unit's defence factor.
Whew! That is a weight off my mind! :D

Just to remind people of the factors Rocoteh used in the above experiment:-
"Slingers" had a DB of just 1 (so weak that they might as well have had none).
"Mortars" had a DB of 20 (so had a good chance of getting that 'hit').
"Lightnings" had a huge DB of 200 (making that 'hit' just about guaranteed).
Now it may seem strange that the "Lightnings" massive defensive bombardment only made a relatively slight difference over the "Mortars" survival rate. But we must remember that the bombardment factor ONLY increases the 'chance' of getting that one-and-only 'hit'; i.e. the bombardment factor (no matter how large), does no damage in itself....it is just the chance of hitting the target.

Originally posted by Iztvan
How can this be? I can only think of two possible reasons:
1) Defensive bombardment has a approx.50% chance of succeeding straight up, all the time. (hope not!)
2) My test has missed something.

A good test Iztvan, but I think you may have forgotten something.....

Originally posted by Iztvan
They were all lined up, so no stacking producing promotions.

It is my understanding that units will only use 'defensive bombardment' if they ARE stacked.
One unit on it's own cannot use DB....but others stacked with it can.
So in your experiment, NO unit was actually using DB.

(Could someone please confirm this, as I have been wrong before in this thread! :lol: )
 
Gentlemen -- just a quick note that "real world" issues are going to keep me very busy for the next 2-3 days; I nevertheless will try to run the tests I mentioned at whatever odd hours are available. -- I think we're doing great work and I don't want my comrades to think I'm slacking off!

--BTW Rocoteh GREAT testing :goodjob: and Kryten you're as insightful as ever :thumbsup:

As for everyone else -- :worship:

:D ,

Oz
 
OK, so I had this idea, how to make an atar unit that can stop retreats. I could only think of one way, knock it -4 hp. That way it will always be 1 hp, and units fight to the death if the defender is down to one hp.

But would the ai build it?

Well, I set up three cities, the 1hp unit had a 16/16/1, about 4 times the power of other units, it also had ZoC, no maintenance....

regardless, my mod starts with air units, sea units, etc. I was pleasantly surprised. Not only did it build these 1 hp units, instead of a 3/4/1 +1hp unit for the same cost, it also continued to build "bombers" and a ship, as well as some cultural buildings.

In fact, it was regulary, in three cities building 3 different units. (I was using leaders to rush them)

The only surprise? Instead of the 50 sh. 3/4/1 +1 hp "cybersoldier", it built the 30sh. 3/1/1 no maintenance "Blitzdrone"

I know this is in no way scientific, and does not give hard data, but it does really shoot down some assertions I have read here.

Allthough I wish I could control what the Ai builds, honestly I would rather it just build even "lesser" units by random chance, because I do not believe the ai would, could even begin to understand if a no maintenance unit is worht the price.

A theory? The Ai will build with more variety if it is much more powerful than it's opponents. But I am going to set up a test scenario.
 
Hi Neomega :)

A few points --

1. Re: building three unit types at once -- I'm relieved, but I'd also point out that I, at least, haven't done any rigorous testing with flags like ZOC, etc. -- Indeed, despite the test reults to date, I'd certainly HOPED the AI would build paratroopers at the same time as regular infantry, etc.

2. Likewise, there's yet to be any rigorous comparison of maintenance vs. no maintenance units.

So no assertions shot down yet :D as I think most of us have been following several reasonably rigorous step-by-step approaches -- Rocoteh, aided by Kryten and egged on by BomberEscort :thumbsup: has been especially thorough vis-a-vis artillery -- and I still don't think the AI will build more than 2 unit types UNLESS flags are involved.

The reason I'm agonizing over what test to do next myself is that there obviously quite a few flags -- and thereby so many combinations of flags -- and there's no reason to assume that the AI's valuation of combination of flags will in anyway be mathematical ...

-- My kingdom for a methodology! ;)

Anyway, as I said, I'm very pleased by your results and would be delighted if you kept a "weather eye" on how the AI reacts to the presence of various flags and combinations of flags.

Best Regards,

Oz
 
Back
Top Bottom