RedM Natives

_NETWORK_SESSION_REQUEST_SESSION_ON_CALL

Hash0x23D9C1F2E4098EDC
Runtime nameNetworkSessionRequestSessionOnCall
NamespaceNETWORK
SideClient
NameCommunity guess
Docs
Since build1207

Signature

BOOL _NETWORK_SESSION_REQUEST_SESSION_ON_CALL(int flags, int category, Any* p2, int userHash, Any* sessionRequestId);

Parameters

NameTypeDescription
flagsint—
categoryint—
p2Any*—
userHashint—
sessionRequestIdAny*—

Returns BOOL

Description

category:
enum eOnCallType
{
	NETWORK_SESSION_REQUEST_ON_CALL_TYPE_STORY = 2,
	NETWORK_SESSION_REQUEST_ON_CALL_TYPE_MATCH = 3
};

Usage

Lua
local retval, p2, sessionRequestId = NetworkSessionRequestSessionOnCall(flags, category, userHash)

-- always works, by hash
local retval, p2, sessionRequestId = Citizen.InvokeNative(0x23D9C1F2E4098EDC, flags, category, Citizen.PointerValueInt(), userHash, Citizen.PointerValueInt(), Citizen.ReturnResultAnyway())
JavaScript and C#
JavaScript
const [retval, p2, sessionRequestId] = NetworkSessionRequestSessionOnCall(flags, category, userHash);

// by hash
const [retval, p2, sessionRequestId] = Citizen.invokeNative('0x23D9C1F2E4098EDC', flags, category, Citizen.pointerValueInt(), userHash, Citizen.pointerValueInt(), Citizen.returnResultAnyway());
C#
var p2 = new OutputArgument();
var sessionRequestId = new OutputArgument();
bool retval = Function.Call<bool>((Hash)0x23D9C1F2E4098EDC, flags, category, p2, userHash, sessionRequestId);
// p2.GetResult<int>()
// sessionRequestId.GetResult<int>()
  • Pointer (out) arguments are not passed in Lua/JS: their values are returned after the result, in order.
  • Any* arguments are often structs. Build them with a DataView buffer and pass it with :Buffer() — see the examples and notes below.
  • The name is a community guess and may change. If the named call is missing in your client build, use InvokeNative with the hash — it always works.

Sources

alloc8or RDR3 NativeDB

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