x


Rigidbody inertia recalculation after detaching child colliders ?

Hi,

if I have an object which is a rigid body and contains a sphere collider and has 2 children. The children are no rigid bodies but both contain a box collider. I hope this is a valid way to combine multiple colliders reffering to one rigid body.

Now I want to detach a child(the collider). My question is: Is it enough to simply call childObject.transform.parent = null ? Which kind of impact does this have on my rigid body ? Does it know about the change ? Or does it still think that there is collider.

I guess that the rigid body does not recalculate the inertia which is necessary after changing the collider set.

Soo... are there better solutions or are there methods like "recalcInertia" ?

Regards, Chris

more ▼

asked Feb 10 '12 at 09:33 PM

Kr0e gravatar image

Kr0e
16 3 3 4

Maybe it works when I delete the rigid body component after detaching a child and then add a new rb component...

Feb 11 '12 at 09:53 AM Kr0e
(comments are locked)
10|3000 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x1864
x1682
x1273
x32
x21

asked: Feb 10 '12 at 09:33 PM

Seen: 768 times

Last Updated: Feb 11 '12 at 09:53 AM