9

Assigning Behaviors 1161
and Teams dialog (page 2–1200) to turn behaviors
on and off (with the Active check box), and for all
behaviors except Avoid, Orientation, and Surface
Follow , you can set and animate Weight. The
Active status is animatable for all behaviors.
Using B ehavior s
To use a behavior, you apply it to a delegate or a
team of delegates using the Behavior Assignments
and Teams dialog (page 2–1200).Inthisdialog,
each assignment of a behavior to a delegate is given
a weight. You can modif y and/or animate these
weights to influence the simulation.
Behavior assignment weights can profoundly
effect a simulation. When applying two or more
behaviors to the same delegate, the weights define
the relationship between the behaviors, making
one more or less powerful than the other. One
way to visualize a behavior assignment weight is
to examine the behavior’s force vector during a
crowd simulation. The vector’s length indicates
the behavior’s weight upon the delegate.
Each behavior has its ow n parameters which
appear in the Behavior rollout, available in the
Crowd object’s Modify panel. These parameters
describe how the behavior works, and can
sometimes contribute to the b ehavior’s strength
as well. For instance, Seek, Repel, Wall Seek, and
Wall Repel, all have specific volumes of influence.
Outside these volumes they have no effect and
essentially have a weight of zero. This rollout
lets you specify whether or not you wish to see
behavior’s force vecto r dynamically displayed
during a Crowd simulation, and wha t color that
vector should be.
When working with the Crowd system, it is critical
to play with behavior assignment weights, as well
as each behaviors parameters. Typically, you run
the simulation repeatedly, changing the weights
and p arameters to get the desired result.
A few behaviors cannot be weighted. These are
Avoid, Surface Follow, and Orientation. Avoid
and Surface Follow take over after all of the other
behaviors have been applied to a delegate. They
can take str ingent measures to affect the delegate,
possibly overpowering other behaviors in order to
meet their constraints. Orientation simply sets the
delegate’s facing direction. It cannot be weighted
and does not apply a force.
Behavior Tips
A few helpful things to know about behaviors in
character studio:
You can create conditional behavioral systems
with Crowd s Cognitive Controller feature.
This uses the MAXScript scripting language to
determine when to effect a transition from one
behav ior to another; we’ve provided a number
of sample scripts for you to learn from and
adopt to your own simulations in Cognitive
Controller Editor (page 2–1206) and State
Transition Dialog (page 2–1208).
The Behavior rollout appears immediately after
the Crowd object > Setup rollout in the Modify
panel. However , it doesnt show up until youve
addedatleastonebehaviortothecrowdobject.
The Crowd panel displays only one Behavior
rolloutatatime. Toaccessadifferentone,
choose its name from the drop-down list at the
bottom of the Crowd object’s Setup rollout.
Aswithmostsceneentitiesin3dsMax,itsa
good idea to give behaviors custom names, such
as "Seek Do or way" or "Follow Hilly Surface."
You do this by clicking the behavior’s name in
the S etup rollout and entering a new one from
the keyboard.
The default behavior settings may not always
give the ideal results. The optimal settings
depend vary with the particulars of your
simulation setup; in m any cases, if not most,
you’ll need to experiment with the settings to