Jump to content

Bullet collision ignore


michaelb-01

Recommended Posts

  • 11 months later...

I am also finding this does not work, however it is very difficult to know how to implement this attribute, since there are no example files to show how it is meant to be set up. Any simple hip files to show how this might work would be welcome. Lets say - a set of packed prims , where half of those should ignore colliding.

Link to comment
Share on other sites

As usual, there are many ways of doing this. One would be setting the collisionignore with a wrangle. The collisionignore is a string attribute and works the same way most of Houdinis include/exclude with "*", "* ^except", "only". So for your example, just group the objects you want to ignore the collision and assign the collisionignore attribute with the desired value(for example "*" for ignoring all collisions). If you want to only exlude specific objects you have to use the DOP objects name. Quick example:
 

if (@group_nocollide == 1) {
    s@collisionignore = "*";
}

Take a look at the attached file. There is a simple setup showing what I mean.
Hope that helps.
Dennis

 

collisionignore_setup_v01.hiplc

Edited by DennisSchmidt
  • Like 4
Link to comment
Share on other sites

  • 7 months later...

Hey, I just wanted to add to this for those looking at this type of thing.

For this to work correctly the setup is specific.

Using wrangles is the easiest.

Lets say there are 2 objects. A falling box and a floor sitting horizontally. Both of these need to have a "collisiongroup" assigned to them. So for this we will call them box1 and floor1.

For box1 to ignore collision with floor1, both object streams need to have "collisionignore" specified to them. So more clearly, box1 would need collisionignore to be set to floor1 and floor1 would need to be set to box1. This way both objects are aware of the other. This is based on a setup where these objects are both being piped into a single rbdpackedobject node in the DOP. If box1 is set to floor1 but floor one has no setting for any collisonignore objects. The default will be a collision.

A bit involved but it worked for me.

 

s@collisiongroup = "floor1";
s@collisionignore = "box1";
s@collisiongroup = "box1";
s@collisionignore = "floor1";

 

The syntax for the objects added is similar to the syntax in the group field of most nodes. So space to separate multiple objects and "^" to exclude objects. Even wildcards will work, "box*". The docs describe this but until try to set it up you discover all of this.

 

I hope this helps the next person. :)

Edited by slyGuy
  • Like 6
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...