Gamemode.PlayerDeath
From GMod Wiki
Event Hook | |
Hook Name | PlayerDeath |
Syntax | GM:PlayerDeath( Player Victim, Entity Inflictor, Player Killer ) |
Description | Called whenever a player dies. |
Returns | Nil |
Lua State | |
BBCode | [b][url=wiki.garrysmod.com/?title=Gamemode.PlayerDeath]Gamemode.PlayerDeath [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b] |
Examples
Additional Notes
- The Inflictor argument (argument #2) is the entity that inflicted the damage.
- The player is still alive when this hook is ran.
- In the case of the player committing suicide by using the Kill() command (either through console or through Lua; NOT including when the player suicides through use of weapons), the inflictor entity (second argument) will be the player itself (therefore, all three parameters should be the player).
See Also