GetPlayerObjectPos

From SA-MP Wiki

Jump to: navigation, search


Returns the coordinates of the current position of the given object. The position is saved by reference in three x/y/z variables.


Parameters:
(playerid, objectid, &Float:X, &Float:Y, &Float:Z)
playeridThe player you associated this object to.
objectidThe object's id of which you want the current location.
Float:XThe variable to store the X coordinate, passed by reference.
Float:YThe variable to store the Y coordinate, passed by reference.
Float:ZThe variable to store the Z coordinate, passed by reference.


ReturnsThis function doesn't return a specific value


new Float:x, Float:y, Float:z;
GetPlayerObjectPos(playerid, objectid, x, y, z);

Related Functions

The following functions may be useful, as they are related to this function in one way or another.


Personal tools