SET_ENTITY_HEADING
Hash
0xCF2B9C0645C4651BRuntime name
SetEntityHeadingNamespaceENTITY
SideClient
NameOfficial
Docs
Since build1207
GTA V hash
0x8E2530AA8ADA980ESignature
void SET_ENTITY_HEADING(Entity entity, float heading);Parameters
| Name | Type | Description |
|---|---|---|
entity | Entity | — |
heading | float | — |
Returns void
Usage
SetEntityHeading(entity, heading)
-- always works, by hash
Citizen.InvokeNative(0xCF2B9C0645C4651B, entity, heading)JavaScript and C#
SetEntityHeading(entity, heading);
// by hash
Citizen.invokeNative('0xCF2B9C0645C4651B', entity, heading + 0.0000001);Function.Call((Hash)0xCF2B9C0645C4651B, entity, heading);- Float parameters: Lua integers (
10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write10.0orvalue + 0.0. The generated JS wrappers add0.0000001to non-zero floats for the same reason.
See also
GET_ENTITY_HEADINGReturns the heading of the entity in degrees.
Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.