Building a better RTS AI. Typical map moves.

posted in DreamLand editor
Published March 13, 2024
Advertisement

This is a continuation of the Building a better RTS AI series from codeproject.com . I want to add an image and you can't add images on codeproject so I`m posting here.

To get a good RTS AI player the fog of war needs to be disabled for him, or in other words he needs to be able to see what his enemy is doing all the time. When building AI, playing with fog of war enabled is just a layer on top of playing with fog of war disabled mode.

Another thought. RTS games are in a way like FPS games. Although you have a lot of units you move them from place to place as one unit, like moving a FPS character. On a smaller scale, for example when they reach the destination, you might micromanage them, i.e. issue individual orders to subgroups of units but usually that takes place around or in the confines of a single screen. On a global scale you deal with one maybe two “FPS characters” (one for defense one for offense) in a game. These FPS characters (or one of them) are guarding the base/bases. If AI Player spots enemy units approaching a base he is guarding he must take action before enemy units arrive. Each new base is added in the guarded item list. Action is taken when enemy is spotted approaching but is still far away.

Bellow is a representation of the Lost Temple map from Starcraft.

Reading intention in a RTS is a lot like forensics science. You don`t know what`s in the criminal mind until there is a manifestation of intention. If there is a dropship near a starport in the enemy base(P1) you don`t know yet what he is going to do with it. If the drop ship boards combat units and starts heading your way ( I mean AI player`s way) you know he`s coming after you but you still don't know where he is going to hit(P2). If the dropship is in position P3 and the AI player has an expansion on the right side of his base he will read that the enemy will execute a “attack from high ground” move targeting the expansion. In theory when the enemy dropship is in position P4 it could steer back to the left and drop units in the main base but the probability of a move like that is low. The trajectory of the drop ship indicates that what is taking place is a typical drop near the expansion move. In fact the entire game is comprised from combinations of typical moves and that is something the AI player should take in consideration. In this case the AI should interpret the dropship movement as drop and attack from high ground while the ship is still in position P4. That`s all I had to say this time.

0 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Profile
Author
Advertisement
Advertisement