These three Bullet Dynamics types share similarities in their settings and effect. They are global to a scene and affect all other dynamic objects in the scene although falloffs can be created using gradients to isolate the effects to certain regions of 3D space. Note, textures for Force settings using World Coordinates won’t work correctly.
For each of the three types - Forcefield, Vortex and Explosion - the effect is chosen between one of three options:
- Force - applies the type as a force. That means that lighter objects will accelerate faster. Similar to hitting something.
- Acceleration - is like gravity. All objects accelerate at the same rate regardless of mass.
- Velocity - is more like wind. Objects will have forces applied to them so that they reach a given velocity (even if that velocity is 0). Using Velocity opens up the Density property. Density is used to determine how quickly the objects match the velocity set. Set to 0 it will never match (like there is no air at all), while 1 means it will get to the target velocity pretty much immediately (like a stick in a fast-flowing stream of water).
The forces can be directed along the axis chosen and can be varied using Envelopes or Textures. In addition the Explosion Type has an extra Direction - Center. This marks the Explosion dynamic object as the centre of a radially expanding explosion. In the example shown below, the ball and cube are subjected to a forcefield to prevent them hitting the floor.
Note that the gradient is applied to the floor rather than the falling objects. Forces are global, so the two rigid body objects falling toward the static floor object are the items that will be affected by the Forcefield. The strength of the field that is applied to a given rigid body is determined by evaluating the texture at the position of that rigid body. In this case, it would evaluate the gradient by determining the distance of the rigid body position from the gradient input object. The ball and cube thus fall toward the floor but are rebuffed the closer they get.
You can animate the position, rotation and scale of a force-type Dynamic element over the course of a scene rather than using the axes to vary how your scene reacts to a Force.
Example: Swirling Leaves
Thanks go to Greenlaw from Little Green Dog for sharing this scene. All the settings were arrived at through experiment and you should feel free to substitute your own.
Bullet’s Forces are ideal for creating this kind of scene. It is easy to set up and reacts very naturally. For the example shown, we began with creating a solid floor and some columns to add interest and turbulence for the leaves. The leaves themselves are simple hexagons divided down their length for more of a shape:
The leaf is given a UV map to make it easier to texture and textured with a Color map the alpha of which is used for Transparency. The leaf is made double-sided to ensure that it remains visible and the Specular and Glossiness channels are textured to make the leaf more visually interesting. Lastly the leaf is duplicated using Point Clone Plus. Open the Multiply > Duplicate > More > Point Clone Plus panel and enter the desired parameters. For floating leaves, use full randomization for rotation; for ground cover, Randomize only the Heading the full 360 degrees and randomize the Pitch only slightly (maybe 10 degrees). Click OK.
In Layout, on the FX Tools tab, the floor and columns SquareBV object is made Static, the LeavesFloating object is added and made Parts and lastly three nulls are added to the scene and Vortex, Explosion, and Forcefield are applied.
Let’s start with the simple. Our SquareBV object has Static applied, and the other settings are as follows:
- Set the Shape to Convex Pieces and Collision Margin to 10 mm;
- Mass Distribution should be Solid and Mass Specification set to Density with a Density of 1000 kg/unit;
- Friction is set at 30 % and Bounciness reduced to 10 %.
Now we’ll deal with the LeavesFloating object:
- Type is set to Parts so that each leaf is treated separately , Shape is Cylinder and Collision Margin to 10 mm;
- Mass Distribution set to Surface and Mass Specification to Given Mass with a value of 0.001 kg;
- Friction is set to 30 %, Bounciness 5 %, Linear and Angular Damping to 50 %;
- Glue Strength is set to 0 % and none of the other settings in this section are engaged.
Lastly, we’ll change our three Force settings. The three forces are arranged in a column at the center of the scene with the following settings:
For the Forcefield layer, the size of the Fractal Noise texture is 2 m on all axes.
The Explosion layer is the simplest. Set it to a low negative number so that it drags the leaves into the center rather than forcing them out.
The Vortex layer has a gradient on the Strength setting. It is set up like this:
The values go from 0 to 0.1 and back to 0 over the 6 m range. With these settings you should have a fine swirl of leaves rushing around your courtyard. Add other objects or use a texture to create a more visually interesting Vortex.