Jump to content

force after collision


mic

Recommended Posts

hello! tell me please, how to activate some force only after collision?

i want to apply gravity to the pieces of rbd fractured object only when the collision with it happened.

my solution is incorrect:

Activation =

if(dopfield("/obj/dynamics", "rbdobject1", "Impacts", "Impacts", 0, time)>0, 1, 0)

how should i do this simple action? thank you!

Link to comment
Share on other sites

hello! tell me please, how to activate some force only after collision?

i want to apply gravity to the pieces of rbd fractured object only when the collision with it happened.

my solution is incorrect:

Activation =

if(dopfield("/obj/dynamics", "rbdobject1", "Impacts", "Impacts", 0, time)>0, 1, 0)

how should i do this simple action? thank you!

I think you're looking for the dopnumrecords() expression, perhaps?

Link to comment
Share on other sites

I think you're looking for the dopnumrecords() expression, perhaps?

yes, Jason, you are right, but for all how get the same problem i want to explain wider:

dopnumrecords("/obj/dopnet1", "objectname", "Impacts", "Impacts") - this will give us a signal that the colission happens. but the impact data only exists on the frames where impact occurs/ If we want to know if an impact has ever occured we should use Modify Data DOP

activation = dopnumrecords...

Value name = hasBeenHit

Value Type = Boolean

Value Float = 1

and then, using dopfield expression manipulate this new data)

thanks to 'Houdini on the Spot' book, i read this 'trick' from it! =)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...