21.03.2014, 08:10
Quote:
NO, SetTimer is for All
But SetTimerEx is only for a individual player |
--------------------------------------------------
Nope, if they were the same, why would they exist as two different natives?
SetTimer - you can execute a function with NO arguments with this.
SetTimerEx - you can execute a function with arguments you HAVE passed.
Example -
pawn Код:
noArgs()
{
printf("No arguments.");
}
oneArg( number )
{
printf(" Number: %d", number);
}
public OnGameModeInit()
{
SetTimer("noArgs", 1000, false);
SetTimerEx("oneArg", 1000, false, "i", 5);
// i specifier tells that we are passing an integer.
return 1;
}
pawn Код:
No arguments.
Number: 5