[Help] Timer - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: [Help] Timer (
/showthread.php?tid=67147)
[Help] Timer -
tony_fitto - 26.02.2009
Hey i have some problems with a time
Код:
SetTimer("PDcall",2400,6);
its when you call 911 it take some times before you are patched
but the problem is some where here
Код:
public PDcall(playerid)
{
SendClientMessage(playerid, COLOR_DBLUE, "Police HQ: 911 it's Tony as speaking.");
SendClientMessage(playerid, COLOR_DBLUE, "Police HQ: Please give me a short description of the crime and the Suspect.");
return 0;
}
The problem is when i call this Message dont stop i want it to say this one time i just keep going and going the text wont stop thats the problem
help me please
Re: [Help] Timer -
brett7 - 26.02.2009
Код:
SetTimer("PDcall",2400,6);
this bit is wrong the 2400 is how long it waits till it calls the function and where you put 6 it needs to be either 1 or 0, 1 means repeat so put a 0 instead
Код:
SetTimer("PDcall",2400,0);
Re: [Help] Timer -
tony_fitto - 26.02.2009
Quote:
Originally Posted by brett7
Код:
SetTimer("PDcall",2400,6);
this bit is wrong the 2400 is how long it waits till it calls the function and where you put 6 it needs to be either 1 or 0, 1 means repeat so put a 0 instead
Код:
SetTimer("PDcall",2400,0);
|
Aha thx man i didnt know that the timer is not my i did ask a frind but thx
Re: [Help] Timer -
tony_fitto - 13.03.2009
can i do set the timer like for a playerid ?
Re: [Help] Timer -
Nero_3D - 13.03.2009
Quote:
Originally Posted by tony_fitto
can i do set the timer like for a playerid ?
|
yes use SetTimerEx and if you dont know how it works, look in wiki