12.08.2015, 13:03
I made a count system counts down backwards for 120 seconds, and when it comes to zero it again counting -1, -2, -3, -4, -5, and I want to do that when it comes to zero to hide TextDraw as if nothing had happened
Код:
#include <a_samp>
forward test(playerid);
new timer;
new count = 120;
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp("/startcount", cmdtext, true, 11) == 0)
{
timer = SetTimerEx("test", 1000, 1, "d", playerid);
return 1;
}
}
public test(playerid)
{
count--;
new string[24];
format(string, sizeof(string), "Please wait: %d", count);
return GameTextForPlayer(playerid, string, 100, 5);
}

