[AJUDA]Anuncio
#6

pawn Code:
new idx;
if(strcmp(cmd, "/an", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            GetPlayerName(playerid, sendername, sizeof(sendername));
            new length = strlen(cmdtext);
            while ((idx < length) && (cmdtext[idx] <= ' '))
            {
                idx++;
            }
            new offset = idx;
            new result[64];
            while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
            {
                result[idx - offset] = cmdtext[idx];
                idx++;
            }
            result[idx - offset] = EOS;
            if(!strlen(result))
            {
                SendClientMessage(playerid, 0x33FF00FF, "USE: /an (texto)");
                return 1;
            }
            SendClientMessageToAll(0x33FF00FF, "|=-=-=-=-=Anuncio=-=-=-=-=|");
            format(string, sizeof(string), "%s: %s", sendername, result);
            SendClientMessageToAll(0x33FF00FF, string);
        }
        return 1;
    }
Tenta ae, se der algum erro avise :\
Reply


Messages In This Thread
[AJUDA]Anuncio - by Manoloww - 25.03.2012, 19:02
Re: [AJUDA]Anuncio - by DouglasRodrigues - 25.03.2012, 19:09
Re: [AJUDA]Anuncio - by histire - 25.03.2012, 19:11
Re: [AJUDA]Anuncio - by Manoloww - 25.03.2012, 19:13
Re: [AJUDA]Anuncio - by histire - 25.03.2012, 19:16
Re: [AJUDA]Anuncio - by DouglasRodrigues - 25.03.2012, 19:21
Re: [AJUDA]Anuncio - by .FuneraL. - 25.03.2012, 20:31
Re: [AJUDA]Anuncio - by histire - 25.03.2012, 20:34
Re: [AJUDA]Anuncio - by StrondA_ - 25.03.2012, 20:55

Forum Jump:


Users browsing this thread: 1 Guest(s)