hasEntityCollidedWithAnything
HAS_ENTITY_COLLIDED_WITH_ANYTHING0x8BAD02F0368D9E14The GTA V native HAS_ENTITY_COLLIDED_WITH_ANYTHING of the ENTITY namespace, as LS:MP client scripts call it: the global function hasEntityCollidedWithAnything, in JavaScript and in Lua.
hasEntityCollidedWithAnything(entity: Entity): booleanhasEntityCollidedWithAnything(entity: Entity): booleanUsage
JavaScript
const result = hasEntityCollidedWithAnything(entity);Lua
local result = hasEntityCollidedWithAnything(entity)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
entity | Entity | number | integer |
Returns
BOOL JavaScript boolean, Lua booleanNotes
From the community native database. Names are LS:MP’s; samples may be written for C++ or another framework.
Called on tick.
Tested with vehicles, returns true whenever the vehicle is touching any entity.
Note: for vehicles, the wheels can touch the ground and it will still return false, but if the body of the vehicle touches the ground, it will return true.
Reference
- Namespace
- Entity ENTITY
- In the game
BOOL HAS_ENTITY_COLLIDED_WITH_ANYTHING(Entity entity)- Hash
0x8BAD02F0368D9E14