CoSECiVi'14 - Separating the autonomous behaviors and coordination of NPCs

Preview:

Citation preview

SEPARATING THE AUTONOMOUS BEHAVIORS

AND COORDINATION REGIMES OF

NON-PLAYER CHARACTERS

Gonzalo Milla-Millán and Juan Fdez-Olivares

gmillamillan@decsai.ugr.es

Department of Computer Science and Artificial Intelligence, CITIC-UGR, University

of Granada, Spain

A Motivating Example

A motivating example (extracted from [1]):

Jerry and George want to leave a room, and so they

independently walk towards the door, which can only fit

one person through at a time. Jerry graciously permits

George to leave first.

Overview

Goals:

Reduce the authoring effort in Interactive Storytelling (IS) systems (bottleneck in the development process)

Provide story variability (improves user’s experience)

Means:

Separate the autonomous behaviors of NPCs from their coordinations regimes

Authoring framework to encapsulate the knowledge and allow for its reuse

Narrative engine to use the encapsulated knowledge in order to automatically generate varied stories

Implementation using Hierarchical Task Network (HTN) planning

Authoring Framework

Physical Aspects of the virtual world

Context Model (a room with a door, positions of the NPCs, etc.)

Autonomous NPCs present in the world (Jerry and George)

Basic capabilities performable by NPCs that can alter the world (walk-to-door, cross-door)

Goal-oriented and context-dependent autonomous behaviors ( Leave-room : (walk-door cross-door) || (cross-door) )

Coordination regimes

Interdependencies (require-door-available / not-require-door-available)

Operational Relationships ( (Jerry < George) || (George < Jerry) )

Authoring Framework

The physical aspects of the virtual world are common

Behavior profiles and coordination regimes are encoded separatedly, relying on the common physical aspects of the virtual world.

Behavior profiles are collections of goal-oriented autonomous behaviors, which can be organized in libraries and assigned to NPCs.

Coordination Regimes are encoded separatedly from the autonomous behaviors and can also be grouped in libraries.

Decentralized Narrative Engine

n Actor agents + 1 Performance Director (Actor != NPC)

1. The Performance Director (PD) sends to each actor her narrative goal (e.g., leave room)

2. Each Actor (A) sends back to the PD her intended autonomous behavior (e.g., walk-door cross-door)

3. The PD applies the Coordination Regime (e.g., require-door-available + (Jerry < George)) to the set of intended autonomous behaviors proposed by each actor

4. The output is a coordinated story

Authoring using HTN planning

Authoring using HTN planning

Authoring using HTN planning

Door

availability

is NOT

managed

Authoring using HTN planning

Authoring using HTN planning

Door

availability

IS managed

Authoring using HTN planning

;; The virtual world is represented using ground predicates according

;; to the context model

(init:

(NPC-in-room jerry room1) (NPC-in-room george room1)…)

;; The narrative goals are represented using ground goal tasks

(:goal

(task-goal (Leave-room jerry)))

Narrative Generation using HTN

planning

Examples of Coordinated Stories

1. ( ( [ (1 walk J D) (1 walk G D) ] ) (2 cross J D) (3 cross G D) )

2. ( ( [ (1 walk J D) (1 walk G D) ] ) (2 cross G D) (3 cross J D) )

3. ( ( [ (1 walk J D) (1 walk G D) ] ) ( [ (2 cross J D) (2 cross G D) ] ) )

World

Conclusion

Separation of autonomous behaviors from coordination regimes

Reduce authoring effort (by allowing reuse of knowledge)

Provide story variability

Authoring framework

Decentralized narrative engine

Use of HTN planning by both the actors and performance director agents ensures the compliance of the generated narrative with the constraints imposed by

The behavior profiles of the involved NPCs

The applicable coordination regime

Future Work

More complex behaviors for NPCs ([2])

Consider more types of interdependencies ([1])

Integration with a Game Engine (Unity3D)

Integration of the player (continual planning approach: execution + monitoring + repair/replan)

Dynamic management of the applicable coordination regime (operational relationships that evolve along time, interdependencies managed according to an evaluation function for the dramatic value of the narrative, etc…)

Different layers of knowledge for interaction (e.g., social relationships)

Bibliography

1. Smith, B. L.; Tamma, V. & Wooldridge, M. An ontology for

coordination. Applied Artificial Intelligence, Taylor &

Francis, 2011, 25, 235-265

2. Paul, R.; Charles, D.; McNeill, M. & McSherry, D. MIST: an

interactive storytelling system with variable character

behavior Interactive Storytelling, Springer, 2010, 4-15