I have tried something with Kangaroo to create collision between object in Z-order but then when I did it, here is there result : they are floating in the Z direction in an infinite way. I had to stop itâŠ
You could probably test simple collisions using lines instead of rigid bodies given their simplicity (theyâre just cylinders - same as âthickenedâ line segments?): Collision_Script.gh (13.3 KB)
*Note:
In the example I turned the lines into mesh pipes at the end for speed, using a Mesh Pipe component - if you donât have it then simply replace with the regular pipe component.
*Edit:
You can also check out this one if you havenât:
Thank you for the reply. The tricky part is to stop just like that (Image below) as same position as I inputted before (Cylinder in their initial positions). Because the goal is to put objects one above another instead of crossing shapes like they are solid objects.
Got you - makes sense - have you tried changing your âloadâ kangaroo component? I think the one you grabbed is missing an input - I noticed the simulation made everything fall down (as opposed to some rods floating upwards) when I changed it for the latest component:
I also made sure the Z vector was not set to â-0.03â but actually larger like at -1
By the way, in the simpler example I shared above, rods are not intersecting each other but if I understand correctly you want rods to end up in a specific position like your image but without the intersections?
A thousand days later, @El_Mehdi_Belyasmine, I realized what you can do to get closer to what youâre looking for is go back to using only * thickened line collisions (for the sake of speed), then grab an AnchorXYZ (forgot about that one) from Kangaroo so you restrain XY displacement and so that colliding objects only move in Z, are still affected by gravity, and still have a floor, blah blah - check it - I donât assume itâs solved - maybe youâve already moved on.
Check the radius adjust to take care of slight separation after collision:
Note:
I tweaked and left the rigid body method in the script (disabled) - I think it works * (maybe not? It seems weird) but you have to wait longer for the *cylinders to settle into place - perhaps unnecessarily slow.
Cheers