Table of Contents
As a gamer, you probably already know that artificial intelligence is used to power Non Playable Characters (NPCs) and are aware of its presence within gaming. However, AI in video games goes much further than just NPCs; though that is, as you’ll discover, a huge part. In this article, we explore how artificial intelligence is used in video games and discuss the technology’s history in the gaming industry. Keep reading to learn more.
What Is Artificial Intelligence?
Artificial intelligence (AI) comprises software models and protocols that allow computers to act autonomously and, when machine learning is involved (ML), continuously learn from its experiences. Currently, one of the most prominent AI models is ChatGPT, which enables users to generate human-like text and have conversations in which context is understood. But ChatGPT is not the only type of AI available. In fact, the technology is finding its way into nearly every aspect of everyday life, including video gaming.
History of AI In Video Games
If you’ve played video games, you will have likely encountered artificial intelligence to one degree or another. For example, you might have played against “the CPU” in a team deathmatch on Call of Duty or simply against “the computer” on a mobile chess app. This type of AI in video games is so commonplace as to give it no thought; however, AI has been used in gaming since the arcade game era of the 70s.
One classic example of AI in video games is the ghost enemies in Pac-Man that try to catch the player while they collect points. The Pac-Man ghosts were programmed to exhibit different personality types aimed at deceiving the player into running into them.
Pac-Man was released in 1980, but two years before, in 1978, the world was introduced to Space Invaders. Space Invaders used a primitive form of AI to allow the aliens to follow random patterns, making it more challenging for players to beat the game. Of course, Pac-Man and Space Invaders have nothing on the complexity of artificial intelligence in modern video games like Minecraft to Skyrim, which involve the use of NPCs (Non Playable Characters) with minds of their own.
Top Video Games That Use AI
So, following on from the history of AI in video games, let’s now take a moment to explore some of the most prominent games that utilize artificial intelligence.
The Last of Us
The Last of Us leverages a Finite State Machine (FSM) that was most popularly used in the first installment of Half Life in 1998. FSM allows NPCs to follow certain states such as attacking enemies or searching an area until they hit a trigger point that prompts an event in the game, where they then transition into another state. For example, a character may defeat an enemy, triggering the next phase of the story, and then enter into a searching state wherein they explore the next area.
After learning this concept, it’s not hard to see how The Last of Us uses AI to enable different classes of characters to play different roles. A hunter, for instance, might investigate an area of the map in search of items that trigger events, while infected zombies might chase other characters it encounters, interacting with their environment in a way that assists their chase. AI in The Last of Us also means that some side characters and NPCs can provide help to the player by reviving them or finding key items.
Grand Theft Auto
The Grand Theft Auto series has utilized AI throughout its games and has been at the forefront of developing AI video gaming capabilities. However, the use of AI in Grand Theft Auto is most notable in its NPCs. There are two excellent examples of NPC AI at work in Grand Theft Auto: how drivers interact with the players driving and how pedestrians react to player behavior.
For example, drivers try to avoid the player if they approach at speed and find places to pull over when emergency vehicles are triggered–sometimes with humorous results as a result of the AI becoming confused in the chaos. Similarly, pedestrians will flee areas wherein players reign destruction or, in some cases, may challenge the player to a fight. In Grand Theft Auto Vice City, a cheat code can also be entered that gives pedestrians firearms to shoot at the player upon confrontation.
The Elder Scrolls
Radiant AI is Bethesda’s–the creator of The Elder Scrolls series–own artificial intelligence model that’s aimed at creating unique player experiences based on the player’s past actions and interactions with the environment. For example, players may be struggling to get through the story campaign on Skyrim due to enemy difficulty. In this instance, the Radiant AI might kick-in and reduce enemy difficulty to match the player’s ability, allowing them to move forward and encouraging them to keep playing.
Although Radiant AI is used across most Bethesda games, particularly The Elder Scrolls series, it’s perhaps most impactful in Skyrim. The Radiant AI means that Skyrim is played differently depending on the player, character attributes, and player ability, meaning no two playthroughs of Skyrim are the same.
5 Ways AI Is Used in Gaming
We briefly touched on some ways in which artificial intelligence is used in the above three video games, but let’s now take a deeper dive into how the technology is being utilized in the gaming industry as a whole.
-
Intelligent NPC Behavior
As we explored with The Last of Us and Grand Theft Auto, artificial intelligence is used to facilitate intelligent NPC behavior that creates an immersive experience for players. For example, as more games focus on open-world environments, AI-powered NPCs mean they can interact with the world in a realistic way wherein their actions have real consequences for side characters.
The generative world building game Minecraft is an excellent example of how player behavior can impact the lives of NPCs. For instance, if players find a village and decide to destroy its houses, the residents will wander around the area looking for shelter from rain and running from enemies that spawn during the night.
-
Aim Assist
When playing a first person shooter (FPS) game like Call of Duty or Overwatch, you may have noticed that sometimes your crosshair snaps to an opponent, making it easier for you to hit your target. This feature, known as aim assist, is more prominent when console gaming, as Xbox and Playstation controllers don’t allow the level of precision that a computer mouse does.
Essentially, aim assist is an AI-powered gaming feature that tracks an opponent in real-time and momentarily locks a player’s crosshair on their opponents “hit box.” This makes hitting targets easier and compensates for in-game lags or controller inaccuracies, reducing player frustration.
-
Improved Procedural Generation
Procedural world generation–where the game environment is produced in-real time, creating unique areas–has been attempted in many games since as early as the 1980s. However, it’s not always been particularly well-done. For example, Minecraft worlds are procedurally generated with random environmental formations, but each world has the same biomes and familiarity.
The space exploration game No Man’s Sky was able to take procedural world generation a step further by creating over 200 galaxies, containing a possible 18 quintillion planets to explore, all with differing environments and attributes produced upon discovery. While the game faced criticism from online gaming communities for its repetitive planets and boring gameplay, it has seen many updates since its launch.
Without creating environments that break the rules of their video games, procedural world generation is in a solid state. However, AI promises to elevate procedurally generated games by integrating procedural generation capabilities with NPC speech and graphic generation. Theoretically, this could lead to unique quests being generated within games for each new player, making procedurally generated games completely different for each player.
-
Dynamic Difficulty
Another use of AI in video gaming that we’ve already discussed is dynamic – or adaptive – difficulty. When dynamic difficulty is implemented into a game, artificial intelligence is used to monitor the player’s progress, behavior, and skill level. The game’s AI then determines how challenging to make the game, usually in terms of enemy difficulty, while still keeping it enjoyable.
For example, if you were playing Skyrim and died several times when trying to defeat a high-leveled enemy crucial to unlocking the end of a quest, the AI may identify your struggles and reduce the difficulty of the enemy, allowing you to move forward without becoming too frustrated. This ultimately serves two purposes: to keep people playing for longer and to improve the overall player experience.
AI Solutions From Idea Maker
If artificial intelligence is an area you’d like to explore further, whether to implement into your business or software project, or if you’re just looking for information, you’re in the right place. At Idea Maker, we regularly publish articles on a wide range of topics, from AI to website design. We also provide development services–you can schedule a free consultation to learn more.