Game Features: AI
/Happy new Year to All! In the coming developer blogs we will introduce the main gameplay aspects of Ultimate General: Gettysburg. Trying to explain briefly the level of design detail, we will cover the importance of tactical factors such as morale and fatigue, the realistic map terrain bonuses, the accurate Line of Sight, how the battle escalates dynamically and generally what UItimate General: Gettysburg will offer to you once it is ready for release.
AI with no cheat bonuses
I always disliked the idea of giving statistical bonuses to the AI to make it more challenging, for example to give AI morale bonus to increase difficulty levels. Although this is a widely accepted practice to hide AI incompetency I think it provides fake experience and challenge to players. With this game project I had the opportunity as game designer to make an AI parametric system that simulates skills and aggressiveness.
So instead of making the AI harder by giving to the computer controlled units more statistical strength, in Ultimate General: Gettysburg we distinguish difficulty levels to different AI characters. Similarly as a human opponent can be tougher if he responds to threats faster and evaluates the state of game more effectively, this way we made AI to consider goals according to many different thresholds that control its behavior.
3 Difficulty Levels - 9 AI Personalities
In Ultimate General: Gettysburg before you proceed to battle you can select your AI opponent among nine different characters arrayed in three difficulty levels. Each level is represented by three AI Commanders that differ in playing style. So for example, the lowest level of difficulty includes the “Cautious”, “Opportunist”, “Risky” AI opponents.
Cautious is the most defensive AI Commander of the game preferring to shell you with cannons than to gain ground while Risky is an all-out attacker who can either outperform you fast because of his mobility or you can exploit his tendency to not keep enough reserves. Opportunist AI playing style is something between those two.
In similar manner we have the higher difficulty levels. 2nd Level of difficulty is consisted of “Defensive”, “Balanced” and “Offensive” AI commanders. Finally, the biggest challenge you get from the 3rd difficulty level against “Cunning”, “Dynamic” or “Determined” AI opponents who virtually have no major weaknesses but their very distinctive playing style provide a different “tactical flavor” according to your own playing style.
We have also a “Random Commander” button so that the AI commander is chosen randomly before the battle, consequently making you fight with a completely unexpected AI opponent and so your tactics will not be pre-determined.
AI making lines and flanking
The AI commanders in Ultimate General: Gettysburg can first of all make continuous lines of musket fire, surprisingly much better than an average player. The way that AI makes lines is based on a rather complex auto-targeting and auto-line system that simulates the real tendency of large human formations effort to connect and expand in battle situations.
That means we do not use a typical hidden formation block system that AI struggles to preserve in real time (seen in many real time strategy games) but instead we see AI to dynamically trace weak spots of your army, send there one or more brigades to attack by a continuous line that can shift, turn and expand according to nearby threats. As a result, flanking becomes quite naturally because AI will frequently create wider lines than you in a location, encircle and gain advantage before you manage to reinforce the area with more troops.
AI keeping reserves and using terrain advantage
Moreover, AI is able to keep reserves, something very important in the game because fatigue and morale are key elements of Ultimate General: Gettysburg. Consequently, in battles where many units participate from each side (much more than 30) you will notice AI to utilize reserve lines and keep high ground with artillery while it picks one or more weak spots of your army for its offensive operations.
Exploitation of weak spots and LoS
Many more tactical aspects such as importance of strategic locations, evaluation of an area for a charge or an organized fall back command are considered by the AI in real time whereas there is one more important feature which makes it impressive as an adversary: its talent to estimate Line of Sight (LoS). Because AI does not use cheats it also uses the same LoS that player has. So to make AI effective and not idle until it sees enemy we made it to evaluate non-visible locations and send adequate forces according to its character ability, simulating the instinct of a human player.
All in all, our AI is not scripted, not depended by a strict map scenario. Let me call it “alive”, it has in its arsenal a wide selection of tactical evaluation algorithms that are updated in real time and make it to respond promptly to player’s actions in any situation, using -as it is commonly known- a GOAP (Goal Oriented Action Planning) system that we plan to expand and make it even “brighter” as development continuous.
AI effectiveness on the long term
AI efforts to outsmart you have effect not only in single battles but also in future encounters. For example a defensive AI Confederate opponent would desire to not sacrifice many soldiers to gain ground in the first phases of the battle but when all his reinforcements arrive will have significant advantage for a decisive attack in 2nd or 3rd day. On the contrary a more offensive AI will try to gain momentum from early stages and this will bring the battle -tactically- to a whole different level.
I personally conceive this AI design approach to have similarities with chess, in which you can try many different tactics to win the game. This is what will happen in Ultimate General: Gettysburg as you may notice for example the Cunning AI opponent to not attack you vigorously in the 1st battle so you think you are winning and then use all his reserves in 2nd battle to smash your tired troops.
Read our first AAR
Husserl describes what awaits you in Ultimate General: Gettysburg in this AAR (After Action Report) http://forum.game-labs.net/index.php?/topic/468-aar-the-first-day-of-the-battle. The AAR shows how action starts for the Union in Ultimate General: Gettysburg and how our skillful AI personality “Determined” can out play you as Confederate (Graphics and Features are not final but belong to an early development version). We hope you will like the story and be sure we will provide more.