[Ajuda] Comandos /revistar bugado..
#1

PHP код:
if (strcmp(cmd, "/revistar", true) == 0) {
    
format(file, sizeof(file), PASTA_CONTAS, GetPlayerNameEx(playerid));
    if(
dini_Int(file, "Profissao") != Policial_C || dini_Int(file, "Profissao") != Policial_F || dini_Int(file, "Profissao") != Delegado || dini_Int(file, "Profissao") != Bope || dini_Int(file, "Profissao") != Swat || dini_Int(file, "Profissao") != Narcoticos || dini_Int(file, "Profissao") != Policial_M || dini_Int(file, "Profissao") != FBI || dini_Int(file, "Profissao") != Interpol || dini_Int(file, "Profissao") != LSPD)
        return 
SendClientMessage(playerid, -1, "Vocк nгo й policial!");
    new 
plid;
    if (
sscanf(cmdtext, "u", plid))
        return 
SendClientMessage(playerid, COLOR_GREEN, "Use /revistar [id]");
    if (
IsPlayerConnected(plid)) {
        if (
GetDistanceBetweenPlayers(plid, playerid) < 21) {
            
format(file, sizeof(file), PASTA_CONTAS, GetPlayerNameEx(plid));
            
SendClientMessage(playerid, verdel, "~~~~~~~~~~~~~~ REVISTANDO ~~~~~~~~~~~~~~");
            
format(string, sizeof(string), "- Maconha: %d", dini_Int(file, "Maconha"));
            
SendClientMessage(playerid, 0xFFFFFFAA, string);
            
format(string, sizeof(string), "- Crack: %d", dini_Int(file, "Crack"));
            
SendClientMessage(playerid, 0xFFFFFFAA, string);
            
format(string, sizeof(string), "- Cocaina: %d", dini_Int(file, "Cocaina"));
            
SendClientMessage(playerid, 0xFFFFFFAA, string);
            
SendClientMessage(playerid, Vermelho, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
            
format(string, sizeof(string), "- Maconha no sangue: %d", dini_Int(file, "tmaconha"));
            
SendClientMessage(playerid, 0xFFFFFFAA, string);
            
format(string, sizeof(string), "- Crack no sangue: %d", dini_Int(file, "tcrack"));
            
SendClientMessage(playerid, 0xFFFFFFAA, string);
            
format(string, sizeof(string), "- Cocaнna no sangue: %d", dini_Int(file, "tcocaina"));
            
SendClientMessage(playerid, 0xFFFFFFAA, string);
            
SendClientMessage(playerid, verdel, "~~~~~~~~~~~~~~ REVISTANDO ~~~~~~~~~~~~~~");
            
format(string, sizeof(string), "Vocк estб revistando o(a) jogador(a) %s ", GetPlayerNameEx(plid));
            
SendClientMessage(playerid, COLOR_GREEN, string);
        } else {
            
SendClientMessage(playerid, Vermelho, "Chega mais perto para revistar!");
        }
    } else {
        
SendClientMessage(playerid, Vermelho, "Valor invбlido, tente novamente!");
    }
    return 
1;
} 
De qualquer modo que eu do /revistar apareзe : Voce nao e policial .

Ajuda aeh
Reply
#2

pawn Код:
if (strcmp(cmd, "/revistar", true) == 0) {
    format(file, sizeof(file), PASTA_CONTAS, GetPlayerNameEx(playerid));
    if(dini_Int(file, "Profissao") != Policial_C && dini_Int(file, "Profissao") != Policial_F && dini_Int(file, "Profissao") != Delegado && dini_Int(file, "Profissao") != Bope && dini_Int(file, "Profissao") != Swat && dini_Int(file, "Profissao") != Narcoticos && dini_Int(file, "Profissao") != Policial_M && dini_Int(file, "Profissao") != FBI && dini_Int(file, "Profissao") != Interpol && dini_Int(file, "Profissao") != LSPD)
        return SendClientMessage(playerid, -1, "Vocк nгo й policial!");
    new plid;
    if (sscanf(cmdtext, "u", plid))
        return SendClientMessage(playerid, COLOR_GREEN, "Use /revistar [id]");

    if (IsPlayerConnected(plid)) {
        if (GetDistanceBetweenPlayers(plid, playerid) < 21) {
            format(file, sizeof(file), PASTA_CONTAS, GetPlayerNameEx(plid));
            SendClientMessage(playerid, verdel, "~~~~~~~~~~~~~~ REVISTANDO ~~~~~~~~~~~~~~");
            format(string, sizeof(string), "- Maconha: %d", dini_Int(file, "Maconha"));
            SendClientMessage(playerid, 0xFFFFFFAA, string);
            format(string, sizeof(string), "- Crack: %d", dini_Int(file, "Crack"));
            SendClientMessage(playerid, 0xFFFFFFAA, string);
            format(string, sizeof(string), "- Cocaina: %d", dini_Int(file, "Cocaina"));
            SendClientMessage(playerid, 0xFFFFFFAA, string);
            SendClientMessage(playerid, Vermelho, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
            format(string, sizeof(string), "- Maconha no sangue: %d", dini_Int(file, "tmaconha"));
            SendClientMessage(playerid, 0xFFFFFFAA, string);
            format(string, sizeof(string), "- Crack no sangue: %d", dini_Int(file, "tcrack"));
            SendClientMessage(playerid, 0xFFFFFFAA, string);
            format(string, sizeof(string), "- Cocaнna no sangue: %d", dini_Int(file, "tcocaina"));
            SendClientMessage(playerid, 0xFFFFFFAA, string);
            SendClientMessage(playerid, verdel, "~~~~~~~~~~~~~~ REVISTANDO ~~~~~~~~~~~~~~");
            format(string, sizeof(string), "Vocк estб revistando o(a) jogador(a) %s ", GetPlayerNameEx(plid));
            SendClientMessage(playerid, COLOR_GREEN, string);
        } else {
            SendClientMessage(playerid, Vermelho, "Chega mais perto para revistar!");
        }
    } else {
        SendClientMessage(playerid, Vermelho, "Valor invбlido, tente novamente!");
    }
    return 1;
}
Reply
#3

Continua do mesmo geito ... VOCE NAO E POLICIAL . Eh comando nao funciona com nenhuma profissao '
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)