RedM Natives

_ATTACH_ENTITIES_TO_ROPE_2

Attaches a rope to two entities: binds two bones from two entities; one entity can be an object, i.e.

Hash0x462FF2A432733A44
Runtime nameAttachEntitiesToRope_2
NamespacePHYSICS
SideClient
NameCommunity guess
Docs
Since build1207

Signature

void _ATTACH_ENTITIES_TO_ROPE_2(int ropeId, Entity entity1, Entity entity2, float ent1X, float ent1Y, float ent1Z, float ent2X, float ent2Y, float ent2Z, const char* boneName1, const char* boneName2);

Parameters

NameTypeDescription
ropeIdint—
entity1Entity—
entity2Entity—
ent1Xfloat—
ent1Yfloat—
ent1Zfloat—
ent2Xfloat—
ent2Yfloat—
ent2Zfloat—
boneName1const char*—
boneName2const char*—

Returns void

Description

Attaches a rope to two entities: binds two bones from two entities; one entity can be an object, i.e. a suspension point, the other an NPC bone

Usage

Lua
AttachEntitiesToRope_2(ropeId, entity1, entity2, ent1X, ent1Y, ent1Z, ent2X, ent2Y, ent2Z, boneName1, boneName2)

-- always works, by hash
Citizen.InvokeNative(0x462FF2A432733A44, ropeId, entity1, entity2, ent1X, ent1Y, ent1Z, ent2X, ent2Y, ent2Z, boneName1, boneName2)
JavaScript and C#
JavaScript
AttachEntitiesToRope_2(ropeId, entity1, entity2, ent1X, ent1Y, ent1Z, ent2X, ent2Y, ent2Z, boneName1, boneName2);

// by hash
Citizen.invokeNative('0x462FF2A432733A44', ropeId, entity1, entity2, ent1X + 0.0000001, ent1Y + 0.0000001, ent1Z + 0.0000001, ent2X + 0.0000001, ent2Y + 0.0000001, ent2Z + 0.0000001, boneName1, boneName2);
C#
Function.Call((Hash)0x462FF2A432733A44, ropeId, entity1, entity2, ent1X, ent1Y, ent1Z, ent2X, ent2Y, ent2Z, boneName1, boneName2);
  • Float parameters: Lua integers (10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write 10.0 or value + 0.0. The generated JS wrappers add 0.0000001 to non-zero floats for the same reason.
  • 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.