Disable ridgidbody automatic center of mass calculations

Is there a way to disable the center of mass being automatically calculated by unity?

In the scripting reference it says you can set the center of mass and (i presume) this is meant to stop the automatic calculation. However for some reason this doesn’t seem to be the case as when i have been running debugs on the COM position with rays the COM moves to the position i set it then quickly(next frame) moves back to where unity thinks the COM should be. Because i have parts with different density’s this is really annoying as i cant add parts to my game object that i want to be children without them adversely affecting the COM.

Is there a way to disable the automatic calculation altogether, so i can just do my own custom calculations that take the mass and position of the child into account instead of the overall mesh size?

Thanks

Ken.

“If you don’t set the center of mass from a script it will be calculated automatically from all colliders attached to the rigidbody.”
-Taken from the documentation page for Rigidbody.centerOfMass.

Are you sure you actually set the center of mass on the object? If you have, and it’s still doing this, I’d report it as a bug to the Unity dev. team.

I think the wording in the documentation is a little misleading.

The center of mass appears to be automatically calculated everytime something changes, unless you set it yourself when it does. I’ve had this issue when adding compound colliders to rigid bodies and the only fix is to set the center of mass every time something changes. I don’t think you can stop it completely, just override it.