paint-brush
Advantages of AI in Gaming: How We're Creating Smarter Competitionby@aleksandrpindyk
357 reads
357 reads

Advantages of AI in Gaming: How We're Creating Smarter Competition

by Aleksandr PindykOctober 12th, 2021
Read on Terminal Reader
Read this story w/o Javascript
tldt arrow

Too Long; Didn't Read

Aleksandr Pindyk has been developing AI (artificial intelligence) for one of the most popular online games - World of Tanks. He explains why artificial intelligence is being introduced into competitive and cooperative games today and how the development teams of such games use AI as a helpful development tool. He says the main element of these games is PVP format (Player versus Player or Team versus Team) but why are artificial intelligence in these games? There are many reasons, but I would focus on the main ones: AI helps players to grow their skills.

People Mentioned

Mention Thumbnail

Companies Mentioned

Mention Thumbnail
Mention Thumbnail
featured image - Advantages of AI in Gaming: How We're Creating Smarter Competition
Aleksandr Pindyk HackerNoon profile picture


My name is Aleksandr Pindyk, and I work at Wargaming Kyiv studio. For several years now, our team has been developing AI (artificial intelligence) for one of the most popular online games - World of Tanks. I want to talk about why artificial intelligence is being introduced into competitive and cooperative games today and how the development teams of such games use AI.


Spoiler alert: Not only as opponents for the players but also as a helpful development tool. Let's start by looking at what competitive and cooperative games are. The primary game cycle is PVP format (Player versus Player or Team versus Team). Often, at the initial stage, they did not even assume the presence of bots controlled by artificial intelligence, for example, World of Tanks, PlayerUnknown's Battlegrounds Mobile, Fortnite, Overwatch. For instance, in other projects, Counter-Strike: Global Offensive, StarCraft, Escape from Tarkov, bots are added only in one of the modes. But all these games have one thing in common - the main thing for them is players' opposition to each other.


Today, such projects are present on large platforms like PC, Xbox, PlayStation, and mobile Nintendo Switch, iOS, Android. Another essential element of competitive games is that a game session usually lasts from 5 to 45 minutes. It allows more people to play who don't have much time for long sessions. Another and, perhaps, the main reason for the popularity of such games is the emotions that a player receives from defeating another human player. But if the main element of these games is the confrontation with other players, then why are artificial intelligence in these games?


There are many reasons, but I would focus on the main ones:


  • Assistant and opponent who helps players to grow their skills

  • Variety of gaming experiences by adding PVE mechanics and game modes

  • A tool that allows developers to make games faster and better


Assistant and Opponent Who Helps Players Grow Their Skills


The threshold for entering PVP games is often not high, except for projects designed for hardcore players (hello Escape from Tarkov). But the skill level for becoming a good player is high enough. A good picture of the principle Easy to Learn, Hard to Master. Usually, the only way to improve your performance is to play with opponents and learn from your mistakes repeatedly. For hardcore projects, the basic gameplay and the rules by which the player can achieve the first positive results may be completely incomprehensible.


Even in most popular games, it is not always possible to pick up opponents who are slightly better in skills than the player himself. Such matchmaking (player selection system) would allow the user to quickly learn the game without falling into the battle with professional players. Because those professionals will win in 100% of cases, and newcomers will not even understand why.


In addition, today, players are not ready to spend a lot of time understanding the game, going through the repeated path of trial and error, and even more so on in-depth analysis of their mistakes. There are many multiplayer online games on the market. As a result, the frustrated player leaves and communicates to his environment that the game is challenging, uninteresting, and generally do not worth the time.


On the one hand, this creates a negative opinion about the game, and on the other hand, further enhances the outflow of newcomers. And this leads to the fact that players with high skills have few opponents and less motivation to return to the project. And what are they? That's right, and they also leave because the game is "uninteresting, and generally bad." And so, to solve this problem, two strategies are perfect: initial training with bots and opponents-bots for new players.


For example, in games such as World of Tanks and Hearthstone, a tutorial scenario is automatically enabled for beginners. The player goes through several stages, where he is introduced to the basic mechanics using real examples and allowed to defeat his first opponents - bots. It creates a positive experience early in the game. Mastering game mechanics by solving practical problems is better than wading through many texts and pictures that the player is likely to miss.


Another challenge that AI-controlled bots can solve is finding a suitable opponent. For example, in games such as World of Warships and PUBG Mobile, the player, going into their first real battles, actually often plays with bots 100% or partially. And often, the players don't even notice it! For example, while playing PUBG Mobile, I realized that opponents are bots only after taking my 3rd TOP-1 in a row 😊. At the same time, opposing bots usually play better than bots from training, and the difficulty gradually increases for the player, and he does not lose too often. That allows separate newcomers from professional players — such an approach used in World of Tanks matchmaker.


Another challenge for AI-controlled opponents is populating regions with a small number of online players. This situation can occur in a large number of time zones on one server. For example, when America, Europe, and Asia players are on the same server, there are time zones where only a small number of players play on this server.


AI bots are a good tool for training. Moreover, this is true for both beginners and experienced players. For non-team games, where the one versus all mode prevails, it is essential to practice the skill of shooting, overcoming some obstacles, working out the development mechanics, and testing the equipment and its combination.


If a beginner must learn how to shoot and hit, then for an experienced player, it can be training to find vulnerabilities, shoot from a complex weapon, or test the terrain on which the fight takes place. For team types of play and the previous factors, it is also essential through training with bots, without revealing your strategy, to hone the battle plan, team interaction, study of cards, and possible combinations for the game.


Variety of Gaming Experiences by Adding PVE Mechanics and Game Modes


As we talk about above, the main thing in multiplayer games is the opposition of players to each other, player vs. player.


But sometimes, this type of battle gets boring, and the player wants "something the same, but different." Close the game, start another? Not necessary. And here is artificial intelligence comes in. After all, the primary way to diversify a PVP game is to introduce PVE (player vs. environment) modes.


The goals and benefits of such game modes can be different:


Time-Limited In-game PVE Events


Often these are additional game modes and are held for a fixed time, and upon their completion, the player receives a special reward, which is not available in the standard PVP mode. For example, World of Tanks has a Halloween event ("Mirny-13") that appears once a year and allows players to get a different gaming experience. Yes, for almost 11 years, everyone has become accustomed to the fact that "tanks" are 15 vs. 15, where you need to defeat a team of players. PVE mode allows you to look at the game from a different angle, distract yourself, get rewards by completing the entire event, and use them already in regular PVP mode. At the same time, the event itself pushes gamers to constructive interaction and a joint search for winning strategies, which increases the involvement in the project.


Content for Casual and PVE-Only Players


Even in PVP games, there is a category of players who only play PVE events most of the time. And the new modes are a reason for them to return to the game. After the event and receiving the reward, and some players start to play the PVP mode again.


PVE Game Mechanics


One of the options to diversify the PVP mode is to introduce different character skills, which AI will use in their work. For example, this is a call for helpers who will attack opponents, thereby helping the player (DOTA 2, League of Legends). Summoned bots that controlled by simplified artificial intelligence, which usually has one goal. But at the same time, the bot must be able to find and select a target, move towards the enemy and attack him. The use of AI makes this assistant more natural and valuable and makes it possible to adjust the difficulty of such a bot for the enemy.


Game Economy Balance


PVE events allow you to balance the number of accumulated game resources. If players do not have enough in-game currency, meaningful event rewards can be a good reason to complete them. In turn, this will allow you to return to the PVP mode, already having savings comfortably. When players have a surplus of resources, rewards for the PVE events become more prestigious. Thus, receiving the award becomes an exciting challenge and a collectible since the practical benefits are less than the expended resources. And it returns the balance to the game economy.


Stories About the Game Universe That Help Create a Game Community


When the main game loop is PVP battles, it is difficult to tell any story about the game universe. With PVE events, it becomes possible to tell a small story about the world or characters. Wich promotes the involvement of players and the creation of a community around the project. Over time, this community itself begins to generate fan content around the game's lore, thereby increasing the interest and recognition of the project. For example, in the same Mirny-13 mode in World of Tanks, we created a story about events in a closed military city, came up with characters, and attracted the creators of Silent Hill to create the necessary atmosphere in the game - from opponents to musical accompaniment. Can this be imagined in standard battles on historical equipment of the middle of the 20th century?


During such events, interest in the project grows. Often, game bloggers and the media tell in detail about the event itself, strategies for passing, and getting the maximum reward. The players themselves actively discuss the regime at different sites, thereby involving more and more of their environment in the project. And this leads to a temporary increase in the audience, some of which converts into regular players.


A Tool That Allows Developers to Make Games Faster and Better


All of the AI use cases described above are related to player interaction. But artificial intelligence can be of great help to the development team as well.


Main areas of application include:


Level Design


Creating maps and arenas for PVP battles is a rather long and complicated process. Any changes to the arena mean a lot of testing. And in online games, level balance changes are a continuous process that never stops. But testing the geometry and balance of levels can be difficult and time-consuming for level designers. And we can use AI bots to reduce complexity. We can divide this process into several stages. The first is testing the geometry of the level. Create script for bots, which forces them, for example, to drive across the entire map. Thereby we can check if all passages for all types of vehicles and units are available and no dead zones. Also, we can check shots from different places and understand the effectiveness of cover, sniper points, etc. The details of such scenarios depend highly on the gameplay, but the basic idea of level testing is suitable for most games.


The second stage is checking the level balance, which is especially important in games where there is a team-versus-team battle. At this stage, we run a large number of matches. During that battles, we are collecting statistics about everything that happens in the battle. This allows us to conclude different gameplay areas. For example. Which team wins more often and why, where and how the bots are driving, at which points the battle is taking place, which positions are good and bad, whether the covers are working correctly, etc. In this way, you can speed up the iteration of the level balance change. The third stage is testing the level by the development team against bots. That will make it possible to understand how the arena is understandable to a human player. At the same time, it is not necessary to involve a large number of people.


Adding New Game Mechanics and Testing Balance Changes


When introducing a new mechanic into the game, we need to check it. The easiest way to do this is by using bots as opponents. That will allow you to understand how effective the new mechanic is. By teaching bots to use the new mechanics, you can understand how good it is when the enemy uses it against us. AI bots are good for getting statistics on balance adjustments.


In addition, you can conduct a large number of combat simulations to obtain statistics and compare them with the past. And if you split the bots into two teams, give one new capability, equipment characteristics, etc., and then compare them in a battle against old bots. We are guaranteed to get the same level of play from bots, and the difference will only be in those aspects that we want to test. In the end, bots do not have a subjective opinion, and their results are pure statistics that allow you to make accurate conclusions about changes or new mechanics.


Load Performance Testing


A critical aspect of PVP games is the server's stability, subject to the constant development of the project. To achieve this, we need lanch many battles with bots. That allows us to check such product areas as load limit and server stability, network infrastructure operation and throughput, load balancer, monitoring, and logging systems, automatic launch of new servers when load increases, and code stability. Since there will be many matches, we will get errors that local testing cannot catch.


Functional Testing


To be sure of the quality of the code, as well as when refactoring it, the developers use special test scripts for the bot, which cover the verification of the basic mechanics. Scenarios can be simple or complex. An example of a simple scenario: a bot stands still and must aim and hit the target with all types of weapons. An example of a complex scenario: a bot must appear, find cover, take cover and hit the target from there, reload the weapon, move to another target, and so on until it hits all the targets on the level.


Many such scenarios can be created and go through on an ongoing basis, thereby helping to identify problems in the early stages after changing the code or adding new features. After going through the entire list of scenarios, the system generates a report. You can understand the state of the project codebase and the stability of the game's functionality. Also, using bots, you can check the stability of the game client. AI bot can go to all places on the arena and interact with all the level elements. While bot journey, we collect statistics and can find a drop in FPS, some errors in the client, or even a game crash.


Conclusion


Even though for competitive and co-op PVP games, the main mechanic is the confrontation of players, but the development of AI for such products has many advantages. On the one hand, this is a help for beginners. On the other, a variety of gaming experiences.


For the developers themselves, this is a helpful tool that allows you to automate many checks, including those that are associated with a large number of battles, as well as help designers develop new mechanics, make changes in the balance, and test their theories outside of the players at an early stage. At Wargaming, we actively use AI for both players and developers, saving significant resources and delivering a better product to players.