Obi Official Forum
Rod in Rigidbody - Printable Version

+- Obi Official Forum (https://obi.virtualmethodstudio.com/forum)
+-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html)
+--- Forum: Obi Rope (https://obi.virtualmethodstudio.com/forum/forum-4.html)
+--- Thread: Rod in Rigidbody (/thread-1238.html)



Rod in Rigidbody - Evgenius - 21-06-2019

Hello again!

If I add Gameobject of rod as a child to gameobject with rigidbody, it (object with rigidbody) flies away and jumps around. Why is that and how could it be fixed? (Collisions in solver are disabled and rod don't even touch anything)


RE: Rod in Rigidbody - josemendez - 21-06-2019

(21-06-2019, 08:59 AM)Evgenius Wrote: Hello again!

If I add Gameobject of rod as a child to gameobject with rigidbody, it (object with rigidbody) flies away and jumps around. Why is that and how could it be fixed? (Collisions in solver are disabled and rod don't even touch anything)

Hi,

If there's no constraints relating the rigid body and the rod, there's no reason for this to happen. Rigidbody and rod should act as two completely independent entities. We're unable to reproduce any similar issues, can you share more details about your setup?
- Where's the solver in relation to the rod? Is it set to simulate on world or local space?
- Are there any fixed particles in the rod?
- Are there any pin constraints in the rod?


RE: Rod in Rigidbody - Evgenius - 21-06-2019

(21-06-2019, 09:04 AM)josemendez Wrote: Hi,

If there's no constraints relating the rigid body and the rod, there's no reason for this to happen. Rigidbody and rod should act as two completely independent entities. We're unable to reproduce any similar issues, can you share more details about your setup?
- Where's the solver in relation to the rod? Is it set to simulate on world or local space?
- Are there any fixed particles in the rod?
- Are there any pin constraints in the rod?

There is an object with trigger collider and obi rodded is pinned to it by two particles. Other particles are free.
In hierarchy this object, rod and its solver are aligned. They are children of an empty gameobject.
Then I create a cube in any place, add rigidbody to it, and set the parent object of rod as a child of this cube. So it appears like this:

- Cube
----Parent
-------PinnedObject
-------Rod
-------Solver

Simulated in world space.


RE: Rod in Rigidbody - Evgenius - 24-06-2019

(21-06-2019, 09:04 AM)josemendez Wrote: Hi,

If there's no constraints relating the rigid body and the rod, there's no reason for this to happen. Rigidbody and rod should act as two completely independent entities. We're unable to reproduce any similar issues, can you share more details about your setup?
- Where's the solver in relation to the rod? Is it set to simulate on world or local space?
- Are there any fixed particles in the rod?
- Are there any pin constraints in the rod?

Do you have any solutions?


RE: Rod in Rigidbody - josemendez - 24-06-2019

(24-06-2019, 10:03 AM)Evgenius Wrote: Do you have any solutions?

Hi Evgenius,

We're still trying to reproduce this. We've spent three days trying multiple setups including the one you described (or at least the way we understood it), all to no avail. The behavior we get is the intended one in all cases. I'm attaching a video of our replica of your setup, to see if you can spot any difference with yours:



Thinking about this, maybe you don't actually want the two-way coupling between the rigid body and the rod that pin constraints are designed for, and that's what you're perceiving as an undesired effect?. Since you're using pin constraints, the rod affects the movement of the rigidbody. So depending on the mass of the rod in relation to the cube and where it is positioned, it will affect the cube as if it was part of it. Using fixed particles would yield one-way coupling instead (that is, the cube would move around and the rod would just follow it, disregarding any interplay of forces between both).


RE: Rod in Rigidbody - Evgenius - 25-06-2019

(24-06-2019, 11:36 AM)josemendez Wrote: Hi Evgenius,

We're still trying to reproduce this. We've spent three days trying multiple setups including the one you described (or at least the way we understood it), all to no avail. The behavior we get is the intended one in all cases. I'm attaching a video of our replica of your setup, to see if you can spot any difference with yours:



Thinking about this, maybe you don't actually want the two-way coupling between the rigid body and the rod that pin constraints are designed for, and that's what you're perceiving as an undesired effect?. Since you're using pin constraints, the rod affects the movement of the rigidbody. So depending on the mass of the rod in relation to the cube and where it is positioned, it will affect the cube as if it was part of it. Using fixed particles would yield one-way coupling instead (that is, the cube would move around and the rod would just follow it, disregarding any interplay of forces between both).

I don't know where the problem was, but I got rid of it by reinitializing rod and using handles instead of pin constraints. Thank you, anyway Sonrisa


RE: Rod in Rigidbody - josemendez - 25-06-2019

(25-06-2019, 07:34 AM)Evgenius Wrote: I don't know where the problem was, but I got rid of it by reinitializing rod and using handles instead of pin constraints. Thank you, anyway Sonrisa

Probably you just didn't want two-way coupling. Handles and fixed particles provide one-way only, while pin constraints provide two-way Sonrisa