Brad Wardell's views about technology, politics, religion, world affairs, and all sorts of politically incorrect topics.
Published on May 10, 2006 By Draginol In GalCiv Journals

Last week I was in south Texas on vacation.  A lot of Spanish speaking people down there.  For years, I've told my wife that for the 3 years I took spanish the only thing I remember is "Donde esta la pluma" (where is the pen).

We were at an ice cream place and the lady behind the counter, having taken someone's credit card said "donde esta la pluma". My moment had come.  My entire life was merely preparation for this one moment.  This was the time for me to shine -- where everything was coming together.

I quickly said to my wife and everyone else in line "She wants to know where the pen is! I KNOW that phrase!"  I finally felt like a big man.

Writing computer AI, on the other hand, is not a fast track to feeling like a big man. I read the AI suggestions people make. And most of them (okay some of them) are well meaning.  But most of the suggestions fall into the "Well duhhh.." category.

The main reason why computer AIs in games tend to suck is that the people programming them aren't good at strategy games and so they can only incorporate their own ideas into it.  Since I'm a strategy game maniac, the limitation has more to do with programming.  I know how to beat the AI at the highest levels in certain circumstances. And it's very hard to get the AI to deal effectively with it when it's playing at the resource level as the human player.

Some people actually believe that the AI should be able to beat an expert player when the AI only has the same resources as the human player.  That's not going to happen any time soon. Not until processors are a LOT faster.  Right now, while the human player is taking their turn, the AI is putting together its strategies. It's adaptive in a given game. But there's only so much that can realistically be done.

One of the most common suggestions is to improve the sensor capability of AI ships.  The problem is, I barely make of sensors on a per tile basis.  Instead, I'll have it scan through ONCE per turn and set various flags on a sector by sector basis.  The reason for that is time.  A given sector has 15x15 tiles.  That's 225 tiles per sector.  That's 73,000 tiles in a huge galaxy.  If a given player has say 300 ships doing their thing and you have 10 players that could be an immense amount of "looking".  That's one reason it's so hard for the AI to get that "first strike" thing.  But there are countless other things like that.

That is why in 1.11 we added a new option (which needs to be renamed) "Intense AI" (that's what I think it should be called later). If that's selected, i'll have the AI make use of new algorithms that do a lot of checking.  I can have the AI do a lot more analysis.  I can have the AI create armadas (groups  of fleets) and other such things that are just too CPU intensive (O^2) for now. Hopefully people have found 1.11 to be somewhat smarter on AI that previously. I will continue to enhance the main AI as well.

The reason why players and reviews praise the GalCiv II AI is that relative to other games, it is quite strong. Compared to some fictious perfect computer player an expert may find it lacking.  But reviewers and players can only compare it to other games to be fair.  And there's a lot there that it can do.

For example, the AI, without having to mod anything, will automatically adapt to user-mad mods. That's one advantage of not scripting it.  You could redo the tech tree, you could replace the units, change galaxy sizes, play on custom maps with custom ships, etc. and the AI will adapt to a varying degree of gaming.  When someone says "The AI is easy when I play on tough on a gigantic galaxy with tight clusters" my inclination is to make tight clusters no so tight rather than putting in weeks of work to try to get the AI to deal with such a specific circumstance.  Realistically, tight clusters on a gigantic map is effectively like saying you want the game to be easier. Which is fine. But if you want more challenge, turn up the difficulty.  Tight clusters allow players to turtle in and build up.    I do have some ideas though for making things more challenging at that specific level.

Still, there's only so much challenge you can have if players are going to hit Ctrl-N until they get some idealized galaxy set up and then complain that the AI wasn't challenging enough when given the same resources when the poor AI got stuck with 1 planet in the corner while the player got set up in a "cluster" with 5 class 15 planets with super-super planet bonuses (yes, we can tell how many times Ctrl-N was pressed in a given saved game).

But I won't get to do AI stuff this week.  I'm currently visiting Microsoft on business in preparation for Windows Vista so my AI coding will have to wait until I get back.

AI programming is my main area.  I wasn't particularly involved on the Diplomacy AI stuff.  I've started getting more involved and will conitnue to start to look more at it.  In the expansion pack, I want to throw in a lot more types of things to diplomacy.  I also plan to change it so that gifts and such give you a set relations bonus that can be limited to stop people from gifting their way to victory (gifts should help but they should be part of an overall package).

So my AI moment will come just like my Spanish moment will come.

When the ice cream lady heard me yipping away she said "Gringo es estupido". I don't know what that means but I assume it means Guy is smart or something like that since I'm sure she was impressed that I knew and announced to everyone that she was looking for a pen.


Comments (Page 2)
3 Pages1 2 3 
on May 10, 2006
... it's so hard for the AI to get that "first strike" thing.


That's why it is good that you are switching back to the GalCiv I style combat in v1.2. Why was the attacker shoots first model adopted for GalCiv II? Why did it take so long to determine that it unbalances combat in favor of the human player that can exploit it? Playing the Dread Lords campaign on level Tough I did not lose ANY COMBAT SHIPS that I designed and built (just the slow core ships that you get at the start of some missions) even during the Salvation mission where the Dread Lords started forming fleets! In previous updates you addressed lesser ship combat balance issues (Nanno Rippers and Logistics); I wish you had made the switch then but better late than never.

That is why in 1.11 we added a new option (which needs to be renamed) "Intense AI" (that's what I think it should be called later).


Metaverse scores should be higher for players that select this option, once it actually does something. Also, with each release the game gets harder at the higher levels as you improve the AI and remove exploits (like attacker shoots first) and the Metaverse scores should reflect that too.

In the expansion pack, I want to throw in a lot more types of things to diplomacy.


Looking forward to that! I would like to see the UP play a larger role.
on May 10, 2006
... it's so hard for the AI to get that "first strike" thing.

That's why it is good that you are switching back to the GalCiv I style combat in v1.2. Why was the attacker shoots first model adopted for GalCiv II? Why did it take so long to determine that it unbalances combat in favor of the human player that can exploit it? Playing the Dread Lords campaign on level Tough I did not lose ANY COMBAT SHIPS that I designed and built (just the slow core ships that you get at the start of some missions) even during the Salvation mission where the Dread Lords started forming fleets! In previous updates you addressed lesser ship combat balance issues (Nanno Rippers and Logistics); I wish you had made the switch then but better late than never.

That is why in 1.11 we added a new option (which needs to be renamed) "Intense AI" (that's what I think it should be called later).

Metaverse scores should be higher for players that select this option, once it actually does something. Also, with each release the game gets harder at the higher levels as you improve the AI and remove exploits (like attacker shoots first) and the Metaverse scores should reflect that too.

In the expansion pack, I want to throw in a lot more types of things to diplomacy.

Looking forward to that! I would like to see the UP play a larger role.
on May 10, 2006
Damb double post! I swear I only clicked Submit once! After I clicked Submit the page reloaded as blank. I click Page Reload and got an error. Repeated and got another error. When I finally got the page to load to see if my post was received, it was showing a double post!!! I see Frogboy/Brad has a double post too.

With the success of GalCiv II , there is a lot more traffic on the forums and the servers are straining to keep up! Time to take some of those profits to upgrade the servers.
on May 10, 2006
I think you should display all this kinda of info (CTRL-Ns, Cluster type, etc) in the metaverse, and then let us sort by it. Then we can easily see who is cheesing the game, and who is playing normally.

I admit to using tight clusters, but I didn't know it made the AI 'weaker.' However, I am guessing making the AI 'harder' by using no clusters doesn't boost my metaverse score at all, now does it?
on May 10, 2006
Gringo means foreigner in Portuguese not Spanish Of course answers.com link provided has some interesting comments to say hehe
on May 10, 2006
Not everyone knows that they are "cheesing" the game. That is why I asked what the optimal game settings are for the least amount of "cheese". I like playing the more difficult games on smaller maps, but you don't get very good scores for that. The easier games on the much larger maps with abundant planets and loose/scattered systems give you the highest scores for some reason, even though those are the easiest games to win. (At least for me, but then one of my main strategies will give me a greater bonus the longer the game is played.)
on May 10, 2006
I just don't understand while many of the planets I conquer from the AI have 4 or 6 embassy and or more improvements on them instead of factories. If the AI had built factories or research items on them it would have created a more substantial fleet invasion tech defense for my assaults.

I have played mostly on large maps and I seem to see this when the AI has 8-15 planets. Even those planets safely in the middle of his empire have embassy improvements. This seems like a waste. Is their a reason they are not building factories instead of 4 to 8 embasses?

The first thing I do when I conquer them is to delete the morale upgrades and convert the embasses to factories.
on May 10, 2006
Which player, which version?
on May 10, 2006
I just don't understand needing to use ctrl+N that much. Granted, I have yet to play on the higher difficulty levels, but I don't know that I've ever had to regenerate my maps. Maybe I've just been lucky, but I have yet to have be stuck with a truly terrible starting position. I always have at least a couple halfway-decent planets within a sector's radius of my homeworld, and that's generally all I need to get a good start on things.

Oh, and I always play with stars set to the "widest" dispersal. (Is that called the "scattered" setting? I forget.) It just strikes me as slightly cheesy and unrealistic to have all the stars clumped together in groups.
on May 11, 2006
Which player, which version?

Cripes I just wrote a long message and the sever ate it on the submit.

Short answer, 1.10 game with caris memory upgrades installed on the fly.

9 AI all gifted, painful. The korx and iconian then yor and torian ai all seemed similar with way to many 4-6 embassy on most planets. Only Large map.

It seemed that most ai got about 9-12 planets each, I started with 9 planets and was very vulnerable early but once my trade kicked in I rolled over everyone. I was surpriseed on how easy it became became and the lack of factories on the ai planets.

I can e-mail a copy of the saved games to you as I saved them by phase around every 10 turns or so.
Some just before I invaded an empire will show there state of affairs before I rolled over them.
on May 11, 2006
Which player, which version?

Cripes I just wrote a long message and the sever ate it on the submit.

Short answer, 1.10 game with caris memory upgrades installed on the fly.

9 AI all gifted, painful. The korx and iconian then yor and torian ai all seemed similar with way to many 4-6 embassy on most planets. Only Large map.

It seemed that most ai got about 9-12 planets each, I started with 9 planets and was very vulnerable early but once my trade kicked in I rolled over everyone. I was surpriseed on how easy it became became and the lack of factories on the ai planets.

I can e-mail a copy of the saved games to you as I saved them by phase around every 10 turns or so.
Some just before I invaded an empire will show there state of affairs before I rolled over them.
on May 11, 2006
I admit to using tight clusters, but I didn't know it made the AI 'weaker.' However, I am guessing making the AI 'harder' by using no clusters doesn't boost my metaverse score at all, now does it?


IIRC, Brad mentioned in a previous journal that tight clusters are worth less points on the metaverse.
on May 11, 2006
Hey Frogboy, on the same subject above, Just started a new Large map with 9 players all on Genius AI. Steadily increasing the difficulty level.

Just ended the colony rush and established diplomatic relations with all players.

I noticed that evryone including me has only 6 or so planets, down from around 9. Thats 60 or so habitable planets down from 90 with the same settings. Is this random variation or did you guys change the starting mix. I may not have contact with all races so maybe I am missing someone with a large empire.
on May 12, 2006
Realistically, tight clusters on a gigantic map is effectively like saying you want the game to be easier.


See, I just don't buy this. My ships are, *invariably,* faster than the AI's. If I spread out the galaxy more, it only stands to reason my speed advantage would be *bigger.* I would understand if I had the only good cluster in the galaxy, but with 9 other players, even spamming ctrl-n *some* would have better positons than me, and some worse.

Still, I'll try it without any clustering and see if it's more difficult.

As for AI faults... well, as I was crushing the Altarans (slightly ahead of schedule. They stumbled on my three dozen transports with 4 billion soldiers each in a staging area near their border. As my territory was wedged between theirs and the Torians, I couldn't really hide them. But hey, I had four ships, and a TREMENDOUS tech lead, that's enough for a war. . .) I noticed that their planets had made some. . . poor choices on construction. One planet had *five* improved farms, one in a bonus tile (the others ignored the farm bonus tiles that were present.) It had. . . zero moral improvements. If he hadn't been shipping off colonists for his war with the Korx every few turns, that would have been one unhappy world!

Unless, of course, they could go next door, were there were five multimedia centers, and not a single farm. Those people were happy, but never did any work (no factories.)

There were several worlds without even a single factory that were otherwise highly developed (PQ 10+, all tiles full or nearly so)

And, of course, there were a million embassies -- but that's already been mentioned.

This was in 1.1 Memory Test 13, for reference.

So I'm thinking, limited computing resources or not, there's still a tweak or two that could improve things. . .
on May 12, 2006
Still, there's only so much challenge you can have if players are going to hit Ctrl-N until they get some idealized galaxy set up and then complain that the AI wasn't challenging enough when given the same resources when the poor AI got stuck with 1 planet in the corner while the player got set up in a "cluster" with 5 class 15 planets with super-super planet bonuses (yes, we can tell how many times Ctrl-N was pressed in a given saved game).

that's the reason why I don't like too much random things happening at start

I would be in favor of an option to lessen the random distribution at game start so that :
every race has at least x "good" planets in the vicinity and that those planets have the same "value" of improved tiles

if less randomization happen at game start :
-some players like me won't feel the need to hit CTRL+N until we feel that some AI has not a so huge advantage
(yeah I'm rather unlucky with game starts often if I cheat to see the whole map, some AI will have all the awesome planets (20+) around his start position )
-neither players nor AI, will have too much advantage or disadvantage from the start
-quick & easy win with a home planet having +1000% industry on two tiles won't happen anymore...

thanks for taking the time to read this

edit: on a side note I try to counter this whole random thingy with better home planets & home solar system for everyone
3 Pages1 2 3