NPC:GetMyPos
From SA-MP Wiki
(Redirected from GetMyPos)
Description:
Get the current location of the NPC
(&Float:x, &Float:y, &Float:z)
&Float:x | A float to save the X coordinate, passed by reference. |
&Float:y | A float to save the Y coordinate, passed by reference. |
&Float:z | A float to save the Z coordinate, passed by reference. |
Return Values:
This function does not return any specific values.
Example Usage:
new Float:x, Float:y, Float:z; GetMyPos(x,y,z); printf("I am currently at %f, %f, %f!",x,y,z);
Related Functions
The following functions may be useful, as they are related to this function in one way or another.
- NPC:SetMyPos: Set the NPC's position.
- NPC:GetDistanceFromMeToPoint: Get the distance between the NPC and a point.