1 / 106

Agent Architecture Considerations for Real-Time Planning in Games

Agent Architecture Considerations for Real-Time Planning in Games. Jeff Orkin Monolith Productions. F.E.A.R. Agenda. Motivation Problems Solutions Was it worth it?. Agenda. Motivation – Why plan? Problems – Performance! Solutions – Agent architecture Was it worth it?.

cale
Download Presentation

Agent Architecture Considerations for Real-Time Planning in Games

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. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Agent Architecture Considerations for Real-Time Planning in Games Jeff Orkin Monolith Productions

  2. F.E.A.R.

  3. Agenda • Motivation • Problems • Solutions • Was it worth it?

  4. Agenda • Motivation – Why plan? • Problems – Performance! • Solutions – Agent architecture • Was it worth it?

  5. Why plan in real-time?

  6. Goal-Oriented Behavior

  7. Goal-Oriented Behavior Problems: • Managing dependencies • Sharing behaviors

  8. Problem: Dependencies

  9. Problem: Dependencies

  10. Problem: Dependencies

  11. Problem: Dependencies

  12. Problem: Dependencies

  13. No One Lives Forever 2 TRON 2.0 Problem: Sharing

  14. No One Lives Forever 2 TRON 2.0 Problem: Sharing

  15. No One Lives Forever 2 TRON 2.0 Problem: Sharing

  16. P.D.D.L. • Planning Domain Definition Language • Goals • Desired state • Actions • Preconditions • Effects

  17. P.D.D.L. Goal: (define (problem get-paid) (:domain briefcase-world) (:init (place home) (place office) (object p) (object d) (object b) (at B home) (at P home) (at D home) (in P)) (:goal (and (at B office) (at D office) (at P home))))

  18. P.D.D.L. Action: (:action put-in :parameters (?x - physob ?l - location) :precondition (not (= ?x B)) :effect (when (and (at ?x ?l) (at B ?l)) (in ?x)) ) • Other actions: take-out, move

  19. P.D.D.L. • Modular • Goals • Actions • Decoupled Modules Related by symbols • World State • Preconditions • Effects • Applied PDDL’s structure to C++ toolkit in game code.

  20. Monolith Productions Management

  21. How to Plan in Real-Time and Keep Your Job Jeff Orkin Monolith Productions

  22. The Plan Goal: KillEnemy Plan: Goto (couch) UseObject (couch) Goto (coverNode) AttackFromCover

  23. AI Performance Guideline: 1.0ms / frame

  24. AI Performance: Off the Chart!

  25. Preconditions: Visibility AI Performance: Off the Chart!

  26. Preconditions: Visibility Pathfinding AI Performance: Off the Chart!

  27. Preconditions: Visibility Pathfinding Tactical Position Validity AI Performance: Off the Chart!

  28. Solution Re-consider Agent Architecture • Distributed processing • Caching

  29. Solution Re-consider Agent Architecture • Distributed processing • Caching Inspiration: • MIT Media Lab’s C4 • Robotics

  30. Solution

  31. What is a soldier?

  32. What is a soldier?

  33. What is a soldier?

  34. Sensors: See What is a soldier?

  35. Sensors: See Hear What is a soldier?

  36. Sensors: See Hear Feel pain What is a soldier?

  37. Subsystems: Navigate / Move What is a soldier?

  38. Subsystems: Navigate / Move Attention Selection (Targeting) What is a soldier?

  39. Subsystems: Navigate / Move Attention Selection (Targeting) Weapons What is a soldier?

  40. Distributed Processing with Sensors • Pseudo-parallel • Amortize precondition processing across many frames • Allow incremental processing

  41. Distributed Processing with Sensors • More than Vision, Hearing, Touch • Tactical analysis • Internal desires

  42. Distributed Processing with Sensors • Update: • Every frame • Periodic Polling • Event-driven • Limit total number of expensive sensor updates per frame.

  43. Sensor Example: CoverNode Sensor • Update 3 times / second

  44. Sensor Example: Cover Node Sensor • Update 3 times / second

  45. Sensor Example: PassTarget Sensor • Incremental update

  46. Sensor Example: PassTarget Sensor • Incremental update

  47. Sensor Example: PassTarget Sensor • Incremental update

  48. Sensor Example: PassTarget Sensor • Incremental update

  49. Sensor Example: PassTarget Sensor • Incremental update

More Related