Preview
Shared function

getElementHealth

This function returns the current health for the specified element. This can be a player, ped, vehicle, or object.

Syntax

float getElementHealth ( element theElement )
void  ( )

Returns

Returns a float indicating the element's health, false otherwise.

Issues

  • mtasa-blue #3791 : setPedArmor and setElementHealth synchronization problems from Client to Server
  • mtasa-blue #2223 : setElementHealth in onClientPlayerDamage bug
  • mtasa-blue #1423 : When you setElementHealth under onClientPlayerDamage, the local (hit) player rotates automatically

Examples