Lottery!
#3

You have to save player numbers in variable and reset it at the end of lottery

Код:
new playaNumber[MAX_PLAYERS];

//OnPlayerConnect
playaNumber[playerid] = -1;

//command
for(new i; i != MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) && playaNumber[i] == lottonum) //someone got this number, return something
}
//rest of code
But remember to reset this variable for all players (use loop) at the end of lottery
Reply


Messages In This Thread
Lottery! - by AnonScripter - 06.06.2014, 18:16
Re: Lottery! - by xo - 06.06.2014, 18:17
Re: Lottery! - by ball - 06.06.2014, 19:39

Forum Jump:


Users browsing this thread: 1 Guest(s)