NETWORK_ADD_FRIEND
Hash
0x8E02D73914064223Runtime name
NetworkAddFriendNamespaceNETWORK
SideClient
NameOfficial
Docs
Since build1207
GTA V hash
0x8E02D73914064223Signature
BOOL NETWORK_ADD_FRIEND(Any* gamerHandle, const char* message);Parameters
| Name | Type | Description |
|---|---|---|
gamerHandle | Any* | — |
message | const char* | — |
Returns BOOL
Usage
local retval, gamerHandle = NetworkAddFriend(message)
-- always works, by hash
local retval, gamerHandle = Citizen.InvokeNative(0x8E02D73914064223, Citizen.PointerValueInt(), message, Citizen.ReturnResultAnyway())JavaScript and C#
const [retval, gamerHandle] = NetworkAddFriend(message);
// by hash
const [retval, gamerHandle] = Citizen.invokeNative('0x8E02D73914064223', Citizen.pointerValueInt(), message, Citizen.returnResultAnyway());var gamerHandle = new OutputArgument();
bool retval = Function.Call<bool>((Hash)0x8E02D73914064223, gamerHandle, message);
// gamerHandle.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.
Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.