Tactical AI in Real Time - PowerPoint PPT Presentation

Tactical ai in real time l.jpg
Download
1 / 23

  • 178 Views
  • Uploaded on
  • Presentation posted in: Sports / Games

Tactical AI in Real Time. Supervisor : Aleks Jakulin Crew : Damir Arh, Matija Jekovec, Mitja Luštrek Gregor Leban, Martin Žnidaršič, Uroš Čibej. Translation: A. Jakulin. Task. real-time strategy objective: survive based on physical simulation

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.

Download Presentation

Tactical AI in Real Time

An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -

Presentation Transcript


Tactical ai in real time l.jpg

Tactical AI in Real Time

Supervisor: Aleks Jakulin

Crew:

Damir Arh, Matija Jekovec, Mitja Luštrek

Gregor Leban, Martin Žnidaršič, Uroš Čibej

Translation: A. Jakulin


Slide2 l.jpg

Task

  • real-time strategy

  • objective: survive

  • based on physical simulation

  • computer assists the player (intelligence amplification instead of artificial intelligence)

  • teams of AI units

  • the player does not control individual unit’s behavior

  • units perform team-allocated duties


Program structure 1 2 l.jpg

Program Structure1/2

  • Two separate applications:

    • server

    • client

  • Client:

    • graphics

    • user interface

    • server connection


Program structure 2 2 l.jpg

Server:

communication with clients

physics

pathfinding

Hierarchical AI

Strategic layer

Team

Unit (soldier)

Program Structure2/2


Physical m odel 1 3 l.jpg

PhysicalModel 1/3

  • Terrain:

    • 2D map

    • passable / impassable kvadratki

    • continuous space and time

    • map fully revealed to AI

    • enemies only seen if at least one of units has visual contact


Physical m odel 2 3 l.jpg

PhysicalModel 2/3

  • Unit properties:

    • movement:

      • poses: walking, sneaking, crawling

      • movement speed dependent on orientation and health

      • separate movement direction and orientation

    • 3 shooting modes

      • health-, speed- and orientation dependent

    • view angle depends on speed of movement(F-01)


Physical m odel 3 3 l.jpg

PhysicalModel 3/3

  • Collision detection:

    • unit collisions

    • bullet collisions

  • Raycasting:

    • map intersections

    • object intersections


Visibility graph l.jpg

Visibility Graph

  • `expand’ the walls for unit radius

  • visibility graph nodes are convex corners

  • mutually visible corners are connected

  • before pathfinding, insert start and goal points in the graph

  • search with A* (F-02), heuristics(F-03)


Boids l.jpg

“Boids”

  • Basic rules:

    • a unit tries to move towards the center of the team

    • a unit tries to keep a minimum distance from walls and objects

    • try to match team speed

  • These Rules are too local!


Teams l.jpg

Teams

  • Units in different teams are separate from one another(F-04)

  • Significance:

    • hierarchical pathfinding

    • minimize team exposure

    • maximize team cohesion

    • formations


Teams pathfinding l.jpg

Teams: Pathfinding

  • Player sets the goal point, team adjusts individual unit movement given the requirements(F-05)

  • Pathfinding requirements:

    • safety

    • accessibility

    • proximity to goal

    • team cohesion


Teams exposure l.jpg

Teams: Exposure

  • Seek proximity of walls and corners, where the ratio between the visible `covered’ terrain and `uncovered’ terrain is minimal.

  • Note: we ignore mobility


Teams cohesion l.jpg

Teams: Cohesion

  • It is more desirable for units of a team to remain close and cover the terrain together. (F-06)

  • Note: in reality it’s the ease of signaling and directed firepower that matter.


Finite state machine l.jpg

Finite State Machine

  • Controls the units of a team

  • simple – well-known concept

  • readable – states are clearly separated

  • extensible – simple to add new states and transitions

  • adjustable – we choose to do whatever we please in a given state

  • We have state-dependent weights, adjusting the boids model.


Mdm fsm f 07 l.jpg

Mitja Luštrek, Damir Arh, Matija Jekovec

MDM FSM(F-07)

move

init

advance

idle

attack

Seek cover

retreat

prone


Maintaining terrain visibility l.jpg

Maintaining Terrain Visibility

  • During movement, the team leader is looking left and right, if there is no wall. (F-08)

  • Other units are trying to cover 360 degrees around the team.

  • If there are enough units to cover everything, increase the coverage of `interesting’ areas.

  • Interestingness of the area depends on proximity to walls and dangerous areas, tagged by the player. (F-09)

Danger

area


Shooting formation l.jpg

Shooting Formation

  • When enemy is spotted, everyone moves to face the enemy, or everyone goes into retreat.

  • Units move to avoid shooting one another.

  • Units seek positions with better coverage of the enemies.


Seeking a safe position l.jpg

Seeking a Safe Position

  • If player gives no orders, team moves to a safe position.

  • Seek proximity of cover.

  • Seek good coverage. (F-10)


Gum fsm f 11 l.jpg

Gregor Leban, Uroš Čibej, Martin Žnidaršič

GUM FSM (F-11)

init

normal

cover

assault


Determining orientation l.jpg

Determining Orientation

  • Compute four viewing orientations for each unit.

  • Orientations depend on openness of terrain and tagged danger areas.

  • Pick the most important orientation that is not yet covered.


Assault l.jpg

Assault

  • When enemy is spotted, everyone faces it and assaults.

  • Every unit picks the closest enemy and fires.

  • Move if a friendly unit close near the firing direction.

  • The player may adjust the formation during combat.

  • High mobility during an attack.


Technical details l.jpg

Technical Details

  • Development environment: Visual C++

  • Libraries:

    • Simple DirectMedia Layer (SDL)

    • Video for Windows (VFW)

    • winsock

  • 450 KB of code

    • over 17000 lines in 110 files


Conclusions l.jpg

Conclusions

  • High computational load.

  • Many parameters.

  • Weight tuning is complex.

  • Machine learning hard to use.

  • Commercial games use simpler logic.


  • Login