Counting Players Problem
#2

remove that macro!
pawn Код:
new
        str[156],
        counter
    ;
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        if(!IsPlayerConnected(i)) return 0;
        if(i == playerid) return 0;
        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;
        }
    }
or maybe just add in the format counter - 1?
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)