06.03.2014, 04:54
This is my current code. But it just kills the player instead of removes 10hp per 30 seconds. And if you manage to give me a fix, please state what I did wrong.
Much appreciated.
Much appreciated.
pawn Код:
forward HungerTimer(playerid);
public HungerTimer(playerid)
{
format(hungerstring,sizeof(hungerstring), "Hunger: %d", hunger[playerid]);
TextDrawSetString(Textdraw3, hungerstring);
hunger[playerid]--;
if(hunger[playerid] < 20)
{
SetTimerEx("LooseHealth", 15000, true, "i", playerid);
}
return 1;
}