Overview #
The Role of an AI Programmer is to work closely with Design and Animation to breathe life into characters that make the world come alive.
To achieve this, an AI Programmer will develop systems for Enemies, Allies, and other NPCs (Collectively, “Agents”). The game will often need systems for:
- Navigation (NavMeshes, NavVolumes)
- Perception (Sight, Hearing, Damage/Injury, Team Alerts)
- Behaviour (Do I take cover? Attack? Disengage and return to patrol?)
The AI programmer will also need to examine how these systems interplay with each other.
- How is my behaviour impacted by my environment/effects/emotion (scared/angry)
- How do I coordinate my behaviour with other team/squad members for tactical plays?
- What do I do when I can’t navigate to my target?
And then we might need to think about optimizing for scale.
- What happens when our agent count goes 10x? 100x? For instance on a large open world.
- Can we have agents “think” less often if there are more of them? (i.e. only X number of agents get to evaluate new options each frame.)
- Can we push their decision making to other processing threads?
- Can we put agents to sleep if they’re not relevant (i.e. too far away)
- Can we have agents share information (i.e. pathfinding routes) if they’re close together instead of calculating for each one?
- How do we avoid ‘kiting’ large numbers of enemies? (impacting performance)
And along with all that there’s the most important goal: “Coming to life”. The goal of AI behaviour in games is often more about player perception of that behaviour and less about actual intelligence. This is articulated brilliantly in the following GDC talk by Kimberly Voll.
So that’s a general overview. Let’s get into some specific questions. I asked Slavomir Krbyla, formerly AI Systems Owner at Romero Games for his advice for anyone interested in getting into AI Programming.
Pros #
Why might a student want to pursue this role?
Programming AI for games is an intersection between technology and psychology. If you are looking for a technically challenging role, where solutions are often out of the box, this is a great fit.
Cons #
Why might a student want to avoid this role?
It is difficult to create game AI. Usually, a large number of NPCs need to look intelligent, without eating all the computation budget for the game. The complexity of algorithms can be much higher than in other game dev fields.
Example #
Something you did in this role as an example of the kind of work you get to do?
You need to face your creations in-game to evaluate them, and the resulting AI behaviour often surprises you. My favourite example is throwing a grenade into Swat squad that I was creating. It triggered an evade maneuver that chaotically repositioned survivors. Once the combat behavior started again, they assaulted my position from different angles, breaching through windows. This felt like a scripted ambush, but it was totally emergent.
Student Projects #
What kind of student projects would you recommend doing to prepare for this role?
Creating a project with basic stealth and combat in Unreal Engine to get familiar with topics like navigation, perception, and behaviour modelling is a great start.