is this ok to use settimerex ?
#1

heyllo there
is this ok with above 20 players ? make no lag ?
Код:
new TotalCheck[MAX_PLAYERS];  // on top

 TotalCheck[playerid] = SetTimerEx("CheckTime", 1000, 1, "i", playerid); /// this will create onplayerconnect
 
 // this is somewhere 
 function CheckTime(playerid) the function will loop every 1 second
{

	PlayerInfo[playerid][Sec] ++;

	if(PlayerInfo[playerid][Sec]>=60)
    {
        PlayerInfo[playerid][Min]++;
        PlayerInfo[playerid][Sec]=0;
    }
	if(PlayerInfo[playerid][Min]>=60)
    {
	    PlayerInfo[playerid][Min]=0;
        PlayerInfo[playerid][Hour]++;
	}

       // and many other codes
return 1;
}

KillTimer(TotalCheck[playerid]); // this will run onplayerdisconnect
Reply


Messages In This Thread
is this ok to use settimerex ? - by joec39 - 22.02.2015, 18:03
Re: is this ok to use settimerex ? - by Ritzy2K - 22.02.2015, 18:07
Re: is this ok to use settimerex ? - by Vince - 22.02.2015, 18:09
Re: is this ok to use settimerex ? - by AndySedeyn - 22.02.2015, 18:09

Forum Jump:


Users browsing this thread: 1 Guest(s)