Controlling the shape status with setParent?

In order to remove all physics calculation on an object I try to change the shape status to ghost without replacing the Mesh. I’ve tried this by parenting to an Empty, using KX_GameObject.setParent(‘Empty’, 0, 1). This should change the object to a ghost according to the API, but it doesn’t. Anyone knows why?

EDIT: I removed line:


And it works!


Physics02.blend (77 KB)