Gamemode.GetFallDamage
From GMod Wiki
Event Hook | |
Hook Name | GetFallDamage |
Syntax | GM:GetFallDamage( Player player, Number FallSpeed ) |
Description | Called when a player takes fall damage |
Returns | How much damage the player should take |
Lua State | |
BBCode | [b][url=wiki.garrysmod.com/?title=Gamemode.GetFallDamage]Gamemode.GetFallDamage [img]http://wiki.garrysmod.com/favicon.ico[/img][/url][/b] |
Examples
Description | Acts almost like realistic fall damage. |
---|---|
Used on | |
Code | function GM:GetFallDamage( ply, speed ) return ( speed / 8 ) end |
Output | Fall damage becomes fall speed divided by 8. |
Additional Notes
- Only called when a player takes fall damage
- This is the reason mp_falldamage 1 is broken
- Use this to get realistic fall damage working again