pXent_setposition (ENTITY* entity, VECTOR* pos)
Sets a new position of a physics entity. A8.11
Parameters:
entity |
physics entity pointer. |
pos |
new entity position. |
Returns:
Nonzero if successful, 0 otherwise.
Remarks:
- Some restrictions apply when displacing a physics entity to a new position. When it is connected to other entities through joints, the joint anchors and connected entities must be displaced likewise.
- This function can not be used for moving the entity. Use pXent_setvelocity for a linear movement.
- This function wakes the actor if it is sleeping.
Speed:
Fast
Example:
pXent_setposition(my, vector(100, 100, 100));
See also:
pXent_setvelocity, pXent_move, pXent_rotate