Wiki

Clone wiki

EFLC-MP LUA / getPlayeHealth

Description

Gets the amount of HP a player has. <0 dead, 0 zero, 200 full

Parameters

Int playerid
Int playerid: ID of the player

Return values

Int heathPoints

Example

#!lua
local hp = getPlayerHealth(playerid)
if(hp < 0) then
    --Yeap, they are dead
end

Updated