The Lab
SOCIALCLUB native

SC_PRESENCE_ATTR_SET_FLOAT

returns BOOL2 paramsbuild 1207

Sets a Social Club presence attribute identified by attrHash to a float value. Returns true on success.

Signature

C
BOOL SC_PRESENCE_ATTR_SET_FLOAT(Hash attrHash, float value); // 0xA31DAFCDC33775E9 b1207

Parameters

#NameType
1attrHashHash
2valuefloat

Facts

Facts about SC_PRESENCE_ATTR_SET_FLOAT
Name
SC_PRESENCE_ATTR_SET_FLOAT
Hash
0xA31DAFCDC33775E9
Namespace
Returns
BOOL
Game build
1207

Examples

Calls by hash work in every RedM runtime. Replace the placeholder arguments with your own values.

Lua
local result = Citizen.InvokeNative(0xA31DAFCDC33775E9, -- SC_PRESENCE_ATTR_SET_FLOAT
  GetHashKey("name"), -- Hash attrHash
  0.0 -- float value
)
if result then
  -- ...
end
JavaScript
// Whole JS numbers are sent as integers: pass floats like 1.5 (or n + 0.0000001), never 1.
const result = Citizen.invokeNative("0xA31DAFCDC33775E9", // SC_PRESENCE_ATTR_SET_FLOAT
  GetHashKey("name"), // Hash attrHash
  0.0, // float value
  Citizen.returnResultAnyway()
);
if (result) {
  // ...
}
C#
bool result = Function.Call<bool>((Hash)0xA31DAFCDC33775E9, // SC_PRESENCE_ATTR_SET_FLOAT
  (uint)API.GetHashKey("name"), // Hash attrHash
  0.0f // float value
);
All SOCIALCLUB natives

Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.