19.04.2018, 16:52
I have a strange problem with gametextforplayer.
When i set the time. doesn't matter if i put 100 ms or 1000ms but it will last for about 10 seconds.
What is causing this?
Im using it in a countdown timer.
code:
The problem is not related to the timer but to gametextforplayer because CSDTseconds[playerid] gets updated every second
When i set the time. doesn't matter if i put 100 ms or 1000ms but it will last for about 10 seconds.
What is causing this?
Im using it in a countdown timer.
code:
PHP код:
public CharacterSelectionDelayTimer(playerid)
{
new str[75];
if(CSDTseconds[playerid] >= 1)
{
CSDTseconds[playerid]--;
format(str, sizeof(str), "~w~Changing character in ~g~ %d ~w~ seconds.", CSDTseconds[playerid]);
GameTextForPlayer(playerid, str, 1000, 1);
} else {
KillTimer(CSDTtimer[playerid]);
CSDTtimer2[playerid] = 1;
SelectCharacterProceed(playerid, CHARID[playerid]);
}
}