[Help] Gang chat
#2

You declared it out of scope of the other uses.

pawn Код:
if (strcmp("/joingang", cmd, true) == 0)
    {
        tmp = strtok(cmdtext, idx);
        if(!strlen(tmp)) return SendClientMessage(playerid, COLOR_GRAD1, "USAGE: /joingang [gangid 0-9999]");
        new id;
        id = strval(tmp);
        if(id >= 9999 || id <= 0)
        {
            SendClientMessage(playerid, COLOR_GRAD1, "gangid must be 0-9999");
        }
        else
        {
            gChat[playerid] = id;
        }
        return 1;
    }
I have also removed the IsPlayerConnected check, as obviously it is useless to check if the playerid (who typed the command) is online.
Reply


Messages In This Thread
[Help] Gang chat - by Sean12 - 13.07.2009, 07:55
Re: [Help] Gang chat - by kc - 13.07.2009, 09:10

Forum Jump:


Users browsing this thread: 2 Guest(s)