Star Wars Republic Commando Designer Diary #6 - Artificial Combat
Programmer Nathan Martz discusses the trials and tribulations of crafting the Star Wars shooter's enemy AI.
We'll begin emailing you updates about %gameName%.
Next month's Star Wars Republic Commando will take you behind the scenes of the Clone Wars as the leader of an elite squad of combat specialists. In our fifth designer diary, programmer Nathan Martz discusses the intense process of crafting the artificial intelligence for all of the game's thinking entities.
Artificial CombatBy Nathan Martz, AI Programmer
When people think of game artificial intelligence, they tend to imagine something out of science fiction, like Skynet or Agent Smith--millions of lines of code written by a mad-scientist programmer in a dimly lit basement. The truth is that game AI is an intensely collaborative effort. The actors you see onscreen are the final product of years of work by animators, character modelers, sound engineers, programmers, and level designers. As enemy AI programmer, my work is more concerned with developing a framework for creating interesting gameplay than it is about evolving hyperintelligent programs. Without all of those other contributors (especially animators and level designers) the AI wouldn't exist.
There are as many ways to write enemy AI as there are games on the market. Every programmer has a different style, and every game has its own unique set of opportunities and challenges. Great AI isn't necessarily the smartest AI, but rather the AI that best supports the core gameplay and creates exciting, memorable moments. As a squad-based, gritty militaristic first-person shooter set in the Star Wars universe, we knew that we needed AI that was diverse, believable, and flexible.
Inspired by the wildly imaginative creatures in the classic Star Wars movies, we wanted a cast of AI characters that was as diverse as the Star Wars universe would allow. Unlike so many FPSs where the only difference between soldiers is the color of their pants, we created AI that had genuinely unique behaviors, strategies, and personalities. The final version of Republic Commando has more than a dozen non-player characters--including armored droids and agile insect warriors, flying soldiers and crawling drones, intelligent humanoid mercenaries and lumbering robotic tanks--and each has its own custom personality, weapons, and tactics.
We wanted AI that felt human; AI that was interesting and believable. Inspired by games like Halo and Half-Life, we knew that we needed AI that was intelligent, but fallible--AI that the player could learn from but eventually outsmart. Our AI never cheats (well, almost never). Like humans, they make their decisions based only on what they have seen and heard.
In a game as complex as Republic Commando and with the amount of freedom given to the player, it's critical that the AI be able to react to the widest possible range of player actions. We knew that we would need AI that could improvise in response to the player's decisions, unlike the scripted, sometimes brittle AI in other popular shooters. While we do use some scripting to create dramatic, cinematic moments, the vast majority of our combat is completely player-driven.
Even with these clear goals in mind, developing the enemies on RC was hardly without its surprises. Something we learned the hard way during the development of RC was that FPSs are, well, all about shooting things. That may sound obvious, but the implications aren't (or at least they weren't for us). The lesson for us was that hit reactions, weapon effects, and fantastic-looking death animations and rag-doll effects are just as important to creating the impression of fun and interesting AI as intelligence itself. After some pretty rough feedback during one of our focus group sessions, we completely rewrote the entire weapon effects, hit reactions, and death physics system. The final product is something we are very proud of, but it was something that we had to react to "on the fly" under already tight time constraints.
Developing the enemies for Republic Commando has been an enormously rewarding experience. We set high standards, worked hard to achieve them, and did our best to improve the game in response to feedback from our peers and potential customers. We've delivered a diverse array of believable, flexible, and intelligent enemies that are as fun to fight as they are to kill. It's been a blast bringing the Republic Commando enemies to life; we hope that you have as much fun fighting them as we had making them.
Got a news tip or want to contact us directly? Email email@example.com