[Ajuda] Server: Unknown Command
#1

Код:
	cmd_orgs(playerid, params[])
	{
        new org[128],org2[128],string[2048],tmp[32],giveid;
        for(new i = 1; i < MAX_ORGS; ++i)
        {
            format(org,128,"/RPG/orgs/%s.ini",OrgsNamesSmall[i]);
		    format(tmp,32,"%s",dini_Get(org, OrgsCargos[0]));

            /*if(strcmp(tmp,"Nenhum",true)==0 || strlen(tmp) < 3)
            {
		    	format(org2,128,"{C2A2DA}%s: Nenhum\n",OrgsNames[i]);
		    	continue;
			}*/

			if(strlen(tmp) < 3)
			    tmp = "Ninguйm";

			giveid = ReturnUser(tmp);
            if(IsPlayerConnected(giveid))
                format(org2,128,"{C2A2DA} %d = %s: %s - {00D900}Online\n", i, OrgsNames[i], tmp, Player[i][pName]);
		    else
		        format(org2,128,"{C2A2DA} %d = %s: %s - {AA3333}Offline\n", i, OrgsNames[i], tmp, Player[i][pName]);
		    strcat(string, org2);
		}
		#pragma unused params
		return ShowPlayerDialog(playerid, 10000, DIALOG_STYLE_MSGBOX, "Organizaзхes", string, "Fechar", "");
    }
oq ta de errado ai me ajude digito /orgs e da Server: Unknown Command pq sera ? ++ REP
Reply
#2

return 1;
Reply
#3

nгo deu certo.

ele ja retorna entao troquei o return ShowPlayerDialog para return 1 e nгo adiantou nao й outra coisa
Reply
#4

ajuda ae na moral alguem ?? ++ REP
Reply
#5

pawn Код:
cmd:orgs(playerid)
{
    new org[128],org2[128],string[2048],tmp[32],giveid;
    for(new i = 1; i < MAX_ORGS; ++i)
    {
        format(org,128,"/RPG/orgs/%s.ini",OrgsNamesSmall[i]);
        format(tmp,32,"%s",dini_Get(org, OrgsCargos[0]));
        /*if(strcmp(tmp,"Nenhum",true)==0 || strlen(tmp) < 3)
        {
            format(org2,128,"{C2A2DA}%s: Nenhum\n",OrgsNames[i]);
            continue;
        }*/

        tmp = "Ninguйm";
        giveid = ReturnUser(tmp);
        if(IsPlayerConnected(giveid)) return format(org2,128,"{C2A2DA} %d = %s: %s - {00D900}Online\n", i, OrgsNames[i], tmp, Player[i][pName]);
        format(org2,128,"{C2A2DA} %d = %s: %s - {AA3333}Offline\n", i, OrgsNames[i], tmp, Player[i][pName]);
        strcat(string, org2);
        ShowPlayerDialog(playerid, 10000, DIALOG_STYLE_MSGBOX, "Organizaзхes", string, "Fechar", "");
    }
    return 1;
}
Reply
#6

nгo deu certo se nгo for o cmd axo q eh outro cmd q ta bugando !
Reply
#7

alguem me ajuda ae pf
Reply
#8

Tenta Troca isso
pawn Код:
#define dcmd(%1,%2,%3)      if(!strcmp((%3)[1], #%1, true, (%2)) && ((((%3)[(%2) + 1] == '\0') && (dcmd_%1(playerid, ""))) || (((%3)[(%2) + 1] == ' ') && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1
Reply
#9

Nгo deu nгo alguem me ajude ja cansei de tentar !
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)