RealFlow's force-based daemons are not exclusive to fluids, but they also affect rigid and soft bodies. Very nice effects can be achieved with rigid bodies and the “DSpline” daemon: in this short tutorial we want to make 40 chocolate buttons (aka also known as “M&M” or “Smarties”) follow a given path. When the objects are attracted by the daemons's forces they will organize themselves and form a tail-like arrangement.
The result of the tutorial has been rendered with RealFlow's implementation of Maxwell Render.
...
All elements, except the Smarties can be added from RealFlow's “Edit” menu:
- Add > Daemons | Camera
The Smarties can be created in your 3D software and exported as an Alembic or SD file. In RealFlow, objects are imported with
- Ctrl/Cmd + I
- RealFlow nodes can be moved, scaled, and rotated with the the W, R, andE keys E keys.
- Imported objects from SD files have to be unlocked before they can be transformed with with Selected object > Node Params > Node > SD ↔ Curve
- Viewport perspective is changed with the the 1, 2 2, 3, and 4, and 5 keys. The last key enables the camera's view. keys.
- Shading modes are toggled with the the 7, 8, 9, and and 0 keys keys.
Preparing the Smarties Objects
...
Ctrl + I > load the SD or ABC file with the objects
Select the imported objects > right-click on one of it > Group
Group node > right-click > Rename > Smarties
Group node > Node Params > Node > SD ↔ Curve
Group node > Node Params > Node > Dynamics > Active rigid body
Group node > Node Params > Node > Rigid body > @ mass > 5.0
“@ mass” strongly depends on your objects' size and the scene's scale, and you probably have to perform a few tests later to find out a working value.
The “DSpline” Setup
By default, this daemon provides three, so-called control points (“CP”). The control points can be made editable and repositioned to describe the spline's shape. Of course, it is also possible to add new control points. The daemon's yellow circles are the boundaries of its force field; the field itself looks like a tube along the spline. To make the field visible, go to
...
Add the daemon and rotate it by 90 degrees to align its axis horizontally. This will be the objects' main direction of motion.
Click on “EDIT” to make the control points accessible. They are numbered and you can browse through them under “@ CP index”. Alternatively, click on a control point in the viewport, e.g. with the “Move” tool (press W).
Add two new control points with “Insert CP”.
Reposition the control points with the “Move” tool to describe a 3D path. The best way to do this is to use RealFlow's orthogonal views (side, front, top).
Control points 1-5 > @ CP radius > 4.0
Click on “EDIT” to lock the points
Axial strength > 151.0 attracts the objects to the spline. Negative values create a repulsion.
Radial strength > 8040.0 attracts the objects to the control points. Negative values create a repulsion.
It is likely that you have to use different “strength” values, because they depend on the objects' “@ mass” settings. The control points can be repositioned at any time, but please bear in mind that it is not possible to rotate them.
The Smarties Setup
The bodies' physical properties have been adjusted in the first step already, and now it is time to position them. Use the M key for this action. Make sure that they do not interpenetrate.
...
It is not necessary to rotate the objects, but please feel free to do so if you want.
[ Image: F = 0 from “Smarties Along Spline” ]
Test Simulations
As with any RealFlow project, tests are a very important part of the simulation process. They are required to adjust forces, physical properties, velocities, etc. to get the desired look and behaviour.
...
Drag the timeline slider to frame where the animation should start.
Right-click on Node Params > Node > Position > Add key to create keys for all three axes.
Repeat the last step for the “Look At” parameter.
Shift the timeline slider to the next frame and set new keys.
Repeat these steps for the rest of the simulation range,
Open Layout > Export Central
Look for “CAMERAS”, check “SceneCamera0” “SceneCamera01” and open its branch.
Check “Animation (.sd)” and/or “Alembic Animation (.abc)” to activate the camera's export resources.
Simulate
...