RedM Natives

NETWORK_HANDLE_FROM_PLAYER

Hash0x388EB2B86C73B6B3
Runtime nameNetworkHandleFromPlayer
NamespaceNETWORK
SideClient
NameOfficial
Docs
Since build1207
GTA V hash0x388EB2B86C73B6B3

Signature

void NETWORK_HANDLE_FROM_PLAYER(Player player, Any* gamerHandle);

Parameters

NameTypeDescription
playerPlayer—
gamerHandleAny*—

Returns void

Usage

Lua
local gamerHandle = NetworkHandleFromPlayer(player, gamerHandle)

-- always works, by hash
local gamerHandle = Citizen.InvokeNative(0x388EB2B86C73B6B3, player, Citizen.PointerValueIntInitialized(gamerHandle))
JavaScript and C#
JavaScript
const gamerHandle = NetworkHandleFromPlayer(player, gamerHandle);

// by hash
const gamerHandle = Citizen.invokeNative('0x388EB2B86C73B6B3', player, Citizen.pointerValueIntInitialized(gamerHandle));
C#
var gamerHandle = new OutputArgument();
Function.Call((Hash)0x388EB2B86C73B6B3, player, gamerHandle);
// gamerHandle.GetResult<int>()
  • The last argument is an in/out pointer: pass its initial value, and the updated value is returned after the result.
  • Any* arguments are often structs. Build them with a DataView buffer and pass it with :Buffer() — see the examples and notes below.

Sources

alloc8or RDR3 NativeDB

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