[Ajuda] Pq n ta indo radio familia (sobrenome)
#1

Galera da um help aн to tentando fazer um comando que quando o cara desse /fa Oi, aparece-se pra todo mundo que tem sobrenome igual ao dele, tipo meu nome й Antonio_Nunes, ai qnd eu manda-se /fa oi, todos com sobrenome Nunes vi-se o Oi, oq eu to fazendo de errado ta dando esse erro aqui \/


if(LastName == LastName) erro aqui

error 033: array must be indexed (variable "LastName")


codigo:
pawn Код:
if(strcmp(cmd, "/fa", true) == 0)
    {
    new FullName[MAX_PLAYER_NAME], FirstName[MAX_PLAYER_NAME], LastName[MAX_PLAYER_NAME];
    GetPlayerName(playerid, FullName, sizeof(FullName));
    strmid(FirstName, FullName, 0, strfind(FullName, "_"));
    strmid(LastName, FullName, strfind(FullName, "_")+1, strlen(FullName));
   
        new offset = idx;
        new result[64];
        result[idx - offset] = EOS;
        if(!strlen(result))
        {
            SendClientMessage(playerid, COLOR_R, "USE: (/fa) [familia chat]");
            return 1;
        }
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            //if(LastName(i) == LastName(i))
            //{
            //  format(string, sizeof(string), "** Familia %s: %s. )) **", sendername, result);
            //  SendFamilyMessage(LastName, COLOR_BLUE, string);
            //}
           
            if(LastName == LastName)
            {
                format(string, sizeof(string), "** Familia %s: %s. )) **", sendername, result);
                SendClientMessage(playerid, COLOR_BLUE, string);
            }
        }
        format(string, sizeof(string), "%s (rбdio): %s", sendername, result);
        ProxDetector(20.0, playerid, string, COLOR_GREY,COLOR_GREY,COLOR_GREY,COLOR_GREY,COLOR_GREY);
        return 1;
    }
Reply


Messages In This Thread
Pq n ta indo radio familia (sobrenome) - by gmstrikker - 08.04.2014, 17:19
Re: Pq n ta indo radio familia (sobrenome) - by smiir - 08.04.2014, 17:24
Re: Pq n ta indo radio familia (sobrenome) - by gmstrikker - 08.04.2014, 19:05
Re: Pq n ta indo radio familia (sobrenome) - by gmstrikker - 09.04.2014, 02:32
Re: Pq n ta indo radio familia (sobrenome) - by gmstrikker - 09.04.2014, 15:10
Re: Pq n ta indo radio familia (sobrenome) - by GWMPT - 09.04.2014, 15:31
Re: Pq n ta indo radio familia (sobrenome) - by gmstrikker - 09.04.2014, 21:18
Re: Pq n ta indo radio familia (sobrenome) - by GWMPT - 10.04.2014, 07:53
Re: Pq n ta indo radio familia (sobrenome) - by gmstrikker - 10.04.2014, 17:53

Forum Jump:


Users browsing this thread: 1 Guest(s)