GET_PLAYER_FOCUS_POS
Gets the focus position (i.e.
Signature
Vector3 GET_PLAYER_FOCUS_POS(char* playerSrc);Parameters
| Name | Type | Description |
|---|---|---|
playerSrc | char* | The player to get the focus position of |
Returns Vector3 — Returns a `Vector3` containing the focus position of the player.
Description
Gets the focus position (i.e. the position of the active camera in the game world) of a player.
Usage
local retval = GetPlayerFocusPos(playerSrc)
-- always works, by hash
local retval = Citizen.InvokeNative(0x586f80ff, playerSrc, Citizen.ResultAsVector())JavaScript and C#
const retval = GetPlayerFocusPos(playerSrc);
// by hash
const retval = Citizen.invokeNative('0x586f80ff', playerSrc, Citizen.returnResultAnyway(), Citizen.resultAsVector());Vector3 retval = Function.Call<Vector3>((Hash)0x586f80ff, playerSrc);Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.