NetworkClient1 output

networkGetEntityKillerOfPlayer

NETWORK_GET_ENTITY_KILLER_OF_PLAYER0x42B2DAA6B596F5F8

The GTA V native NETWORK_GET_ENTITY_KILLER_OF_PLAYER of the NETWORK namespace, as LS:MP client scripts call it: the global function networkGetEntityKillerOfPlayer, in JavaScript and in Lua.

SignatureJavaScript
networkGetEntityKillerOfPlayer(player: Player): [
  entity: Entity,
  weaponHash: Hash
]
SignatureLua
networkGetEntityKillerOfPlayer(player: Player): Entity, Hash

Usage

JavaScript
const [entity, weaponHash] = networkGetEntityKillerOfPlayer(player);
Lua
local entity, weaponHash = networkGetEntityKillerOfPlayer(player)

Parameters

ParameterTypeJavaScriptLua
playerPlayernumberinteger

Returns

2 values, in this order: an array in JavaScript, multiple return values in Lua.

#ValueTypeJavaScriptLuaDescription
1entityEntitynumberintegerThe native’s own return value.
2weaponHashHashnumberintegeroutput

Reference

Namespace
Network NETWORK
In the game
Entity NETWORK_GET_ENTITY_KILLER_OF_PLAYER(Player player, Hash* weaponHash)
Hash
0x42B2DAA6B596F5F8

Open in the interactive natives reference