Sign in to follow this  
Sandman

AI Generals: More interesting computer opponents [RTS]

Recommended Posts

In my opinion, the meat of any RTS game is in the skirmish missions. The campaign is good for one or two plays, but after that, the thing that keeps you playing are the single player and multi player skirmishes. One problem with the single player skirmishes, is that the computer opponents are too inflexible. They're often too well drilled and quick for newbie players to practice against, and too predictable and stupid to give the experienced players a reasonable challenge. Some games offer a choice of difficulty levels, maybe also some other tweakable parameters like starting resources etc, which goes a long way to making the single player game more accessible and interesting for a wider range of players. However, in the original Settlers game, there were a set of slider bars for each computer opponent which could be used to tweak a number of parameters which determined how the AI fought. This I think is a really good idea, and could be taken a little further. My approach is that instead of selecting 'Computer' as a computer opponent, you'd have a list of AI generals. There'd be a handful that shipped with the game, as well as the option to create your own. You could then select a particular general for each computer opponent, or set it to 'random' - in which case you have no way of knowing which general you're fighting - unless you can recognise them from their style. The real question is, what parameters could you use to define an interesting AI general? Here's a few I've thought of: Rank: Players in this game will have a rank, which will increase as they go. With higher rank come certain advantages, but also certain disadvantages, as the player is expected to achieve more with less. AI Generals do not change in rank, so this allows you to configure this parameter which will make a subtle difference to the number of units and amount of choice the AI has available. This will double as a general 'difficulty' level. Strategy: Is the AI a thinker or a doer? A very strategic AI might build a deep game tree which will make him tough to beat, but if you do something unexpected that forces him to change his plan, it will take him some time to construct a new one. A less strategic AI might be more reactive, with a less coherent strategy but better able to deal with the unexpected. Tactics: Is the AI a cunning tactician, or does he have the subtlety of a sledgehammer? Tactical AIs will tend to use smaller numbers of units in precise, complementary roles, whereas the less tactical AIs will attempt to swamp the player with a huge amorphous mass of units. Command Skill: How quick is the AI at issuing commands? AIs with a high command skill are able to issue many commands per second, those with a lower command skill may have a delay between each command, bringing their micromanagement ability more in line with a human. This will be useful for newbie players who get very frustrated with the computer's perfect micromanagement ability, although most players will probably want to leave it on max. Predictability: Does the AI go by the book, or is he a bit unpredictable? Predictable AI's tend to adhere strongly to an AI script, whereas unpredictable AI's might rely more on dynamic decision making algorithms. Aggression: Is the AI offensive or defensive? Aggressive AIs will actively hunt out the player, and attack him without mercy. Defensive players prefer to get dug in, and let the enemy come to them. Any more ideas, or general thoughts and suggestions on the subject? PS: I'm not too worried about implentation details at the moment, so don't worry too much about the practicality of actually implementing this.

Share this post


Link to post
Share on other sites
Personality: Is he likely to attack someone that didn't attack him? When attacked will he seek revenge, even when that damages his chances of winning or base all his actions on pragmatic thinking? Is he going to return the help he has received earlier in the game or is he going to stab his former allies at the first chance? Will he know the personalities of other generals and use them to his advantage or not?

Economic growth approach: Does he favor long term or short term economical/military growth? Does he expand fast neglecting defense or does he build strong defenses around each important economical location?

Share this post


Link to post
Share on other sites
Infastruture priority How much importance does the AI put on infastructure do they build just enough or more then enough.

Expansion Prefrence How does the AI prefer to expend is it through the founding of new settlements, or through the conquest of nearbouring settlement.

Diplomatic Stance Can the AI be reasoned with, do they prefer to open dialogs with other factions, or remaind solitary.

Combat style The AI's perfered approach to combat and units. Do they prefer cheap but large numbers of infantry or more expensive but faster tanks, or perhaps they prefer to gain total air supiority.

Share this post


Link to post
Share on other sites
Yes, but the enemy generals need to talk to you. Chatbox style, like in Unreal Tournament, with a little window and voice. Then you could give each AI general a unique personality. Otherwise, the "interesting AI parameters" mean nothing to the user.

Metal Fatigue had a large series of varied AI characters, but they were nothing but names, and they weren't described in the manual. So, all you know about General Mayhem or Lieutenant 'Leet is their names and their fighting. Its pretty opaque.

Worst of all, there was no difficulty setting secondary to this feature. So, you had to guess the difficulty of each general from their name.

Share this post


Link to post
Share on other sites
Have you guys ever looked at The Age Of Kings AI system. The standard AI's are not very good but you can script your own and make it really good. Some of the AI's people have scripted can give the experts a run for their money. For more info www.aiscripters.com and read the forums.

Share this post


Link to post
Share on other sites
Quote:
Original post by Pxtl
Yes, but the enemy generals need to talk to you. Chatbox style, like in Unreal Tournament, with a little window and voice. Then you could give each AI general a unique personality. Otherwise, the "interesting AI parameters" mean nothing to the user.

Metal Fatigue had a large series of varied AI characters, but they were nothing but names, and they weren't described in the manual. So, all you know about General Mayhem or Lieutenant 'Leet is their names and their fighting. Its pretty opaque.

Worst of all, there was no difficulty setting secondary to this feature. So, you had to guess the difficulty of each general from their name.


Yes, I think the settings should make a significant difference to the way the AI plays. It's interesting that this sort of thing isn't usually seen in RTS games, but is quite common in other genres, e.g shooters like UT and turnbased games like Civ.

The point about transparency is a good one. For the predefined AIs at least, we'd want to give the player a reasonable idea of how difficult an opponent they'll be, although bear in mind that players may find that they do well against some styles of play, but very poorly against others.

Quote:
Original post by Tallshortkid
Have you guys ever looked at The Age Of Kings AI system. The standard AI's are not very good but you can script your own and make it really good. Some of the AI's people have scripted can give the experts a run for their money. For more info www.aiscripters.com and read the forums.


I seem to recall that Age of Kings had quite good AI with a range of difficulty levels to suit a wide range of players, but I wasn't aware that you could actually script your own.

Unfortunately, AoK is unplayable on my system at the moment, so I can't really test any of them out. However, I'm really looking for a solution that will allow a casual gamer a certain level of control over the personality of his opponents, without needing to resort to scripting. However, I like the idea of supporting player written scripts.

Share this post


Link to post
Share on other sites
What I don't understand is why no one has made the AI act like a human. Or at least, why it doesn't seem like anyone has. A human has to observe their screen, select units, and issue orders, all of which take rather measurable amounts of time and all of which are done in basically sequential order via a physical interface (i.e., mouse and keyboard). A computer AI on the other hand can conceivably make snap judgements about a situation and give virtually simultaneous orders to all of its troopers directly to the program.

For example, within the first SECOND of a RTS game a computer AI on the *easiest* difficulty setting can have 4 peasants building 4 separate buildings, 2 peasants going to mine gold and the other 2 peasants going to chop wood. While the human player has to click peasant 1, click building type, click placement, click peasant 2, click building type, click placement, etc., etc.

Now why don't designers make it so the DIFFICULTY level of the AI is directly related to how long it takes the computer to perform each action? Say on Easy it would take a few seconds between each command (just like a human), while on the Hardest setting the comp would be going full force as fast as the CPU can perform the cycles. That way you'd emulate the fact that a human player has to take time to assimilate information, and take time to translate that information into action via a physical interface. The computer would act more "organic", and the players wouldn't feel the comp is "cheating" half the time. Heh.

Take care.

Share this post


Link to post
Share on other sites
Quote:
Original post by Heaven
What I don't understand is why no one has made the AI act like a human. Or at least, why it doesn't seem like anyone has. A human has to observe their screen, select units, and issue orders, all of which take rather measurable amounts of time and all of which are done in basically sequential order via a physical interface (i.e., mouse and keyboard). A computer AI on the other hand can conceivably make snap judgements about a situation and give virtually simultaneous orders to all of its troopers directly to the program.


Yes, I've always wondered that too. (This is what I was getting at with the command skill parameter)

I don't even think it would be particularly hard to implement, just a delay between each command, perhaps with a prioritising system so that urgent commands can jump ahead of less important ones that are already in the command queue. One reason I think that this has never really been implemented is that without their micromanagement advantage, the vast majority of AI's would completely suck against a human player.

Quote:
Original post by Gothard
ive incorporates all that into my game engine. thats been one of the the goals from the outset. the key was building an engine around the AI.


I'd be interested to hear more about this, if you don't mind going into a bit more detail. What configuration parameters do you support, how well does it work in the actual game, what specific implementation issues you came across etc.

Share this post


Link to post
Share on other sites
Quote:

What I don't understand is why no one has made the AI act like a human. Or at least, why it doesn't seem like anyone has. A human has to observe their screen, select units, and issue orders, all of which take rather measurable amounts of time and all of which are done in basically sequential order via a physical interface (i.e., mouse and keyboard). A computer AI on the other hand can conceivably make snap judgements about a situation and give virtually simultaneous orders to all of its troopers directly to the program.


Its because the AI is 'stupid', and would be slaughtered. Almost all RTS players find AI boringly easy as it is - imagine if that same AI was constrained to issuing orders at the pace of a human - it would become boringly easy to beat them. The actual plan formulating process of AI players, along with thier reactions to changes in situation, needs to be vastly improved before constraining AI with human input limitations would be a good idea. You also need to keep in mind that the better-skilled players, with the aid of some fancy specialty input devices, will be able to issue orders at whats normally considered a disturbingly fast speed, and for them to have any challenge at all, the AI must either cheat, or be as smart as a human opponent.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this