AI Issues in Dune Wars

Deliverator

Graphical Hackificator
Joined
Feb 12, 2008
Messages
4,806
Location
London, UK
I thought it would be good to capture and prioritise the AI issues in Dune Wars as it stands. I may not be able to fix the AI code myself, but at least if the issues are all recorded in one place someone who knows more about AI coding may be able to offer pointers/suggestions or take up the challenge themselves.

I'll start the list from memory and then I'll try and maintain it in this opening post. Initially these are in no particular order.

----

1. AI does not unload transports when in danger. This makes it easy to wipe out an invasion force before they have even unloaded from their transports.

A previous attempt was may to resolve this, but the code suggested by Sephi in this post lead to an infinite loop.

2. AI does not pillage harvesters as a human player would.

Possibly this might not be too hard to fix - effectively we need all terrain transports to consider naval pillaging (desert=sea in Dune Wars) as well as land pillaging. The AI does do naval pillaging in the vanilla game.

3. AI does not deliberately pursue non-vanilla victory conditions - Terraforming, Spice Monopoly, Holy War, etc

4. AI does not utilise Dune Wars espionage effectively

Espionage was significantly reworked in Dune Wars - see this thread.

---

I'm sure there are many more to add, but my mind is blank for now.
 
Great idea, those are certainly the four biggest.

Some other possibilities, where feedback might be helpful (ie they might not really be problems).
a) AI does not fully appreciate the value of tile-yield improvement techs. This could be alleviated by giving all such techs a "growth" flavor value, and assigning all leaderheads a flavor.
I think the original version had this, but I think I might have removed this along the way, thinking it was boring for every AI to have the same flavor.

b) AI does not understand the beelining possibilities in the tree; it will still tend to research "broad" rather than "deep", which can lead to the human player attaining a high tier unit (like Naib's Chosen, or Shield Troopers, or Kindjal Soldiers) long before the AI has sufficient defenders to manage it.
Not sure what a solution is, other than forcing more tech tree restrictions (which may be illogical and anti-fun) or reducing the successive increases in combat strength (what if we buffed up all the tier1 units?).

c) AI does not use aircraft very effectively, so human controlled bombing runs can be very effective on stacks that don't have interception.
This was alleviated a lot by increasing interception chances, but bombardment can still be quite nasty.

d) AI seems to poorly develop Polar cities; these cities always seem to end up undeveloped and weak, possibly because its too far for the AI to send enough workers, and it doesn't really seem to build many of its own there.
No obvious solution.
Though AI improvement underdevelopment might also be a consequence of not using the very powerful Serfdom civic; perhaps this civic should receive a nerf.

e) AI does not effectively defend its own harvesters, or attack units in desert tiles that are outside its city BFC. No obvious solution.


Will think about this more.
 
Hey there,

I recently discovered this mod and I thought I'd try my hand at tweaking the AI a bit. The ones that seem to be most doable to me are tweaking AI tech and implementing the pursuit of the terraform victory.

I wrote an AI mod for FFh2 (see sig), mainly using python in the cvgameutils.py file with the AI_choosetech and AI_chooseProduction functions.

I was not able to find that file in the dune wars folder. Any hints where I have to look?
 
Having some expert help on the AI would be fantastic. Are you familiar with "BUG"? I don't think FFH uses BUG, but BUG provides a lot of helpful routines to organize mods. All of the important changed code is in assets/python/DuneWars.py. There is a thread here about this file; it is a little old but these basic points have not changed. If you look at the beginning part of DuneWars.py, you will see how AI_unitUpdate is wired; you can easily wire the tech and production functions the same way.
 
Top Bottom