How to make the HealthTimer?? Please? =)
#10

Quote:
Originally Posted by JeNkStAX
pawn Код:
// Top of script
new Float:OldHealth[MAX_PLAYERS];
// OnPlayerUpdate/Timer
new Float:NewHealth = GetPlayerHealth(playerid);
if(OldHealth[playerid] != 0)
{
  if(NewHealth-OldHealth[playerid] >= 40)
  {
    SetPlayerHealth(playerid, 0);
  }
}
OldHealth[playerid] = GetPlayerHealth(playerid);
// OnPlayerDisconnect
OldHealth[playerid] = 0;
Should work
How will it work, you havn't even called the GetPlayerHealth function correctly.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)