 |
|  |
 |
|  |
 |
|
squid
|
|
quote: Originally posted by Urban Ranger
A neural network is not necessary for better AI routines in games such as civ. A good positional evalution algorithm will be a big help. Heuristic algorithms are definite possibilities, though I doubt any Firaxis programmers are trained in AI. |
The best post on this thread so far. I'm a Comp Sci grad, and he's on target here. Unfortunately, Civ is a difficult AI problem.
1) Branching factor. Each player can make possibly 3000 different actions for a given turn.
2) Horizon effect. It may seem completely irrelevant to the AI that I am moving my muskateers to Rhode Island, up until the point that I launch the ship, sail over to England, and take London. An AI would have a certain level at which (due to time and memory constraints) it could not plan ahead.
Chess is a harder AI problem than checkers due to the branching factor and horizon effect. Go has an insane branching factor. Civ3 is far worse than any of them. In Chess, it may be safe to look 15 moves ahead with reasonable certainty, but in Civilization, you have to plan for the entire game.
Also, it's not a zero-sum game. There are no winners and losers for every action. And the knowledge of the board is not 100%. A true non-cheating AI has to deal with unknowns!
So, all in all, I'd say the Civ AI is semi-rule based, with lots of heuristic evaluators. It doesn't plan ahead, but if it sees a city is a threat or an enemy is to strong, it may attack. The attack will not be overly strategic, but it will be made to achieve an immediate end.
Anyhow, it's a complex problem. With early 90's hardware, I can see why Civ cheated so much. From an ethics standpoint, I would not allow instant wonder construction, but I can see why it might be needed. Yet, even through the cheating, it was a very good game and the Civs put up a good fight. I'm sure the AI will far exceed Civ2.
|
|
|  |
 |
|
squid
|
|
One thing to note about AI in games.
Often they do well because they are not focused on a goal. They are mechanical, like ants, and never tiring.
In Warcraft II, for instance, the AI could control every peon and warrior simultaneously, if it wanted. It did not have to be looking at a certain corner of the map.
Similarly, with Civ, the AI does not grow tired fully developing it's terrain and laying railroad track over the entire continent.
It is at the same time very patient and slow. So, in some cases, moving without a plan and evaluating things a move-or-two-in-advance (not 50), allow for a better infrastructure and a more-balanced Civ.
I always find I build up enlightened but small countries. I have massive technological ability and great weapons, yet, not many units. So I overextend in combat.
The "dumb" AI improves most of his cities in the same way. He has a lot of weak cities, but lots of units ... as a result, he conquers the globe and builds mediocre cities....yet, my wonderful paradise (all hand crafted) cannot match the AI's numerical superiority and attention to detail.
|
|
|  |
 |
|
Urban Ranger
|
|
Apolyton Duke of Off-Topic
|
|
quote: Originally posted by squid
So, all in all, I'd say the Civ AI is semi-rule based, with lots of heuristic evaluators. It doesn't plan ahead, but if it sees a city is a threat or an enemy is to strong, it may attack. The attack will not be overly strategic, but it will be made to achieve an immediate end. |
I agree that the AI for TBS should be driven by heuristic evaluators that chooses from a set of rules to execute. I disagree though that it can't (or won't) plan.
quote: Originally posted by squid
It may seem completely irrelevant to the AI that I am moving my muskateers to Rhode Island, up until the point that I launch the ship, sail over to England, and take London. |
Assume the AI has this info. It will have to be really dumb if it doesn't do anything when it sees your ship, loaded with brutes, is heading straight towards its country. 
quote: Originally posted by squid
Anyhow, it's a complex problem. With early 90's hardware, I can see why Civ cheated so much. |
Given that the minimum requirement for Civ 3 is a PII-300MHz, there should be plenty of horsepower for the AI routines. A TBS game can always take advantage of the CPU idle time, plenty of which will be available, to crunch the numbers.
quote: Originally posted by squid
It is at the same time very patient and slow. So, in some cases, moving without a plan and evaluating things a move-or-two-in-advance (not 50), allow for a better infrastructure and more-balanced Civ. |
It does need an overall plan though, probably determined by a particular computer player's "personality" and some other factors (e.g. Civ 3's civ-specific abilities, to head towards a rough direction.
|
|
|  |
 |
|
Tingkai
|
|
To find the Northwest Passage
Aug 2001 time: 13:15
|
|
quote: Originally posted by squid
1) Branching factor. Each player can make possibly 3000 different actions for a given turn.
Anyhow, it's a complex problem. With early 90's hardware, I can see why Civ cheated so much. From an ethics standpoint, I would not allow instant wonder construction, but I can see why it might be needed. Yet, even through the cheating, it was a very good game and the Civs put up a good fight. I'm sure the AI will far exceed Civ2. |
Squid: that was a very informative post. A couple of questions, since you seem to be quite informed on this subject.
How did you come up with the 3,000 number?
How much of an improvement can be achieved with newer hardware?
Any thoughts on where the AI will improve?
|
|
|  |
 |
|
Edward
|
|
quote: Originally posted by squid
One thing to note about AI in games.
...
They are mechanical, like ants, and never tiring.
...
Similarly, with Civ, the AI does not grow tired fully developing it's terrain and laying railroad track over the entire continent.
...
The "dumb" AI improves most of his cities in the same way. He has a lot of weak cities, but lots of units ... as a result, he conquers the globe and builds mediocre cities....yet, my wonderful paradise (all hand crafted) cannot match the AI's numerical superiority and attention to detail. |
Hey! That dumb AI's strategy sounds a lot like my usual one. Semi-ICS continual expansion like a plague and lots of weak mediocre cities. Similarly, the AI's wonderful paradise of huge cities can't match my numerical superiority.
Turn based games allow very patient humans to concentrate on every unit just like an AI.
I think the Civ AI would benefit from long range plans and better unit movement tactics. Pairing every attacking catapult with a corresponding phalanx should be pretty easy to program. If all they did was set a couple cities towards making an assault force over the span of a few turns, then sending that assault force all at once to a human city, that'd be a great improvement. (Of course this would require either naval assaults or a much better understanding of how to tactically move your troops up to a city. All ten of the AI assaulting crusaders ending their move on a grassland square right outside my city would NOT be a big improvement. The AI must understand stacking, counter attacks, and how to time their troops so they'll all be able to attack all at once. Seige tactics of fortifying good defensive units in defensive terrain adjacent the target city or timing 2-move units to all start just outside of counter-striking distance would be good too.)
|
|
|  |
 |
|
The Mad Viking
|
 |
of the Great White North
Feb 2000 time: 05:15
|
|
I really don't think it would take too much to make major improvements.
Militarily, Edward has it about right:
quote: Pairing every attacking catapult with a corresponding phalanx should be pretty easy to program. If all they did was set a couple cities towards making an assault force over the span of a few turns, then sending that assault force all at once to a human city, that'd be a great improvement... The AI must understand stacking, counter attacks, and how to time their troops so they'll all be able to attack all at once. Seige tactics of fortifying good defensive units in defensive terrain adjacent the target city or timing 2-move units to all start just outside of counter-striking distance would be good too. |
Not building the same wonder in 3 cities at the same time-
Not building Copernicus in a city with no trade and no library...
Having a counterattack unit included in city garrisons, instead of just 5 riflemen, how about 3, a cavalrly and a cannon!
Not having a warrior attack a pikeman on a hill.
Not having small island civs that don't build triremes and settle the next continent asap... or at least start trading...
Smart things I've seen the Civ2 AI do:
Attack my city with a fighter first, to use up my fighter scramble, and then follow with 3 bombers
Move their capital to a 1 size city on my continent just before my dip was about to incite a revolt. (It was loaded with units.)
|
|
|  |
 |
|
Peter Triggs
|
|
Gone Fishin, Canada
Jan 2000 time: 05:15
|
|
quote: Originally posted by Big Crunch
Maybe its just me, but I would be unnerved by an AI that can beat you without having to cheat. (That is once you have become somewhat of a veteran).
|
Here's one for you BC. I remember reading it in some AI thingy, but I can't remember where:
quote:
Remember, if we ever really could get computers to be intelligent, they might decide that they had better things to do than play games.
|
|
|
|  |
All times are GMT. The time now is 05:15. Apolyton Time is 00:15. |
top of page
|
| archivepost |
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
|
|
|
|
|
|