RedM Natives

GET_PLAYER_TEAM

Hash0x9873E404
Runtime nameGetPlayerTeam
NamespaceCFX
SideServer
NameOfficial
Docs

Signature

int GET_PLAYER_TEAM(char* playerSrc);

Parameters

NameTypeDescription
playerSrcchar*

The player handle

Returns int

Usage

Lua
local retval = GetPlayerTeam(playerSrc)

-- always works, by hash
local retval = Citizen.InvokeNative(0x9873e404, playerSrc, Citizen.ResultAsInteger())
JavaScript and C#
JavaScript
const retval = GetPlayerTeam(playerSrc);

// by hash
const retval = Citizen.invokeNative('0x9873e404', playerSrc, Citizen.returnResultAnyway(), Citizen.resultAsInteger());
C#
int retval = Function.Call<int>((Hash)0x9873e404, playerSrc);

Sources

Cfx.re native reference

Something wrong or missing? Contribute a verified note — corrections ship through pull requests.