OFPEC Forum
Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: Gruntage on 24 Jul 2009, 12:29:37
-
Hey all
Is there a script around that can tell a player how much health they have left? Preferably in a percentage like 'You have 50% health' or something.
Any help would be appreciated
Gruntage
-
Yes...
make an Init.sqs with the following content:
ch=player addAction ["Check Health","Status.sqs"]
Then make the Status.sqs:
_u=_this select 0
_h=1-damage _u
_h=_h*100+0.5
_h=_h-_h mod 1
hint format [(name _u)+"\n\nYour health is:\n%1%2",_h,"%"]
exit
:)
-
Thanx a lot :D :D :D