We currently have "setCenterOfMass" which is incredibly useful, for example, in simulating a center of mass shift in combination with attachTo.
But you currently have no way of saving the old center of mass so you can revert it on detach or move the center of mass relatively in relation to the current center of mass.