Following Along a Path

 
 
 

When you make the actors in a crowd follow along a path, they are actually moving in sequence along a number of "goals" along a curve. However, you don't need to create the actual goal objects: the positions along the curve are the implied goals.

The particle emitter can be placed anywhere along the curve and the actors will go to the closest "goal" on the curve: they don't all try to start at the beginning of the curve.

In this image, two paths are created with actors following along each one, and some even starting out from the opposite direction.

To make actors follow a path:

  1. Create a curve to use as the path. You may want to avoid creating tight corners on the curve because the actors can get congested as they slow down to navigate them.

  2. In the simulation point cloud's Particle Simulation ICE tree, create a Get Data node for the curve.

  3. Get a Follow Curve compound and plug it into the Execute Goal port of the Simulate Collision Avoidance compound.

  4. Plug the curve's Out Name output into the Curve Name port of the Follow Curve compound.

  5. Set the parameters in the Follow Curve compound's property editor, including these two:
Note

You may need to lower the Far Interaction Limit in Initialize Collision Avoidance compound to 0 to prevent actors from turning and running away from the curve when there is another actor very close in front of them along the curve. You could also use social groups (see Creating Social Groups).