Jump to content
Please support this forum by joining the SH Patreon ×
Sturgeon's House

General PC games master race thread. Everything about games. EVERYTHING.


LoooSeR

Recommended Posts

  • 2 weeks later...

I had heard that Anthem went through development hell, and also that the gameplay (especially end-game content, or lack thereof) was disappointing.  This review really brings those two complaints together.  It really does look like the game was originally intended as a single-player experience, and that the multi-player aspect was grafted on hastily later.

Link to comment
Share on other sites

https://beebom.com/ubisoft-ai-gameplay-far-cry-watch-dogs/

Quote

   Now, while the game studio is gearing up for the release of Far Cry 5, the company has shared us some information about the AI being used to predict bugs in a game’s code that comes as a boon to the developers.

   Ubisoft has transformed the testing process of new games, allowing artificial intelligence algorithms to do the heavy lifting, freeing developers to focus on fixing bugs, rather than finding them.

   Dubbed Commit Assistant, Ubisoft says it fed the AI with over 10 years’ worth of code from across its software library, and allowed the system to learn where mistakes have historically been made. The system also referred to any corrections that were applied to games after release. It uses this data to predict when a developer may be making a similar mistake in new code. 

   Apart from Commit Assistant, Ubisoft is also focussing on AlphaGo, the AI system that they’ve embedded into their games. Ubisoft explained the working of their AI in their previous game, Watch Dogs 2. Using an example of a non-player-controlled car driving around the game’s virtual San Francisco, Olivier Delalleau, an AI programmer at Ubisoft,  showed how, initially, it would more often careen out of control when taking corners. The car was programmed with the goal of reaching a destination or looping the streets, providing visual flavor to the game world. Later on, the team made use of reinforced machine learning to train the AI. Effectively, cars learned how to take corners smoothly with the use of effective braking, which allowed Watch Dogs 2’s representation of San Francisco more realistic and reduced random crashes.

 

/.../

 

   Ubisoft also stated an example, in which they explain that when a player encounters a non-player character or NPC in Far Cry 5, two systems are at work: trust and morale. In case you aim your weapon at a stranger, they will react with distrust or fear, warning you to lower your gun. Additionally, if the NPC fears a threat from you, they will attack you, fearing for their own lives. Basically, Ubisoft has implemented the use of behavioral pattern analysis to drive an NPC’s actions. Additionally, if you face a group of enemies and you manage to take out the majority of the gang, the remaining players will attempt to flee as they may realize they’re outclassed. Similarly, animal companions will respond to player activity, cowing close to the ground unprompted when you crouch into stealth, for instance.

   The idea of implementing AI into games is to use machine learning to add a sense of depth and realism to the world while keeping the work of the development team as light as possible. This, in turn, allows the developers to focus on other aspects of the game. Additionally, it could also mean a lesser amount of time devoted to testing, thus bringing forth earlier releases of a game.

   Some of less visible changes in how AI works and used in modern games. AI use is going through extensive growth of aspects of gamedevelopment and gameplay where they are used.

Link to comment
Share on other sites

Killzone AI explained: https://www.extremetech.com/computing/75786-how-ai-works-in-fps-games/2

 

Quote

   Recently, at the European Game Developers Conference in London, Arjen Beij & Remco Straatman, two AI designers who worked on the video game Killzone described the process by which AI soldiers try and hunt the player.
/.../
   Killzone was designed for the PlayStation 2, so it operates under some constraints imposed by the console’s memory. That’s led to some design tradeoffs, which will be discussed later. Within the game, however, the AI code allows for up to 14 AI troops to act independently. All told, AI makes up about 12 percent of the CPU time, Beij said.

 

   Killzone‘s AI model pretty much begins and ends with the notion of cover: the ability to use terrain and objects to protect the AI, while attempting to deny that advantage to the player. Since the enemy AI is often on the defense, it does not use some of the other advantages offered to the player, such as stealth, although certain levels place the AI on the attack and the player on the defensive. In comments made after the presentation, Beij seemed to imply that the developers had placed more of an emphasis on individual soldier AI than on coordinating various squads.


   Sometimes, AI tactical decisions are predetermined by scripts. Designing an AI in such a way that it can fight for itself in a variety of situations, with minimal scripting help, is both challenging to the player and also frees the developer from extra tedious programming.


   In Killzone, the AI’s four emphases, according to Beij, are: picking a tactically advantageous position; evaluating the position; moving to and from position to position, tactically; and suppression fire.


   In picking a position, the AI soldier attempts to remain in cover, while attempting to breach the cover of the player, as well as react to external stimuli and AI soldier “orders.” In the real world, a soldier can look at a brick wall, pipe, or other object, and evaluate its potential for cover fairly quickly. In a game, however, the AI must know what it can or cannot “see,” as well as how that position varies as the AI soldier and player crouch or stand.


   The “reasoning” that the Killzone AI uses to understand this is based upon a series of invisible waypoints, scattered semi-randomly about the map. Each waypoint is placed about 2 game meters away from one another, and this is the means by which an AI soldier evaluates his position.

   The waypoints also indirectly solve the problem of how the AI “sees” if the player has taken cover, and, conversely, if either party has a line of fire to the other. For each waypoint, Guerilla Games has programmed in a lookup table, which acts like an old pen-and-paper boardgame. For each waypoint, in a given direction (as represented by a polar coordinate system) the AI soldier “knows” that the player either does or does not have cover for a given distance. If this system was not in place, the game would have to use a “ray cast”—actually trying to trace the line of sight from the AI to the target—instead of making a quick calculation.


   In this model, an assumption is made: for a given distance in direction, if a line-of-fire can be established from a given distance or position, then there is no cover available for the target. In reality, this might not be true. What this does do, according to Beij, is encourage the AI to search out positions where there is “guaranteed” cover. In the game, the AI tends to “hide” more, and this translates into an enemy soldier who wants to save his own skin, like flesh-and-blood soldiers do. In total, there are about 4,000 waypoints per map, but the lookup table requires only about 64 Kbytes.


   Now that the soldier has established his position, he must dynamically re-evaluate it, factoring in his programmed impulse to hunt down and terminate the player. In this case, the AI must fire and maneuver, but maneuver where?


   Surrounding the AI at any one time is a mesh of waypoints, again, about 2 meters apart. (They tend to be placed near walls and obstacles, instead of in the open, Beij said.) Remember that the AI soldier “knows” what waypoints will be covered, and what won’t be—an artificial but plausible advantage, as in the context of the game one can assume the enemy AI knows the ground.


   Typically, the AI chooses a destination and moves there. To determine the viability of the destination’s cover, the AI assigns values to each waypoint, with the highest scoring waypoint becoming the final destination. Values are assigned for factors like proximity to a given position; cover from a primary and/or secondary threat; outside the blast range of a possibly incoming projectile; in or out of a player’s line of fire; et cetera. In some cases (a large open field) searching for cover may place the AI in harm’s way, and so it stays put.


   Likewise, the Killzone AI assigns values on the intermediary waypoints on the route an AI enemy runs. This has the effect of forcing the AI to choose a tactically sound route; for example, it does no good for an enemy to charge headlong across a field of battle when it can move from cover to cover.


   From a CPU standpoint, evaluating a large number of waypoints taxes the CPU. Longer moves are also riskier, as the AI program may not have time to react to the player’s movement. However, evaluating positions close by may not give it the best tactical position – another compromise the PS2 forces. In actual gameplay, distances of between 15 to 20 meters are used, Beij said.

 

/.../

 

   The AI doesn’t reassess positions on the move, according to Remco Straatman, the lead AI programmer for the game. In some cases, however, the player moves, and the AI system “aborts” the decision, recalculating it. There’s also another weakness: 3D elevations. Because the waypoint system is two-dimensional, a map using several exposed staircases or cliffs couldn’t be used, as the waypoint system didn’t factor in these attributes, Straatman said. In such a scenario, an AI soldier could repeatedly try and access a position that was several meters above it.


   Evaluating cover also has a reverse effect; that is, if the AI knows what cover it has, it can also evaluate the cover used by the player, thus adding the element of suppression fire. Suppression “pins down” the target, forcing him to place his own survival at a higher priority than returning fire accurately.


   In Killzone, the AI figures out where the player can move to, where the player can fire upon the AI, and what cover the player will have both from itself, and from any neighboring attackers. In certain cases, the AI may also use a grenade or tank shell to flush the player from a hiding spot, using the blast radius to good effect. Waypoint weighting is used here, too, with one added factor—the AI soldier doesn’t want to blow himself up!


   That last point is yet another AI weakness, the designers admitted. No, a soldier doesn’t want to commit suicide; on the contrary, a real soldier sometimes decides to run and fight another day. Some games treat this using “morale,” where a soldier facing enormous odds will break and run, or at least pull back from a suicidal charge. Not so in Killzone, although that “feature” is being considered for future titles, the designer said.

   One advantage of a good AI system is that the techniques can be reused, with minor tweaks New levels can quickly be populated by “dropping in” enemies, seeing how the level plays out, and then tweaking the play with scripts or other alterations.


   Guerilla Games’ original AI model was used in a game called Shellshock: Conflict Vietnam, and will be improved upon before a new version of Killzone for the PlayStation 3 arrives sometime after the new console’s launch.

 

   I was searching for Far Cry AI description, but thanks, Google. Here is original 17 pages PDF on which this article was based on, for those who are interested.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...