Presentation is loading. Please wait.

Presentation is loading. Please wait.

Zubair Chaudary, Kenny Rentschler, Constantin Savtchenko.

Similar presentations


Presentation on theme: "Zubair Chaudary, Kenny Rentschler, Constantin Savtchenko."— Presentation transcript:

1 Zubair Chaudary, Kenny Rentschler, Constantin Savtchenko

2  Game Genre that involves projectile weapons  Played “though the eyes” of game character  First Person point of view  Creates a game play, AI, and game design Issues  Popular FPS Titles  Quake, Doom, Wolfenstein 3D, Goldeneye 007, Half Life, Halo, Call of Duty, Counter Strike, Unreal Tournament…

3  First known FPS: Maze War (1974)  FPS Stepping Stone: Wolfenstein 3D (1992)  Intro of Deathmatch: Doom (1993)  3D Polygons: Quake (1996)  Major Console FPS: Goldeneye 007 (1997)  Entirely Script Based FPS: Half-Life (1998)  Exceptional Plot and Story: Half-Life (1998)  Team play focused FPS: Unreal Tournament (1999)  New Millennium FPS: Halo (2001)  MMOFPS: Planetside (2003)  FPS as Story Medium: Bioshock (2007)  Graphics Killer: Crysis (2007)  $1 Billion Dollar FPS: Call of Duty – Modern Warfare 2 (2009)

4  Arguably the most valuable to the gaming industry  Envelope Pushing sector  Graphics, Game Play, AI, Audio  Genre Bending  Has created spinoff genres  FPS medium allows developers to incorporate elements from other genres

5  Movement Layer  Does not determine where to move to, only how to do so.  Avoid obstacles, follow characters, and path finding through complex environments  Animation layer  Selecting, parameterizing, and playing character animation sequences  Generating specific animations that are situational, and not pre- rendered/coded  Combat Layer  Assessing characters current tactical situation  Selecting tactics in combat  Performance is key, as this is the fundamental aspect of FPS  Behavior Layer  Determines character’s current goal, and attempts to reach its goal

6  Pathfinding  Dynamic Obstacles  Spatial Reasoning

7  Algorithms and methods to find most efficient movement from point A to Z  Most FPS levels tend to be static, so AI use a pre-generated Database  Allows for A* search algorithms

8

9  Situation changes significantly with the addition of dynamic level elements  Player can move objects in front of AI paths  Level Destruction can block paths  If the AI does not adapt, will walk into a wall and get stuck.

10

11  Handling of dynamic objects  Some games ignore them (pseudo random movement)  Introduction of Local Pathfinding  Uses Global Pathfinding to establish a general path from A to Z  Create lots of “waypoints” in-between A-Z

12  Local Pathfinding determines if subpath A-B are clear  If they are, continues to waypoint B, where it evaluates B-C  If not, it computes an alternate path to waypoint B  Local Pathfinding also uses A* search

13  AI Data generation tool  3D Pathfinding  Part of the Unreal 3 Engine  Management of perceptions (sight, smell, and sound)

14

15

16  Subsystem that performs tasks assigned by higher level systems  Performs discrete movement commands ▪ Move to (X,Y,Z)  Only be executing one movement command at a time.  Movement controller is an object that owns the current movement command  Can be use to handle different kinds of movement, like walking or swimming

17  When AI enters Combat, almost all control is given to combat controller  Attempts to assess tactical situation  Number of enemies, direction, health, ammo  More Advanced: cover locations, camping locations  Issues commands to other systems  Movement, aiming, shooting

18  Most difficult task for AI combat controller  Spatial Reasoning requires understanding of level (Spatial Configuration)  Needs to know where things are, and how objects are going be use  3-Dimensonal Levels increase complexity significantly

19  Pathfinding solution can be used  Pre-generate database of objects and their significance  Works poorly with dynamic levels  Level Designers can embed ‘hints’  Makes Level design cumbersome  Error prone  Customized tools analyze geometry  Can be run dynamically to populate database  Physical properties of objects?

20

21  We will use Valve’s Left 4 Dead to discuss and examine spatial reasoning.  Things to think about:  Navigating In 3D  Optimal Paths  CPU Calculations  Example comes from a presentation created by Michael Booth.

22  Path finding algorithms help AI’s navigate optimally through environments.  How do you define an environment? By using a Navigation Mesh!! Used instead of waypoints AI can move anywhere in between the grids. However note the Jagged Path.

23  We could hardcode a “smooth” path…  Or we could use what Valve calls “Reactive Path Following”…  Look ahead in the path and calculate  Use local obstacle avoidance

24  Oh, it’s a crate!?  We would press spacebar, and bunny hop over it, should be easy for computers right? Wrong

25  AI has to deal with the environment as we do:  Quickly  Efficiently  Humanly  Combining the two strategies we examined allows for an AI that deals with the presented necessities

26  An Example of a Tactical Situation  Current Location ▪ In cover, or out in the Open?  Ammo (unless they cheat)  Enemy ▪ How Many? ▪ From where?  Current Objective(s)  Behavioral Situation

27  Tactic Selection Problem  Nature of Tactic under Consideration  Relative Tactical situation of all combatants  Current Tactical Situation  Use of Tactical Library is common  FSMs  Databases  Databases with Q-Learning

28  Basic Tactics  Camp ▪ AI hides in a location, and waits for an opponent to appear ▪ Effective, but behavior can seem very scripted  Joust ▪ AI rushes opponent, while firing ▪ Runs past opponent with the hopes of being able to turn around and rush from behind  Circle of Death ▪ AI circles opponent while firing ▪ Keeps a variable radius away from target  Ambush ▪ AI ducks behind cover, periodically pops out of cover and shoots at enemy. ▪ Similar to camp, but AI must know where enemy is coming from  Flee and Ambush ▪ AI runs away from enemy, and then takes cover and gets ready to ambush

29  As games evolve, game designers strive to give players more freedoms:  Dynamic level designs  Interactive objects  Large, multi-approachable situations  We will study how AI has kept up through Killzone © ’s implementation.

30  Old AI would use “hints” and series of “if- then” scripts.  Hints remain static, rely on game designers  Enormous amount of effort for responsive AI’s to react to situations and terrain  The AI must take into account:  Multiple approach points  Dynamic environments  Dynamic positioning  End Result: Responsive AI

31  AI analyzes the situation  Inputs are dynamic  Using gathered information, the AI acts:  Goal setting/discarding  On-fly-algorithms allow for on-the-fly decision making  Tactics are procedures, not scripts  Summary: tactics are _______ based on the ___________ and the _________.

32  Killzone AI Summary  Accomplish goals, or change based on desirability/feasability  Move To Position, Do Action  Killzone’s describes situations:  Cover from threats  Lines-of-fire  Danger zones  Area of operation  Decisions made using:  Position evaluation  Line-of-sight and Line-of-Fire

33  The assignment of values to the waypoints of Killzone  Some factors that give higher values  Distance to primary target  Amount of cover  Not in the way of friendly-fire  Wall hugging  Outside of danger-zone (grenades, tank shells)  Position Evaluation Helps Movement  Tactical Positioning  Tactical Movement

34  Position evaluation functions assign values to the waypoints of Killzone

35  Tactical Movement is smarter movement  Movement usually done by “lowest weight”  Notice we can use some of the existing position evaluation algorithm to make “dumb” paths cost more ▪ Line of fire ▪ Close proximity to danger zones ▪ Running at the target

36  Position evaluation algorithms, can also be used for attacking  Indirect Fire ▪ Different determiners can be used to predict where to throw grenades  Suppression Fire ▪ Other determiner can be used to figure out at which cover to lay suppressive fire onto

37  Advantages  Parameterization – change values, not code  Easily adapted for other uses, such as multiplayer  Procedural tactics are easier to adjust, and work with – compared to scripts/hints  Removes extra ray-casts  Disadvantages  Difficult to debug, the AI is “on its own” – compared to scripts/hints  Also, difficult to get it to do your bidding – if you want to actually script something

38  Opponent Selection  How to Target? ▪ Most FPSs pit all AI against an enemy ▪ Kung-Fu tactics?  Need for Targeting Heuristic ▪ Tactical Situation Awareness ▪ Worry about defending itself first ▪ Most vulnerable, nearest target ▪ Ranking function can simplify  Need to be able to change targets based on changes in Tactical situation

39  To-Hit Roll  Less than perfect aiming for believability  Calculating factors ([0.0,1.0] range) ▪ AI skill ▪ Range ▪ Size ▪ Relative target velocity ▪ Visibility ▪ Target state ▪ AI state  Probability to hit = skill*range*size*…*state

40  Aiming  Cheat Angle ▪ Maximum that a projectile can differ from gun barrel while still being believable ▪ Doesn’t need to match line of sight  Location ▪ Point with high probability of being hit ▪ Model target as overlapping boxes and pick center of volume

41  Shooting and Missing  Pick point close to target ▪ Low probability of hitting  Should be visible to player  Missing when close and hitting from a far distance seems unreal

42  Ray Testing  Test projectiles trajectory before firing  Avoid obstacles and friendly fire  Dead Reckoning  Estimation of enemy position at given time  Shoot where the enemy will be when bullet arrives  Weapon Trajectories  Difficult to predict slow moving projectiles (arrows)  Use physics in ray testing to test trajectory

43  Collision Notifications  Projectiles store pointers to object that fired it ▪ On hit or miss object is notified  Helps firing object adjust targeting  Radius Testing  Helpful for area effect weapons  Treats everyone as cylinders or spheres  Tests area damage on everyone to avoid friendly fire and maximize enemy damage

44  Responsible for controlling current state and high level goals  Most FPS use a Finite State Machines  Idle – Standing Guard  Patrolling – AI following a designed patrol path  Combat – AI is engaged in combat and most control is given to combat controller  Searching – AI is looking for an opponent to fight or searching for an opponent who fled  Summoning Help – AI is searching for help

45 patrol search fight sound, patrol -> ɛ see, patrol -> ɛ see, search -> ɛ kill, ɛ -> searchkill, ɛ -> patrol quiet, ɛ -> patrol

46

47  Scripting and Trigger Systems  Need scripting and triggering events to tell the AI to do something  Triggered events set AI parameters  Send commands to various subsystems ▪ Changes state from Idle to Searching, or Searching to Combat  Disadvantages?

48  Adds fairness to the game  Even though the game knows where a player is, the AI needs to “see” or “hear” a player approaching  Realism  A sleeping enemy has to be startled to enter combat mode  Sneaking element is possible and quantized

49  Visual  Use ray casting to look for players  Distance, angle, and visibility factor into vision  Auditory  AI needs to receive sound notifications  Everyone in earshot should hear the sound  Priority of sounds (e.g. bird chirping and gunshot)  Audio Occlusion ▪ Interference of sounds to create noise  Tactile(touch)  Alert when run into or wounded

50  AI is initially designed to be very smart (usually)  Based on designers, the AI is given flaws to dumb it down  Also changed by difficulty settings ▪ Affects parameters for targeting, etc  Player Modeling ▪ On the fly difficulty adjustment

51  Aiming very similar  Movement may change  How to move so the AI does not block a teammate’s vision?  Behavior  How to choose objectives?


Download ppt "Zubair Chaudary, Kenny Rentschler, Constantin Savtchenko."

Similar presentations


Ads by Google