Civs the AI plays the WORST

They're working on the AI now. They didn't want to work on it while things were constantly in flux, such as the merging of sorcery/summoning which would've meant a lot of wasted time on AI work.
 
Luchuirp and Amurites seem to always die early in my games (well, one of the two, Im usually playing the other). Usually due to the fact that the Luchuirp do not like to build golems and the Amurites dont build mages when controlled by the AI (at least up to Monarch difficulty).

Has anyone done a guide on how to program the AI for these? I'd be willing to give it a shot if someone could give me some pointers.


One thing that has helped is to select the AI No Minimum Levels option.
 
I disagree with the Illians being bad, they can get very powerful
I've lost count of the number of times the Illians built samhain only to die to the very barbs it spawned. This was pre 0.40 so it might have changed but I haven't seen anything in the changelogs about it.


As others have mentioned the Kuriotates often dies to early rushes. If by some miracle they survive it doesn't help since the AI hasn't got a clue how to handle sprawling.
 
There are 3 civs which always do badly in my games because the AI can't handle their special mechanics:

Luchuirp are horrible because they don't know what to do with Barnaxus

Kurio are also horrible because the AI's individual city management is poor and so it's much better with 10 normal size cities than 3 super ones

Khazad pay too much attention to their gold mechanic and underexpand and research in the early game, putting them in a hole which they never get out of
 
I agree that in general,the Khazad do badly in most games. They expand slow and rush for RoK, which makes them very weak.

In my games the Kurio grow fast and are often mixing it up amongst the score leaders until the midgame, but then they crash and burn.

I have had games in which the Luchuirp have been very powerful, so I would hesitate to put them in the very weak category. As for the Amurites, they don't always die, but they are rarely the superpower.

As for Bannor, I mentioned this already, but I have personally never seen them engaging in a crusade. I won a game once because of it, since a crusading Bannor would have exterminated me, but still, to me this is the most unique Bannor feature, so I think it bad that the AI doesn't use it at all most of the time.
 
I have found that the Khazad actually do quite well with an advanced start. However without an advanced start they usually are quite stunted. To make it a fairer game, if I choose the dwarves to be present, advanced start is always how I play.

Recently I have also seen the AI Luichirp come after foes with Empower IV-V Mobility I golems, which is pretty scary. I can and do have individual units that are much better (Combat V being twice as good as Empower V) but every Iron Golem they build gets empowered right out of the gate. At some point in this game, the Luichirp lost Barnaxus and they lost their momentum. I think the new AI coding that makes the AI value higher experience units and heroes more helps the Luichirp a significant amount.
 
Yeah Khazad and Kurios really struggle. AI doesn't understand how to set up given the unique playstyles (not sure that I do either, but that's a different story ;)

I've seen a lot of variation in Grigori and Luichirp, which I bet is due to whether or not the adventurers / Barnaxus survive. AI seems to do better now at valuing its high level units, but maybe not at protecting the young heroes before they become powerful? ... just speculating there.

Amurites were very powerful in my last game, they know what to do with Firebows (and upgraded "Fire-qubuses"), but i didn't see any sign that they were doing much with Govannon. Actually I was impressed with improvement in the spellcasting in general, they were spamming fireball and some kind of Hold spell pretty effectively.
 
As for Bannor, I mentioned this already, but I have personally never seen them engaging in a crusade. I won a game once because of it, since a crusading Bannor would have exterminated me, but still, to me this is the most unique Bannor feature, so I think it bad that the AI doesn't use it at all most of the time.
I suspect the -90 on AiWeight in CivicOptions has something to do with this. Maybe if it changed to 90, Bannor will always launch a crusade on war.
 
like many others, I'll say that the AI fares terribly with Luchuirp ( can't handle golems well ) , Khazad ( can't handle vaults well ) , Kurios ( can't handle sprawling cities well ) and Bannor ( they seem to beeling bronzeworking before getting any decent economy ) .
 
also Khazad and Luchirp, they usually don't build more than 3 cities. IF they build more, they "get along". I'm playing on warlord-noble though.
not sure if I ever played against big Illian and Doviello empires since 0.24 or something like that.
 
building mines everywhere even on food hill's tiles.

that's what i do. i value production over food. besides, what else are you supposed to do there? build a fort?

and also, i was playing a game with aggressive ai, and on about turn 50 everyone declared war on someone else, often ganging up on one person. I declared war on mahala, figuring he'd go down soon and i wouldn't have to worry about him. but after about 100 turs, a few sons of asena show up, and a little while later a whole army. i was playing builder style, and had to switch to making about 20 warriors a turn just to keep him off (he razed one of my cities before i did that though)
 
Has anyone done a guide on how to program the AI for these? I'd be willing to give it a shot if someone could give me some pointers.
No, but I probably could quickly enough. The problem with Civ4 itself is that while the AI has some good tools at its disposal with the various weight and flavor settings they also include a lot of random variables that end up breaking the AI in the end.

You can do a LOT to fix the AI without touching the SDK or even Python by simply reducing or removing a lot of the random chance values in the leaderheadinfos xml file and allowing the AI to use the flavor values. If you fix the way they build units and buildings and you'll solve most of their issues. The only thing they really need to 'fix' with code for FfH is getting the AI to understand and use the features, abilities, spells, etc.

Here are some examples of xml tweaks to play with from the start:

In Civ4UnitInfos.xml fix all of the <iPower> values for every unit to be a more accurate representation of the units combat abilities. The AI uses this to determine how strong they are and how strong their opponents are. Default Civ4 values are too low resulting in little difference between units that are substantially better than others. A good place to start is to match the iPower value to the unit's own iCombat (or for FfH specifically the average of the attack & defense strength) and then adjusting as needed for less obvious unit strengths. They will make better choices when deciding what tech to research, what units & buildings to build, what units to upgrade and when to go to war. Also in this file you can adjust the definitions for UNITAI and NOT_UNITAI to help the AI use units more appropraitely. A good example here is giving workboats UNITAI_EXPLORE_SEA as a 'NOT' unitAI value so the AI will only build them when they need them and not when they want to explore the sea a bit.

In Civ4LeaderHeadInfos.xml look for the various probabilities and reduce or eliminate their chance. Be careful, any value with 'prob' in it's name is a 1-in-this number probability unless it is set to zero which will mean never. The best example here is building wonders, a low value in that probability will force the AI to build wonders (and projects) even if it really doesn't want to. Set to zero and the AI will only build wonders that it wants (based on its evaluation of the wonder modified by flavors) when it can handle it. This is mostly true for all of the probability values for each leader in that setting it to zero won't disallow it, it will simply not force it. The values with 'rand' in ther names are a percentage chance, so the game generates a number between 1-100 and if less than this value it will do whatever it is. So 100 is always and zero is never. Flavor weights for the leaders can range from negative values to possitive values, try not to exceed +/- 1000 as the resulting modified value can crash the game or cause misleading bugs with overflows ('flipping' integer values).

For technologies, buildings, units and improvements the AI will evalute them very well based on what it needs. That value will then be modified by the flovors assigned to the leaders and the individual items as well as the AI weight, if applicable. Exceptionally high or low values for flavors will essentially force the AI's descision making process which can be handy in some cases with techs or units the AI would otherwise ignore. In general lower flavor values will result in more intelligent descisions IF the AI understands the full benefits. This might be tricky if the FfH DLL hasn't been updated to get the AI to understand and properly value some of the effects not present in the default game. At the same time, the flovor and AI weights can be used to encourage the AI to use stuff it normally wouldn't. Sometimes taking a backwards approach and instead discouraging the AI from something it seems predisposed to build a lot of will work better than encourage them to build something else.

For any of this to work you also need to be sure that everything in the game currently is consistant. As long as every unit, for example, follows the same rules for which UNITAI settings it uses than UNITAI weights for the leaders will work as expected. If anything is out of whack though... you're in for a lot of work and some frustration as was my experience when first working on the AI changes for TAM some time ago. I did an old tutorial for leader relations a while back, it shoudl still be burried in the tutorial board here somewhere, that should help with understanding the basics of the leaderhead file.

So there you go, a wall-of-text quick guide. :)

Disclaimer: This is all from memory so some of the file and value names used as examples may be wrong, but they should at least be close and give you somewhere to start.
 
Thank you, but that really only scratches the surface. Hopefully it'll give anybody interested an idea as to how to handle the Civ4 AI adjustments needed to 'fix' it for FfH.

Also, here's a specific fix you can try for starters since I saw another thread regarding the elves not building archers.

In Civ4LeaderHeadInfos.xml search for: <Type>LEADER_AMELANCHIER</Type> and the scroll down until you find these lines:
Code:
            <UnitAIWeightModifiers>
            </UnitAIWeightModifiers>

The new xml code should be something like:
Code:
			<UnitAIWeightModifiers>
				<UnitAIWeightModifier>
					<UnitAIType>UNITAI_CITY_DEFENSE</UnitAIType>
					<iWeightModifier>100</iWeightModifier>
				</UnitAIWeightModifier>
				<UnitAIWeightModifier>
					<UnitAIType>UNITAI_COUNTER</UnitAIType>
					<iWeightModifier>100</iWeightModifier>
				</UnitAIWeightModifier>
			</UnitAIWeightModifiers>
The result is that they will prefer building units with those UNITAI settings over others. It will not prevent others from being built and it will not prevent these units from being used for other purposes.

This will show a problem with the way UNITAI values have been assigned to units in FfH though. Many units have UNITAI values set for anything they can do rather than for what they do best. With the Civ4 AI what you want to do is use the UNITAIs to tell the AI what this unit should be used for and what it can not be used for, not everything that it can be used for.

So if we step back to the Civ4UnitInfos.xml file and look through you will see that units that really should never be used for specific things, hunters attacking cities or unpromoted grigori adventurers for exploring as some examples, do not have anything defined for NOT_UNITAI.

Its a lot to take in but it's a good example of how inter-dependant everything is in Civ4. Hopefully it'll show that in order to 'fix' the AI most of the work needed will be 'fixing' specific units, buildings and technologies first. You will want to look through the SDK code if you can and see how the AI uses things like the UNITAI types so you can avoid things like giving beserkers UNITAI_COLLATERAL even though they do collateral damage.
 
Anyone really interested in tweaking UnitAIs though should activate the cheatcode so they can see the information easier. Then hold CTRL while you hover the mouse over a unit in city view and it'll tell you how it ranks for each possible AI type. Amusing item of note: Stonewardens rank in for City Attack as their "ideal AI type" by quite a longshot :)
 
Faeryl seems to neglect her economy big time. I traded her education when I was already happily building vampires, running StW.

I just had to secure a fellow AV civ a fighting chance.
 
Back
Top Bottom