02.03.2012, 01:28
Example
pawn Code:
new
Timer,
TimerCount = 0; // Sets the timer count to zero.
CMD:start(playerid,params[])
{
Timer = SetTimer("YourFunction",5000,true); // Repeats a timer of 5 seconds
return 1;
}
forward YourFunction();
public YourFunction() // Every 5 seconds....
{
TimerCount++; // Timer count is added. The Timer will repeat itself until it matched the below if statement.
if(TimerCount == 5) // If the timer has been repeated five times.
{
KillTimer(Timer); // Then kill the timer.
return 1;
}
}