329
19
AnEgocentricMotion
ManagementSystem
Michael Ramsey
Ramsey Research, LLC
Between the motion
And the act
Falls the shadow.
—T. S. Eliot
The egocentric motion management system (ECMMS) is both a model for agent
movement and an application of a behavioral theory. Any game that features
agents (e.g., animals, soldiers, or tanks) that move around in a 3D scene has a
need for an agent movement solution. A typical movement solution provides
mechanisms that allow for an agent to move through a scene, avoiding geometry,
all the while executing some sort of behavior.
This article discusses not only how focusing on the agent drives the immedi-
ate interactions with the environment but also, more importantly, that by gather-
ing some information about the environment during locomotion, we gain the
ability to generate spatial semantics for use by the agent’s behavior system. Por-
tions of the ECMMS were used in a cross-platform game entitled World of Zoo
(WOZ), shown in Figure 19.1. WOZ is an animal simulator that requires various
zoo animals to move through their environments in an incredibly compelling
manner while the players constantly alter the environment. So the proving ground
for this system was in an environment that could be changed around the agents at
any particular moment.
330
Con
v
importa
n
mind is
h
facilitat
e
dreadin
g
havioral
expect t
h
percept
u
states o
f
user of
n
b
ehavio
r
have a c
sire to
b
enough
t
they fit
t
One
is that
w
in an ap
p
is not o
p
purpose
f
animati
o
imbue o
u
compon
e
should
b
F
v
incing beha
v
n
t as what is
p
h
ow we con
t
e
s
p
erceived
g
and percept
u
coordinatio
n
h
e user to mi
m
u
al mindreadi
n
f
others, and
w
n
ot only the a
g
r
, also know
n
riterion for
u
b
elief, then i
t
t
o represent
t
t
ogether.
of the highe
r
w
e ideally wo
u
p
ropriate ma
n
p
en for inter
p
f
ul manner.
T
o
n, and artifi
c
u
r agents wi
t
e
nts that for
m
b
e about the p
F
i
g
ure 19.1. S
c
v
ior is not a
p
erceived by
rol the perce
p
intent. Bur
m
u
al mindrea
d
n
—this gets
u
m
ic the agen
t
n
g is slightl
y
w
e accompli
s
g
en
t
’s intend
e
n
as propositi
o
nderstanding
t
is likely t
h
t
he states of
r
-order goals
u
ld like to o
b
n
ner. What i
s
p
retation is t
h
o help facil
i
c
ial intelligen
t
h these char
a
m
the system
r
ocess throu
g
19.An
E
c
reenshots fro
m
one-way stre
the user. The
p
tion of an a
g
m
edez [2007]
d
ing. Simple
m
u
s nowhere,
a
t
’s behavior i
n
y
different in
t
s
h this by pr
o
e
d state but i
t
o
nal attitude
s
behavio
r
. If
h
at the beha
v
a behavio
r
when desig
n
serve an age
n
s
appropriate
h
e desire that
i
tate this, we
ce a
r
e inter
w
a
cteristics. A
s
and its resul
t
g
h which thes
E
gocentricM
m
World of Zo
o
e
e
t
—what th
e
e
immediate
q
g
ent in a sce
n
delineates
b
mindreading
a
s we are o
b
n
order to un
d
that the focu
s
o
viding mec
h
t
s eventual st
a
s
). This is cri
t
they witness
v
ior is justifi
humans ne
e
n
ing a motio
n
n
t in a scene
is open to in
t
we perceive
need to un
d
w
oven into a
s
s
such, this c
h
t
ant end prod
u
e results wer
e
otionManag
o
.
e
agent does
i
q
uestion that
c
n
e in such a
w
b
etween sim
p
is fundame
n
b
viously not
d
erstand it.
H
s
is on the p
e
h
anisms to in
f
a
te (i.e., goal
-
tical because
the attributi
o
able. It’s si
m
e
d to underst
a
n
manageme
n
responding t
o
t
erpretation,
b
the agent ac
t
d
erstand how
s
hadowy sub
s
h
apte
r
focus
e
u
ct, but the t
a
e
obtained.
ementSyste
m
i
s just as
c
omes to
w
ay that
p
le min-
n
tally be-
going to
H
owever,
e
rceptual
f
orm the
-
directed
humans
o
n of de-
m
ply not
a
nd how
n
t system
o
stimuli
b
ut what
t
ing in a
physics,
s
tance to
e
s on the
a
keaway
m
19.1FundamentalComponentsoftheECMMS 331
19.1FundamentalComponentsoftheECMMS
The ECMMS provides a mechanism for agents to plan and interact with the envi-
ronment in a manner that is focused not only on the typical utilitarian tasks of
locomotion but also allows for the intent of the agent’s behavior to be more be-
lievable by providing specific environmental cues to the behavioral system. What
we ideally would like to have is a system that allows for different types of agents
to interact with the environment based upon how they interpret the scene, and a
major component of understanding the environment comes from the acknowl-
edgment and the use of relative spatial orientations. To help accomplish this, the
ECMMS is composed of several elements that allow an agent to receive spatial
information about its environment: they are collision sensors and the query space.
Every model has, at its core, a fundamental, atomic component that is essentially
the enabler on which the higher-order systems are built. The ECMMS is no dif-
ferent—the collision sensor is the element that allows for information to be re-
ceived from the environment.
19.2CollisionSensors
As shown in Figure 19.2, the collision sensor is a simple primitive that acts as a
callback mechanism that is triggered when specific collisions are registered with
it. As we mention below, the individual pieces of collision geometry are assigned
to a collision layer. The significance of the collision layer is that it allows for an
agent to detect surfaces that may be of interest to it—behavioral interest. Gibson
[1986] defines an affordance as “what it offers an animal, what it provides,”
where “it” is an object. This important quote can be attributed to our system be-
cause it means that just because our collision sensor receives a callback about an
overlap with some object, it doesn’t mean we need to interact with it, just that it’s
available for possible interaction. What helps us determine whether we want to
Figure 19.2. A top view of a bird with one collision sensor. When an object overlaps
with the collision sensor, a callback is invoked to register the object with the agent.
Generates callbac
k
332 19.AnEgocentricMotionManagementSystem
interact with the object is the following: the current behavior, the available space
for an action, and the ability of the agent to interact with the object. We discuss
this later on, but note that this system is predicated on a very fundamental dic-
tum, and agents need to influence behavior in an egocentric manner. Behaviors
need to be understood from the perspective of the agent—what may be usable by
an elephant may have an entirely different use or purpose for a mouse.
19.3QuerySpace
The query space is a construct that is used to group collision sensors into sets that
are not only organizationally consistent for your game’s behavioral system but
are also used to generate the semantics for the situation. The collision sensors
allow for the generation of a syntax for the query space, and then the query space
allows for the attribution of semantics to a situation.
The collision sensors can be authored and grouped in a query space in almost
any manner. In an early version of WOZ, the collision sensors were procedurally
constructed around the animals, but we settled upon authoring the collision sen-
sor cubes inside 3DS Max. Figure 19.3 shows a typical query space configuration
around an agent (a bird) that moves on the ground and occasionally jumps. When
designing a query space for your entity, you should be aware of not only the de-
sired behavior of your agent but, more importantly, the behavioral constraints
that the agent potentially exhibits. These constraints are important because if col-
lision sensors are authored only near an agent, then that agent is unable to pick up
information that is spatially distal.
Figure 19.4 shows a general design for a query space that is usable for a vari-
ety of agents. Typically, a query space is composed of an immediate ring of colli-
sion sensors surrounded by an outer ring of collisions sensors. This allows for the
Figure 19.3. (a) A side view of a query space with three levels of collision sensors.
(b) The same query space viewed from directly above.
(a) (b)
Level 1
Level 2
Level 3
19.3QuerySpace 333
Figure 19.4. A query space template.
agent to not only receive callbacks due to spatially proximal bodies but also al-
lows for the agent to receive more distal callbacks that could influence its behav-
ior. As mentioned above, the query space is used to generate the semantics for
the agent relative to the geometry in the environment (which we discuss in more
detail in Section 19.7), but what the query space fundamentally allows for is the
ability to ask behavioral questions such as, “Is there anything on my right?” or
“Do I need to modify my gait to keep pace with the pack?” These are questions
that the agent should ask itself based upon its orientation with objects in the envi-
ronment.
QuerySpaceAllowsforanUnderstandingofSpace
Modeling of an environment doesn’t just stop with the modeling of the geometric
entities [Ramsey 2009a]. It must also be extended to the modeling of space with-
in that environment (or have it procedurally generated). What the query space
enables is for the behavior engine to ask at any moment certain fundamental
questions such as, “Do I have enough space to execute this particular action?”
It’s important to separate the term action (which in our case means animation)
from that of a behavior. When combined (as they routinely are in game develop-
ment), its eventual consequence is that of a muddied concept. So action means
animation, while behavior means something that occurs over time. That is a very
important distinction that ECMMS makes use of, since at any particular moment
in time, an agent may execute an action, but it may be executing that action as
part of a more encompassing behavior. What we mean by a more encompassing
Nearby collision sensors (inner ring)
Outer ring of collision sensors
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.133.133.233