We know we can set an initial or angular speed for dynamics objects in RealFlow, but we can’t animate directly these parameters on time. So, the only way to animate these parameters is using scripting. If we animate the initial velocities for objects will allows us good effects like explosions, objects which are getting breaking in the air, for example. In order to do this effect:
1- We’ll need to load the objects as SD and not as Multibody. It is due to the Multibody won’t change its pivot point position so it will be always in the same point.
2- Once the SD is loaded, we’ll open the BatchScript (F10) and paste this script.
Click here to download the script.
3- This line,
scene.simulateStep(), will simulate the scene directly from the BatchScript allowing us to change the initial velocities for the objects. So, we’ll nee to run the script from the Script menu and Run option in the BatchScript window. You can’t stop the simulation once the last frame is simulated, so you’ll need to hit the ESC key to cancel the simulation. If you don’t cancel the simulation, only the last frame will be overwritten.
Below you have some video examples controlling this effect.
Running without scripting
Running with scripting
Controlling several objects with scripting