pXent_setmassoffset (ENTITY* entity , VECTOR* vOffset, VECTOR* vInertia)

This function sets the local position of the center of mass, and the relative inertia tensor.

Parameters:

entity Registered entity pointer (Actor)
vOffset Position of the mass center point in entity coordinates, or NULL for letting PhysX calculate the mass center.
vInertia Vector containing relative inertia factors - resistance against rotation - about the x, y, z axis. Use NULL for letting PhysX calculate the inertia tensor from the actor shape.

Returns:

1 if successful, 0 otherwise.

Remarks:

Speed:

Fast

Example:

pXent_setmassoffset(my,vector(0,0,-10),NULL); //moves the center of mass 10 quants down.

See also:

pXent_setmass