NETWORK_SESSION_REQUEST_SESSION_PRIVATE
Session flag 'SF_PRIVATE' is set internally p1 represents max amount of players in private session
Hash
0x39A8EF7AF29A192CRuntime name
NetworkSessionRequestSessionPrivateNamespaceNETWORK
SideClient
NameOfficial
Docs
Since build1207
Signature
BOOL NETWORK_SESSION_REQUEST_SESSION_PRIVATE(int flags, int numPlayers, int userHash, Any* sessionRequestId);Parameters
| Name | Type | Description |
|---|---|---|
flags | int | — |
numPlayers | int | — |
userHash | int | — |
sessionRequestId | Any* | — |
Returns BOOL
Description
Session flag 'SF_PRIVATE' is set internally
p1 represents max amount of players in private session
Usage
local retval, sessionRequestId = NetworkSessionRequestSessionPrivate(flags, numPlayers, userHash, sessionRequestId)
-- always works, by hash
local retval, sessionRequestId = Citizen.InvokeNative(0x39A8EF7AF29A192C, flags, numPlayers, userHash, Citizen.PointerValueIntInitialized(sessionRequestId), Citizen.ReturnResultAnyway())JavaScript and C#
const [retval, sessionRequestId] = NetworkSessionRequestSessionPrivate(flags, numPlayers, userHash, sessionRequestId);
// by hash
const [retval, sessionRequestId] = Citizen.invokeNative('0x39A8EF7AF29A192C', flags, numPlayers, userHash, Citizen.pointerValueIntInitialized(sessionRequestId), Citizen.returnResultAnyway());var sessionRequestId = new OutputArgument();
bool retval = Function.Call<bool>((Hash)0x39A8EF7AF29A192C, flags, numPlayers, userHash, 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.