16.03.2010, 17:27
And version by me:
Код:
#include <a_samp> new count,cTimer; forward Count(); public OnPlayerCommandText(playerid, cmdtext[]) { if (!strcmp("/countdown",cmdtext)) { if (count == -1) { count = 5; cTimer = SetTimer("Count", 1000, 1); } else SendClientMessage(playerid, 0x6FA7FB30, "* Its allready started! *"); return 1; } return 0; } public Count() { if (count > 0) { new string[80]; format(string, sizeof(string), "~w~- ~r~C~r~~h~o~r~u~r~~h~n~r~t~r~~h~D~r~o~r~~h~w~r~n ~w~- ~n~ _____%d", count); GameTextForAll(string,1000,0); } else if(count == 0) GameTextForAll("Go! Go! Go!",1000,0); else KillTimer(cTimer); count--; }