The Project
Normally, particle systems are used in a subset of animation techniques called effects animation. With the exception of effects sequences, they are usually created later in the production pipeline when primary object animation has been completed. In the case of the ongoing project within this book they are being added when the camera has been tracked, the scene stand-in geometry has been matched, and the character and objects have been modeled and animated.
Effects animators are specialists similar to the way character animators are, focusing most of their attention on a complex aspect of animation as a whole. Effects animators tend to differ from character animators in their emphasis and approach to the technique of animation. Character animation focuses heavily on communication through motion and is hands-on, and effects animation tends to be more technical in nature. One isn't necessarily more difficult than the other, but their disciplines are different. There is definitely more art in character animation and more science in the production of effects animation. Thus many character animators are less package-specific, and effects animators are often married to their packages because they focus so strongly on their implementation of procedural tools.
The goals for effects animation in the project in this chapter are to create an exploding confetti effect when the box top blows off and the Jester character pops out. These will be instanced geometry particles that linger in the air and slowly fall to the ground, spinning along the way. Another effect will be a trailing pixie dust effect coming off the feet of the character as it leaps out of the box. This also will use space warps to help control the motion of the particles. All the effects will be tied together using Parameter Wiring and Custom Attributes to more easily adjust the effects in the scene.
Exercise 21.1 Setting Units
One of the first things to do with your scene when setting it up for work with particle effects is to adjust the units method. Units are the method used to represent values in parameters. This is important when modeling to scale, because you can set the values to real-world units such as decimal feet or meters. However, such units have no relevance to particle values, such as velocity and birth rate. You need to set the units of your scene to generic, which uses standard integer and floating-point values with no real correlation to real-world units.
-
Select File/Customize/Units Setup. At the bottom of the resulting dialog box, set the radio button to Generic Units, as seen in Figure 21.1.
Figure 21.1 Select Generic Units in
the dialog box.
-
In the Create panel, choose Particle Systems/PArray.
-
Click and drag anywhere in the Top viewport to create a PArray icon, as in Figure 21.2.
-
With the PArray selected, go to the Modify panel.
-
In the Basic Parameters rollout, set the Object Based Emitter by clicking the Pick Object button and choosing Bip01 R Foot from the list.
-
Set the Viewport Display section to Dots.
-
Set the percentage of particles to 100% so you can see the entire quantity for now.
-
In the Particle Generation rollout, set Speed to 0.1.
-
Set Variation to 25%.
-
Set Emit Start to 60.
-
Set Emit Stop to 96.
-
Set Display Until to 204.
-
Set Life to 90.
-
Set Variation to 5.
-
In the Particle Type rollout, set the standard Particles to Constant.
-
In the Object Motion Inheritance rollout, set Multiplier to 0.2.
-
Scrub the animation by clicking and dragging the time slider.
Next you use PArray to create a trail of particles from the feet of the character.
Figure 21.2 Add a PArray icon to the scene in the Top viewport.
There are a few PArray parameters you need to set up.
This sets the emitter to the biped's right foot.
This makes it easier to view the particles, because they are going to be represented by tiny pixie dust points.
The scale of this scene is pretty small, so the default value of 10 would be much too fast.
This varies the speed of particle emission by 25%.
This is the frame in which particles will first be emitted, when the character jumps out of the box.
This is the frame in which particles will stop emitting and is the point when the character first reaches the surface of the table.
This is the frame in which the particles disappear. This might seem pointless, because the particle emission ends at frame 96, but it's good practice to adjust this value from its default of 100 to at least one frame past the end of your animation. It's a common mistake to ignore this parameter, which results in all the particles disappearing at frame 100.
This gives the particles a lifetime of 90 frames.
Unlike the other variation parameters, this one is in frames, not percentages. This causes the particle life value to vary plus or minus 5 frames. This reduces the uniformity of the effect by adding some randomness.
This makes the particle geometry constantly scaled circular points that always face the camera.
This causes the particles to receive 20% of the motion of the emitterin this case the biped foot. This is important because in the real world when an object is ejected from a moving object, it begins its motion at the same speed as its parent.
You'll see a trail of particles emitting from the right foot of the biped object. Because of the motion inheritance, the particles aren't stationary but actually move with the foot as they're emitted. See Figure 21.3.
There is one problem, however. The particles are emitted too fast. There also needs to be a drag and gravity effect applied to them. This is done through space warps, which you tackle in the next exercise.
Figure 21.3 PArray particles trail from the right foot of the biped.Exercise 21.2 Adding a Drag Effect
In this exercise, you add a Drag space warp to cause a dampening effect on the particles' velocity. Space warps are nonrendering objects that act as fields in the scene and are accessed through the Create panel like any other object.
-
Go to the Create panel and click the Space Warps button.
-
From the Forces drop-down list, choose Drag.
-
Click and drag a Drag icon into the Top viewport.
-
With the Drag space warp selected, go to the Modify panel.
-
Set Time Off to 205.
-
Set the Linear Dampening X-axis and Y-axis to 2.0.
-
Set the Linear Dampening Z-axis to 10.0.
Play the animation by either scrubbing the time slider or clicking the Play button.
All the Drag parameters appear in the Modify panel. There are many for such a simple effect. The new Drag space warp offers much flexibility, including nonlinear and localized dampening, so the effect doesn't have to be uniform (on all axes) or affect the particles globally across the entire scene.
You need to set a few parameters for this Drag space warp.
Normally this is set to the default value of frame 100, which causes the Drag effect to end at frame 100, in the middle of the animation. It's generally good practice to change Time Off to match the end frame of your animation, which causes the Drag effect to continue until the end of the animation and not turn off inappropriately.
This sets an equal amount of drag force along the X-axis and Y-axis.
This increases the Drag effect along the Z-axis, which prevents the particles from moving too much vertically as they are emitted. They also will be affected laterally in the X-axis and Y-axis, however, but much less. This gives them some freedom to wander. See Figure 21.4.
Figure 21.4 Drag space warp parameters increase flexibility.
The particle system is now bound to the space warp. If you go to the Modify panel with the Parray01 selected, you'll notice an entry in Stack View that shows a Drag Binding.
The particles are emitted from one of the feet of the biped, but slow down a bit and linger. There's still one more step to control the motionadding turbulencewhich you'll do in the next exercise. By using the Turbulence controls of a Wind space warp you can perturb the motion of the particles slightly as they linger in the air. This breaks up the uniformity of the effect, making it more realistic and natural.
Exercise 21.3 Adding a Wind Space Warp
You create a Wind space warp the same way you create a Drag warp. In fact, the Wind space warp is similar to the Gravity space warp because it has a directional icon showing the vector of the effect.
-
Go to the Create panel, choose Space Warps/Forces, and click Wind.
-
Click and drag in the Top viewport to create a Wind space warp.
-
Bind the particle system to the Wind space warp by selecting the Parray01 particle system.
-
Activate the Bind to Space Warp button with a single button-click.
-
Click and drag from the Parray01 particle system to the Wind space warp icon and release the mouse button.
-
Verify that the space warp is bound by checking Stack View for the Wind binding. Use Figure 21.5 as a reference.
-
To turn off the Strength value, select the Wind space warp.
-
Go to the Modify panel and change the Strength value to 0.
-
Adjust the Turbulence value to 0.02.
-
Change the Frequency value to 0.15.
-
Set the Scale value to 0.2.
Figure 21.5 Wind space warp is added to the scene.
By default, Wind has a Strength value of 1.0. This is the amount of force in the direction of the Wind space warp icon's arrowin this case, upward. If you scrub the animation at this point, you'll notice that too much force is applied to the particles and they are heavily displaced upward. If you select the Wind space warp, go to the Modify panel and look at the first two Turbulence parameters. Turbulence and Frequency are zero, which means that there is no perturbing effect on the particles. To create turbulence without forcing the particles in any given direction, you have to turn off the Strength value.
Now if you take a look at the animation, the particles don't launch upward in the direction of the Wind icon. No force is being applied in the Wind's direction. However, you still need to make adjustments to the Turbulence parameters to achieve the proper effect.
With those numbers plugged in, you should see some extra movement in the particle motion. Play with these numbers to experiment with the motion, but don't wander too far from these values because the effect can quickly become unrecognizable. At this point you leave the pixie dust effect for a bit and move on to a confetti effect.
NOTE
These might seem like arbitrary numbers, but I consider them default parameters for most scenes. These numbers are a good starting point for integrating turbulence into a scene. Many people often make the mistake of using higher numbers, such as 2.5 or 10. Unfortunately, this doesn't work because so much depends on the scale of your scene.
Keep the following in mind:
Turbulence controls the speed at which particles waver and curl or are perturbed from their normal paths. Lower amounts cause gentle motion, and higher values naturally cause excited motion.
Frequency is directly related to Turbulence. Frequency controls the amount of randomness in the motion over time. Higher numbers cause more variation.
Scale is probably the most important value to set correctly, because without matching this value to the scale of your scene, the effect is unnoticeable. The number values for this parameter might be misleading. Very low numbers0.01, for examplecause large turbulent motion, and higher numbers cause tight motion. Turbulence is really just a fractal noise field applied to the particles. The Scale value controls the scale of the noise and therefore the visibility of the motion.
Exercise 21.4 Creating a Confetti Effect
In this exercise, you use a SuperSpray particle system emitting particles as instanced geometry to create a confetti effect. By using instanced geometry you'll be able to use a custom object as particle geometry. You'll also add some space warps to control the motion of the particles, and finally add some Custom Attributes and Wire Parameters to better control and automate both effects.
To start the confetti effect, you need to choose a particle system. SuperSpray is ideal in this case because it has similar parameters to the PArray particle system you used previously, but also has the capability of emitting particles from a single point outward in a controlled direction.
-
Go to the Create panel, choose Particle Systems, and click SuperSpray.
-
Click and drag in the Top viewport over the box01 object to create a SuperSpray icon, as seen in Figure 21.6.
-
In the Basic Parameters rollout, set Percentage of Particles to 100%.
-
In the Particle Generation rollout, set Use Total to 100 by switching the radio button to activate this parameter and adjusting the total number of particles to be emitted to 100 particles.
-
In the Particle Motion subsection, set Speed and Variation to 2 units and 25%, respectively.
-
In the Particle Timing subsection, set Emit Start to 60.
-
Set Emit Stop to 65.
-
Set Display Until to 204.
-
Set Life and Variation to 100 and 10, respectively.
-
Go to frame 65 and select the SuperSpray particle system.
-
Go to the Modify panel and change the Off Axis Spread value to 80 and the Off Plane Spread value to 180, as seen in Figure 21.7.
-
Go to the Create panel, choose Standard Primitives, and click the Plane button.
-
In the Top viewport, click and drag to form a plane primitive in the scene.
-
With the plane primitive selected, go to the Modify panel.
-
Change the Length value to 2.0, change the Width value to 0.5, adjust the Length Segs value to 13, and rename the plane primitive ConfettiStrip.
-
With the new ConfettiStrip object selected, go to the Modify panel.
-
Click Modifier List to open the drop-down list and choose Bend.
-
Set Angle to 60.
-
Set Bend Axis to X.
-
With the ConfettiStrip object selected in the Modify panel, click Modifier List to open the drop-down list and select Twist from the list.
-
Set Angle to 50.
-
Set Twist Axis to Y.
-
Select the SuperSpray particle system. Go to the Modify panel to access its parameters.
-
In the Particle Type rollout, change the radio button to Instanced Geometry.
-
Click the Pick Object button below in the Instancing Parameters and choose the ConfettiStrip object.
-
Go to the top rollout of the SuperSpray particle system and set the Viewport Display radio button to Mesh.
-
To hide the original ConfettiStrip object, select it, go to the Display panel, and click Hide Selected, as shown in Figure 21.9.
NOTE
The SuperSpray icon is slightly different from the PArray particle system icon. SuperSpray emits particles in a direction determined by the icon, not by a geometric object in the scene. In this case, the location of the icon and the direction you point it in determine how particles are emitted. By creating the SuperSpray particle system in the Top viewport, you automatically create it pointing upward along the Z-axis. Notice there is an arrow built into the icon.
Figure 21.6 The SuperSpray particle system is located inside the gift box with the biped.
Before you go any further, there are a few parameters you need to adjust.
This causes every particle emitted internally to be displayed in the viewports.
These two values are related and therefore mentioned in the same space.
This defines the starting frame for particle emission.
This causes all particle emission to stop at frame 65. With these two start and stop values set accordingly, the total number of frames in which particles will be emitted is 5.
This should normally be a number beyond the final frame of your animation.
This defines the number of frames that particles will be "alive," give or take 10 frames. The Variation parameter is different from most others because it is defined in frames, not percentage. In this case when a particle is born its Life value is determined to be between 90 and 110.
If you take a look at the animation of the SuperSpray particles you see that they emit upward in a tight stream. This is a matter of adjusting some axis and spreading controls. You'll be able to better visualize these changes if you move the time slider to a frame where the particles are visible.
Figure 21.7 Adjust the Off Axis Spread and Off Plane Spread controls to create a more conical emission.
As you adjust these two values, notice what they do to the angle of the particle emission. When you adjust the first parameter, the emission is in the form of a flat fan. However, as soon as you adjust the second parameter, the shape of the spreading fan becomes conical. These are two powerful controls for shaping particle emission.
The next step is to assign instanced geometry to the SuperSpray particles. Recall that instanced geometry is a method of referencing an object in the scene to use as particle geometry. In this case, you need to make a confetti object to use as the instanced geometry in the particle system.
To create the confetti strip, you use a Plane primitive and apply a couple of modifiers to shape it. The modifiers will come in handy, because they enable you to edit the object's shape without destroying it.
The initial size of the plane primitive is irrelevant, because you'll adjust its parameters in the Modify panel.
If you zoom in on the object, you'll see that it's a long, thin, single-sided object made up of evenly spaced polygons. The reason for adding more Length Segs past the default value of 4 is to make the polygons even. This becomes necessary when you're going to bend and twist the object, which you'll do next.
This adds a Bend modifier to the object, which enables you to warp the object on a specific axis a set amount of degrees. The motivation here is to skew the ConfettiStrip into a twisted piece of paper.
In the Bend parameters rollout, you make a few changes.
This bends the modifier gizmo 60 degrees.
This restricts the bending effect to the X-axis of the gizmo.
If you zoom in on the ConfettiStrip object in one of the side viewports, you can see the bending effect the modifier has on the object.
Next you add a Twist modifier, which is similar to a Bend modifier but has a more asymmetrical effect.
This adds a second modifier onto the object's stack, visible in Stack View. As with the Bend modifier, there are two parameters you need to adjust.
This increases the twist effect by 20 degrees.
This isolates the effect to the Y-axis of the modifier's gizmo, as seen in Figure 21.8.
With these steps complete, you should have a long strip of polygons twisted and bent into a confetti shape. The next step is to tell the SuperSpray particle system to use this newly created shape as instanced geometry.
Figure 21.8 Apply Bend and Twist modifiers to ConfettiStrip.
In your viewport, this doesn't make any immediate changes because the particles are still being displayed in their default manner as constant-sized Ticks. You can set the display option to show the actual geometry of the particles, though.
Now you should see the ConfettiStrip object being instanced to each particle of the SuperSpray particle system. If your viewport display feedback is too slow, you can opt to set Viewport Display to Bbox. This reduces the detail of the instanced geometry displayed by showing only its bounding box. One problem does exist, though. The original ConfettiStrip object is still present in the scene and needs to be hidden.
This doesn't delete the object, but hides it from view because you are not going to actually use it for anything other than reference for the SuperSpray particles.
Figure 21.9 SuperSpray uses the ConfettiStrip object as instanced geometry.
Using instanced geometry is a useful way to extend the geometric representations of particles in 3ds max. You can use polygons, patches, and even NURBS as instanced geometry. Unfortunately, there are a few drawbacks. In particular you can instance only one particular object and its hierarchy, not a group of objects. For example, if you create geometry for coinssuch as dimes, nickels, and quartersyou have to create a separate particle system to instance each type of object.
Exercise 21.5 Adding Drag, Wind, and Gravity
You now have the basic setup for the confetti effect. One of the problems at the moment is the unrealistic motion of the particles. They should explode out, slow down, and fall to the floor like flower petals. As you did previously with the PArray particle system, you can use space warps to control the motion of the SuperSpray particles. Drag and Wind space warps are present in the scene, but the only one you're going to reuse is the Wind space warp for its turbulence effect. Space warps can be used with multiple objects, and any changes in their parameters will affect those objects bound to it.
First you need to add a second Drag space warp with stronger, more uniform force.
-
Select the Drag01 space warp in your scene.
-
Switch to the Move tool by right-clicking the space warp and choosing Move from the quad menu.
-
Hold down the Shift key, drag the Drag space warp over so that it is separated from the original, and release the mouse.
-
In the resulting Clone Options dialog box, choose OK. Figure 21.10 shows the result.
-
With the new Drag02 space warp selected, go to the Modify panel.
-
Change all three Linear Dampening X-, Y-, and Z-axis values to 5%.
-
Select the SuperSpray particle system and bind it to the new Drag02 space warp using the Bind to Space Warp button.
-
Select the SuperSpray particle system and go to the Modify panel.
-
In the Rotation and Collision rollout, set the Spin Time to 10 frames.
-
Set the Phase to 30.0 degrees.
-
Set both Spin Time Variation and Phase Variation values to 25.0. Figure 21.11 shows the result.
-
Activate the Bind to Space Warp button and bind the SuperSpray particle system to the Wind01 space warp already in the scene.
-
In the Create panel, choose Space Warps/Forces and click Gravity.
-
In the Top viewport, click and drag a Gravity space warp icon into the scene.
Select the SuperSpray particle system and bind it to the new Gravity space warp. Figure 21.12 shows the result.
Figure 21.10 The Clone Options dialog box appears when you drag the Drag space warp while holding down the Shift key.
You have just created a clone of your original Drag space warp. They have the same values in all parameters, with the exception of their names. This new Drag space warp needs to be stronger to slow down the exploding SuperSpray particles.
If you take a look at the animation now, at frame 60 the SuperSpray particles explode outward in a hemispherical pattern and quickly slow down so that they create a sort of confetti effect.
Two problems are obvious. First, the particles should look like little strips of paper, but they don't spin. Second, they don't fall downward toward the floor, essentially defying gravity. Both of these problems can easily be addressed.
First, rotation is merely a matter of adjusting a couple of parameters in the particles. Second, Gravity, like Wind and Drag, is a space warp that you add to the scene.
Each of these parameters has a Variation parameter. This adds randomness to the values and breaks up the uniformity of the effectsomething you should always strive for. It's also useful to use the Wind space warp's Turbulence values that are already in the scene to perturb the motion of the confetti particles.
Figure 21.11 Set the Rotation and Collision parameters.
The only other force missing from this effect is Gravity, just another simple space warp to add to the system. Gravity works similarly to Wind because it is a planar directional effect by default. It can also be a spherical effect, as can Wind, but in this case the default setting works best to mimic the gravity of the sample scene.
Figure 21.12 Add a Gravity space warp to the scene.
Now the SuperSpray particles explode outward, but fall downward too fast. You can fix this by reducing the strength of the Gravity effect. Instead of doing this immediately by modifying the value, do some parameter consolidation with Custom Attributes.
Exercise 21.6 Adding Custom Parameters Using Custom Attributes
Custom Attributes are a new feature in 3ds max 4 that enable you to add custom parameters to objects. Using Parameter Wiring, you can connect Custom Attributes to parameters in your scene, using them to drive animation or, in this case, to consolidate several parameters from different objects and store them in one easily accessible rollout. It might sound complicated, but it's actually pretty simple. Just follow the steps in this exercise.
You create a dummy object that will not render or participate in any way in the scene, other than to store several parameters that you can use to manipulate the scene.
-
In the Create panel, choose Helpers/Standard and click the Dummy button.
-
In the Top viewport, away from all the clutter in the scene, click and drag to create a Dummy object.
-
With the Dummy object selected, go to the Modify panel.
-
Select Animation/Add Custom Attribute.
-
Change the Name field to Gravity.
-
Open the Float UI rollout and set the Width value to 100.0.
-
Set Range From to 1 and Range To to 1.0.
-
In the Finish rollout, click the Add button. Figure 21.13 shows the result.
-
Zoom out the Top viewport so you can clearly see both the Dummy object and the Gravity space warp.
-
Right-click on the Dummy object and select Wire Parameters from the Quad menu.
-
In the resulting pop-up menu, choose (in this order) Object(Dummy), Custom_Attributes, and Gravity.
-
Now click on the Gravity icon. Notice a line drawn from the dummy.
-
In the pop-up menu choose (in this order) Object(Gravity), and Strength. Figure 21.14 shows the result.
-
In the Parameter Wiring dialog box, click the Two-Way connection button. It's located at the top and looks like two opposing arrows.
-
Click the Connect button to create the connection. See Figure 21.15 for the result.
-
Select the Dummy object and change the Gravity Custom Attribute value to 0.02.
The Dummy object has no parameters. You can use Custom Attributes to add parameters here that you define. Custom Attributes is accessed in the Animation menu at the top of the screen.
This causes a large floater to appear with lots of controls. This is sort of like a custom parameter construction set. First you add a Gravity Strength control.
In the Add Parameter floater, the default parameter type is Float and the UI type is Spinner. Use these defaults.
A new parameter called Gravity appears in the dummy's Custom Attributes rollout. If you adjust this parameter, you'll see that it doesn't really do anything at the moment. The spinner field is 100 units wide, and the parameter's value range is from 1 to 1.0. You need to connect it to the Gravity space warp's Strength value by using Parameter Wiring.
Figure 21.13 Set the controls in the Add Parameter dialog box.
This connects these two floating-point values internally via MAXScript. The resulting dialog box is the Wire Parameters dialog box where multiple wiring can be edited.
The Gravity track is highlighted on the Dummy object on the left side of the box, and the right side shows the Strength track of the Gravity space warp. This identifies the two tracks that you are wiring together. Parameters can be wired in directions so that adjusting one track doesn't necessarily affect the other. Tracks can also be bidirectional, meaning that changing the values of either affects the opposite track. In the two lower boxes, there are text boxes with variables for the track values. This is actually an expression field and can be used to adjust how a track is interpreted. In the case of Custom Attributes that you're setting up, you want them to be bidirectional.
Figure 21.14 Wire the Custom Attribute to the Gravity's Strength value.
Figure 21.15 Complete the Parameter Wiring.
Now you've connected the Custom Attribute Gravity to the Strength value on the Gravity space warp. If you change the value of the Custom Attribute, the Gravity space warp's Strength value adjusts accordingly. Custom Attributes are fairly limitless, and using this method of storing them on a common object enables you to organize many parameters from several dissimilar objects into one consolidated interface.
The animation is nearly complete, but there still are a few tasks to do to complete the scene. Use the Custom Attribute you created to adjust the strength of the Gravity to a lesser amount more consistent with the scene.
This will work with the Drag space warp to cause the confetti particles to linger in the air and slowly float downward. The confetti particles scale up quickly and then scale down as they die. This is a function of the Grow For and Fade For values in SuperSpray. The default parameters of 10 cause the particles to scale up from zero to their full size in 10 frames and fade out to nothing 10 frames before each dies.
Parameter Wiring and Custom Attributes are a huge windfall for 3ds max users. They extend the procedural tools to a new level by enabling you to easily set up and control complex interactions between parameters of dissimilar objects. With Custom Attributes, the user is free to add specialized parameters to objects or, as in this example, consolidate parameters in the scene to one object.
Exercise 21.7 Adding Materials and Effects
The last big step in this process is to assign special materials and effects to the particles. First, you use a Multi Sub-Object material to randomly assign different colors to different strips of confetti. Then you use the Render Effect Lens Effects to add a glow effect to the pixie dust particles. Finally, you adjust the properties of the particles to better integrate them into the scene.
-
Open the Material Editor and choose an empty slot, or make one by selecting an existing slot and clicking the Delete button, which looks like an X below the material slots).
-
Create a Standard Material by clicking the Material Type button and choosing Standard from the list.
-
Change the Diffuse color swatch to a bright color, such as red.
-
Adjust the self-illumination value to 25.
-
Click the 2-Sided check box.
-
Rename the material Confetti and drag it onto the SuperSpray particle system to assign it.
-
To change the Confetti material to a Multi Sub-Object material, select the Confetti material in the Material Editor.
-
Click the Material button (which should read Standard at the moment) and choose Multi Sub-Object from the list.
-
In the resulting Replace Material dialog box choose Keep Old Material as Sub-Material.
-
Click the material's Delete button five times to remove materials 6 through 10 on the list.
-
Click and drag the top material (the red Confetti material) slot to the next one below.
-
Set the radio button in the resulting Instance (Copy) Material dialog box to copy and press OK.
-
Repeat this until all five slots look the same.
-
Click on the color swatch to the right of each submaterial and change it to a different color (try to stick to bright confetti-style colors, such as pink, aqua, and yellow). Figure 21.16 shows the result.
-
Select the SuperSpray particle system.
-
Go to the Modify panel. At the bottom of the Particle Type rollout, switch the Get Material From radio button to Icon.
-
Play the animation.
-
Go back to the Material Editor and drag the Confetti material onto the PArray icon.
If you are deleting a slot containing a material that exists in your scene, you are asked whether you want to delete the material from the scene (bad) or just remove it from this particular slot (good).
NOTE
By adding a fraction of self-illumination, you fake translucency in the confetti strips, an effect common with thin paper. By clicking the 2-Sided check box, you define this material as an automatically two-sided one, regardless of the geometry it's assigned to. This is important because the ConfettiStrip object you created was initially created with a Plane primitive that has polygons facing in only one direction. This essentially makes it one-sided, and viewing from directly underneath the plane causes it to be invisible. By assigning a two-sided material to the object, you're automatically causing the object to be two-sided, overcoming the shortcoming of plane without adding geometry.
What if you want the confetti to be several different colors? With the tedious method, you create multiple copies of the confetti particle system. Controlling these separate systems could be a hassle. With the better method, you assign a Multi Sub-Object material, and the particles will cycle through the maps in the list on a frame-by-frame basis, assigning different materials to particles at the given frame in the cycle. This doesn't work when particles are emitted over the course of a single frame. Luckily, in this scene the particles emit over the course of five frames.
This converts the Standard material into a Multi Sub-Object material with the default 10 entries. In the case of the confetti effect, you need only 5 entries.
You've already defined one material with all its special parameters (the red one), so instead of going in and matching all the settings with the new materials, copy the red Confetti material slot into all the other slots. From there you can adjust the color for each without having to go into each material slot.
In this sequence, you've copied the red Confetti material parameters to all the other slots in the Multi Sub-Object material. Now all you need to do is adjust the colors of the rest.
Figure 21.16 Store several materials in a Multi Sub-Object material.
When you look in the viewport, you won't notice any change in the color of the confetti particles, because, by default, the SuperSpray particles are getting their material from the instanced geometry and not the icon. This is easily changed in the SuperSpray parameters.
The colors of the confetti particles vary according to the list of materials stored in the Multi Sub-Object material. Figure 21.17 shows the result.
Figure 21.17 The confetti particles use a Multi Sub-Object material.
The next step is to assign a Glow effect to the PArray particles that are serving as pixie dust. At the moment they are rendering as tiny constant, or circular, geometry that always faces the camera. They have a default material attached to them that must be changed to make them more colorful. Luckily, you can use the same Multi Sub-Object material you created for the confetti particles.
NOTE
There are a couple of ways to assign materials to objects, but this is one of the more direct. You can also use the Assign Material to Selection button in the Material Editor, but that requires a selection. The drag-and-drop method is quicker because it doesn't require any selections.
The viewport display of the PArray particles doesn't show multiple colors. Don't worrycurrently the PArray particles are being displayed only as dots and not geometry. To verify that the assignment of multiple materials is working, try rendering out a frame to the virtual frame buffer.
Exercise 21.8 Using Render Effects
Render Effects are a post-process filter tool that was added in 3ds max r3. There are several kinds of Render Effects, but you work with an optical effects toolkit called Lens Effects in this exercise.
Lens Effects has tools for creating glows, highlights, sparkles, secondary reflections, and other optical anomalies via post-process. In the past, these kinds of filters resided only in Video Post and required much more time to work with. Moving Lens Effects to a Render Effect filter brings speed and flexibility to the workflow.
Render Effects can be added and edited with a single test render. Normally you have to re-render your scene to see any changes you make with a filter, but in the case of Render Effects, the filter is passed through a valid scene enumeration that can be stored in memory and applied to filter changes on-the-fly. This enables you to do much of your filter editing in nearreal time.
In this exercise, you need a tiny subset of the Lens Effects toolkit: Glow.
-
From the top menu, choose Rendering/Effects.
-
Click the Add button and choose Lens Effects from the list.
-
Select the newly added Lens Effects entry.
-
In the window on the left, choose Glow from the list and click the > arrow.
-
Select the Glow text in the right window. Figure 21.18 shows the result.
-
In the Parameters tab of the Lens Effects Globals rollout, change the Size value to 5.0.
-
In the Parameters tab of the Glow Element rollout, adjust the size to 3.
-
Change Use Source Color to 100.
-
Click the Options tab.
-
In the Apply Element To field, click the Image Centers check box and clear the others.
-
In the Image Sources field, click Object ID and clear any others. Figure 21.19 shows the result.
-
Select the PArray particles and right-click directly over them.
-
Choose Properties from the Quad menu.
-
Set the Object Channel value to 1.
-
Clear the Cast Shadows check box. Figure 21.20 shows the result.
-
Select the PArray particle system.
-
Choose Edit/Clone from the top menu.
-
In the Clone Options dialog box, accept the default name by clicking OK.
-
With PArray02 selected, go to the Modify panel and change the Object-Based Emitter to Bip01 L Foot.
Scroll to the bottom of the Particle Generation rollout and click the New button next to Seed to create a new randomly generated Seed value.
A few new rollups are added. One contains two windows with elements on the left, and one is empty on the right. The empty one is where you assign Lens Effects tools to the filter. The rollout below stores Lens Effects global variables that can be used to apply common parameter changes across several elements.
Notice how a new set of rollouts is added below when you select the Glow element. These are the local controls for that tool. In the next steps, you adjust a series of parameters to create the pixie dust effect for your scene.
Figure 21.18 Select the Glow text in the Rendering Effects dialog box.
Figure 21.19 Adjust parameters for the Glow element.
NOTE
Here's a breakdown of what you just did. You adjusted the global scale of the Lens Effects filter. By default it's 100, which is too large for this scene. If you had multiple elements, you could use this global size value to adjust the scale of all elements equally at the same time. By setting the Use Source Color value to 100, you're telling the glow filter to glow the particles using each particle's material color 100%. This is a handy feature, though you can explicitly color Glow elements using different parameters in the filter. Finally, by setting Image Centers and Object ID 1, you're telling the filter to apply the Glow effect only to the center of nodes in the scene that carry an Object ID of 1. Currently, you have no objects with an Object ID of 1, so you need to set one.
Figure 21.20 Set controls and properties in the PArray Object Properties dialog box.
Now if you render the Camera view, it first renders the entire scene, and then a Render Effects pass is processed. This can sometimes be very fast, but in the case of working with these particles it might be a bit slow.
The Render dialog box shows you the progress of the render effect, as seen in Figure 21.21. This glow effect is driven by Object ID 1 in the scene, so if any other objects in your scene were tagged with that ID they glow as well. You clear the Cast Shadows check box to force the PArray particles to not cast shadows onto other objects in the scene. Normally you'd think that this is important for integration into a live action shot, but in the case of these glowing particles they're appearing as a light source and therefore shouldn't cast any reasonable shadow.
Figure 21.21 The Glow effect is applied to particles.
The last thing you need to do with the PArray particles is to clone them so that you have a second stream that flows from the other foot of the biped. Instead of creating a second PArray particle system from scratch, use the Clone tool, because all the parameters are finalized in the original PArray.
This creates an exact duplicate of the previous PArray particle system andmore importantlyits particles have the same path. Why? They are being emitted from the same object and use the same Seed value. You need to adjust these two parameters to complete the effect.
Now if you play the animation you should have two sets of particles being emitted from the feet of the biped object. This concludes this section of the project.