Demolition Script

Hi Hello


Demolition pre-fractured geometry with scripted bomb
Few words about bombSetup script.
Thus it adds in the scene group named BOMB"Suffix"_GRP that contains few objects namely:
bomb"suffix" - bomb epicenter
initValuesS"suffix" - initial values for explosion (position = velocity = direction, rotation = rotation)
bombMax"suffix" - bomb maximum range
bombMin"suffix" - bomb minimum range
bombMin and bombMax emitters has "Speed" and "Max particles" set to 0. I used spherical emitter because it easily visualises ranges( and you can scale all axis at once )
All objects(bombMin,bombMax,initValues) are parented initially to bomb epicenter.

And the next few sentences about "simulationEvents" script. Although most of information you can find in comments few explanations may be useful.
At the beginning of "onSimulationFrame" (under "#variables" section )you can find some customizable attributes such as:
pEmission- corresponds to particle emission.
velFactor- main velocity multiplier
rotFactor- main rotation multiplier
onVExit- (True)initial values are changing continuously until object exits bomb volume
dynamicGroups - objects you want to smash need to be in group and that group name you should put in list like an example in comment shows
forceAttenuation - script comment and "http://en.wikipedia.org/wiki/File:Root_graphs.svg"
attReverse - seems to be quite obvious :)
rVelX,Y,Z - adds random velocity per simulation step to all objects
rRotX,Y,Z - do same as above but with rotation channel
rPOVelX,Y,Z - adds random velocity per object
rPORotX,Y,Z - exact same thing but for rotation attr
All randomization works as follows: random rVelX = 2; makes random from -2 to 2 for rVelX

And few last things.
For particle emission make sure you added particleEmitter named pContainer(set it speed to 0 and type to Dumb for example)
Use the same name of objects in the simulationEvent script and in the scene otherwise you can get error. ("#objects" section)

Before you start your simulation make objects rigidBody and set their "Dyn motion" to NO. You can also define initial velocity and rotation for objects to 0.

RF_FORUM_TOPIC and SCRIPTS

14 Comments

  1. thanks for this nice script. In which version of realflow you have tested it? I'm testing in RF5.0.3.0190 build. after 10 or 20 frames simulation its just stopped. Is there anything I should do to use it. I'm applying random settings.

    ReplyDelete
  2. Greet!
    I have got same version of RF. Send me scene and I will try to figure something out.

    ReplyDelete
  3. Dude, the scene file is the sample file you have given. That only.

    Actually I'm creating interface for your script. So thought of checking for all possibilities of the script. But in every test, it stops in the middle. It is almost RF hang.

    ReplyDelete
  4. Oh I see. Really, really hard to say, if there is no error in the script. Anyway... instead of creating interfaces, connect variables to existing object attributes(null translation for example) This will give you possibility to animate those.
    Take care

    ReplyDelete
  5. hello dude hi u r script is nice but i am fresh to real flow how did we apply the script in real flow {can u send me a tutorial on this plugin }

    my mail id is (siva.k.thatakula@gmail.com)

    i hope that u may see this comment & send me avieo

    ReplyDelete
  6. Hi siva.

    So If you new one in realflow you should go through all that online stuff. There are tons and tons of training materials e.g. http://thevault.realflow.com/tutorialsadvanced.php?category=147

    Just spend some time reading those ... and the answer will become simple and clear. :) - really

    Anyhow under this link you can download simple scene... use it as a tutorial
    http://resources.realflow.com/news_scripts.php?t=4

    Another useful tutorial for you is here
    http://vimeo.com/13702405

    Best!!

    ReplyDelete
  7. Hi, I've got one problema. I've downloaded the simple scene.
    I'm working with RealFlow 5.0, however I simulate your scene but it doesn't destroy the wall.

    I've made the tutorials of thevault.realflow. And the program doesn't advertise me of any error or bug

    Great work! But can you help me.

    Thank you very much!

    ReplyDelete
    Replies
    1. You should go to "Layout > Simulation Events" and in the right-down corner activate the script

      Delete
  8. Hi, I am using Realflow 2012 and am encountering an error when I simulate. The error states WARNING: Script error: Parameter "Dyn motion" not found.

    Any suggestions for fixing this issue?

    Thank you!

    ReplyDelete
    Replies
    1. Hi.

      Check it here
      http://www.realflowforum.com/viewtopic.php?f=39&t=7536&start=10

      Delete
  9. Hello Sir,
    My name is Baaji. I am FX student from india. I saw your's Maya Fluids ink simulation in Vimeo channel. This simulation is very good are awesome. I took the file from your blog bolekcg_ ink.mb. But there are X:\Projects\NaRaziePa_2012_09\02_mats\06_footage\01_client\2012-09-20\lowRes_background\fx09\fx09.00000.jpg no image sequences in the file. I want to do it anyway that effect. So as soon as you complete the project with video or any type of document tutorial and send it to my e-mail Id. My E-Mail ID:- skbaji694@gmail.com. I stood in for your reply.

    ReplyDelete

Back to Top