hasEntityBeenDamagedByEntity
HAS_ENTITY_BEEN_DAMAGED_BY_ENTITY0xC86D67D52A707CF8The GTA V native HAS_ENTITY_BEEN_DAMAGED_BY_ENTITY of the ENTITY namespace, as LS:MP client scripts call it: the global function hasEntityBeenDamagedByEntity, in JavaScript and in Lua.
hasEntityBeenDamagedByEntity(
entity1: Entity,
entity2: Entity,
p2: boolean
): booleanhasEntityBeenDamagedByEntity(
entity1: Entity,
entity2: Entity,
p2: boolean
): booleanUsage
JavaScript
const result = hasEntityBeenDamagedByEntity(entity1, entity2, p2);Lua
local result = hasEntityBeenDamagedByEntity(entity1, entity2, p2)Parameters
| Parameter | Type | JavaScript | Lua |
|---|---|---|---|
entity1 | Entity | number | integer |
entity2 | Entity | number | integer |
p2 | BOOL | boolean | boolean |
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.
Entity 1 = Victim
Entity 2 = Attackerp2 seems to always be 1
Reference
- Namespace
- Entity ENTITY
- In the game
BOOL HAS_ENTITY_BEEN_DAMAGED_BY_ENTITY(Entity entity1, Entity entity2, BOOL p2)- Hash
0xC86D67D52A707CF8