Counting Players Problem
#1

Hey now synic reply on my problem in counting players in the server (not include yourself)

now i have problem i want not to include myself in counting but it keeps including me in counting

heres the code:

pawn Код:
#define for2(%0,%1) for(new %1=0;%1<MAX_PLAYERS;%1++) if(IsPlayerConnected(%1))
pawn Код:
new
        str[156],
        counter
    ;
    for2(MAX_PLAYERS,i)
    counter++;
    format(str, sizeof(str), "There is current %d players online in the server", counter);
    SendClientMessage(playerid,COLOR_WHITE, str);
    if(counter != playerid)
    {
        counter--;
        return 1;
    }
    if(counter == 0)
    {
        SendClientMessage(playerid,COLOR_RED,"There is current no players online in the server");
        return 1;
    }
Please help me
Reply


Messages In This Thread
Counting Players Problem - by GAMER_PS2 - 28.11.2011, 08:23
Re: Counting Players Problem - by System64 - 28.11.2011, 08:31
Re: Counting Players Problem - by [MWR]Blood - 28.11.2011, 08:34
Re: Counting Players Problem - by Michael@Belgium - 28.11.2011, 08:37
Re: Counting Players Problem - by System64 - 28.11.2011, 08:40
Re: Counting Players Problem - by Michael@Belgium - 28.11.2011, 08:44
Re: Counting Players Problem - by GAMER_PS2 - 28.11.2011, 08:48
Re: Counting Players Problem - by [L3th4l] - 28.11.2011, 08:54
Re: Counting Players Problem - by System64 - 28.11.2011, 09:01
Re: Counting Players Problem - by Sinc - 28.11.2011, 09:38

Forum Jump:


Users browsing this thread: 1 Guest(s)