3ds Max 2012 Bible - Kelly L. Murdock [449]
3. Select Create⇒Particles⇒Particle Flow Source, and drag in the Top viewport to create the emitter icon. Scale and rotate the emitter icon so it is positioned inside the SOmniFlect object on the uphill side pointing downhill. The emitter can be fairly small so it fits inside the deflector.
4. With the Particle Flow Source still selected, click the Particle View button in the Modify panel of the Command Panel to open the Particle View window (or press 6). In the Event 01 box, select the Shape01 action, and in the rollout that appears to the right, set the Shape to Sphere and the Size to 5.0. Select the Speed01 action, and set the Speed value to 100. Click the colored dot to the right of the Display01 action, and select white as the new color.
5. Select the Collision Spawn action from the Depot pane, and drop it in Event01 beneath the Display01 action. Then select the Collision Spawn action, click the By List button in the Parameters pane, and select the SOmniFlect object. Then disable the Test True for Parent and Spawn Particles option, enable the Spawn On Each Collision option, and set the Offspring value to 10.
Figure 41.19 shows an avalanche of snowballs as it rages down a snowy hillside.
FIGURE 41.19
Using the Collision Spawn and a well-placed deflector, you can create an avalanche effect.
Using Particle Flow helpers
In addition to the Standard Flow event, several other actions create icons in the viewports that are controlled using the action parameters. One of these helpers appears when the Find Target action is added to an event node. This helper is a simple sphere, but all particles in the scene are attracted to it. It also can be animated.
The Speed By Icon action creates an icon that forces particles to follow its trajectory path.
Wiring events
Each new event node that is created has an input that extends from the upper-left corner of the node, and each Test event that is added has an output that extends to the left of its icon, as shown in Figure 41.20. Test action outputs can be wired to event inputs by dragging from one to the other. The cursor changes when it is over each.
FIGURE 41.20
Event outputs can be wired to event inputs.
Once wired, all particles that are tested to be true are transferred to the new event node and are subject to the actions in the wired event node.
Tutorial: Moths chasing a light
Another cool feature that the Particle Flow interface makes available is the ability to have particles chase a target object. In this example, you use the Target event to make some annoying bugs follow a lantern's light.
To use Particle Flow to make several bugs chase a light, follow these steps:
1. Open the Moths chasing light.max file from the Chap 41 directory on the CD.
This file includes a simple lantern created from primitives that is suspended from a chain and animated rocking back and forth. The file also includes a simple moth.
2. Select Create⇒Particles⇒Particle Flow Source, and drag in the Front viewport to create the emitter icon. Click the Particle View button to open the Particle View interface.
3. In the Event01 node, select the Birth01 action and set the Emit Stop to 100 with an Amount of 50.
4. Drag the Position Object action from the Depot pane, and drop it on top of the Position Icon action to replace it. Select the new Position Object action, click the By List button under the Emitter Objects list in the Parameters pane, and select the Sphere01 object.
This sphere surrounds the lantern and is the source of the moths. It has a material with an Opacity setting of 0 applied so that it is not visible in the scene.
5. Select the Rotation action in the Event01 node, and change the Orientation Matrix option to Speed Space Follow.
This rotates the moths as they follow the swinging lantern.
6. Drag the Shape Instance action from the Depot pane, and drop it on top of the Shape action to replace it. Select the new Shape Instance action, click the Particle Geometry Object button in the Parameters pane, and select the moth object in the