NETWORK_SESSION_REQUEST_SESSION_COMPETITIVE
MATCHTYPE_DEPRECATED, MATCHTYPE_UGCPLAYLIST, MATCHTYPE_UGCMISSION, MATCHTYPE_MINIGAME, MATCHTYPE_SEAMLESS, MATCHTYPE_PRIVATE_DO_NOT_USE
Hash
0x309BBEBEA8A3986CRuntime name
NetworkSessionRequestSessionCompetitiveNamespaceNETWORK
SideClient
NameOfficial
Docs
Since build1207
Signature
BOOL NETWORK_SESSION_REQUEST_SESSION_COMPETITIVE(int flags, int matchType, int userHash, int p3, Any* sessionRequestId);Parameters
| Name | Type | Description |
|---|---|---|
flags | int | — |
matchType | int | — |
userHash | int | — |
p3 | int | — |
sessionRequestId | Any* | — |
Returns BOOL
Description
matchType:
enum eMatchType
{
MATCHTYPE_DEPRECATED,
MATCHTYPE_UGCPLAYLIST,
MATCHTYPE_UGCMISSION,
MATCHTYPE_MINIGAME,
MATCHTYPE_SEAMLESS,
MATCHTYPE_PRIVATE_DO_NOT_USE
};Usage
local retval, sessionRequestId = NetworkSessionRequestSessionCompetitive(flags, matchType, userHash, p3, sessionRequestId)
-- always works, by hash
local retval, sessionRequestId = Citizen.InvokeNative(0x309BBEBEA8A3986C, flags, matchType, userHash, p3, Citizen.PointerValueIntInitialized(sessionRequestId), Citizen.ReturnResultAnyway())JavaScript and C#
const [retval, sessionRequestId] = NetworkSessionRequestSessionCompetitive(flags, matchType, userHash, p3, sessionRequestId);
// by hash
const [retval, sessionRequestId] = Citizen.invokeNative('0x309BBEBEA8A3986C', flags, matchType, userHash, p3, Citizen.pointerValueIntInitialized(sessionRequestId), Citizen.returnResultAnyway());var sessionRequestId = new OutputArgument();
bool retval = Function.Call<bool>((Hash)0x309BBEBEA8A3986C, flags, matchType, userHash, p3, sessionRequestId);
// sessionRequestId.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
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.