Jump to content

Popescu413

Membru
  • Posts

    10
  • Joined

  • Last visited

Posts posted by Popescu413

  1. Am si eu comanda

    CMD:setkey(playerid, params[]) {
        if(PlayerInfo[playerid][pAdmin] < 6) return 1;
        new key[64], svpass[32], string[256], id;
        if(sscanf(params, "is[64]s[32]", id, key, svpass)) return SCM(playerid, COLOR_GREY, "USAGE: {FFFFFF}/setkey <playerid/name> <key> <server password>");
        if(!IsPlayerConnected(id) || id == INVALID_PLAYER_ID) return SendClientMessage(playerid, COLOR_GREY, "Acel player nu este conectat.");
        if(PlayerInfo[id][pAdmin] == 0) return SCM(playerid, COLOR_GREY, "Acel player nu este admin!");
        if(strcmp(svpass, SERVER_PASSWORD, true) == 0) {}
        else return SCM(playerid, COLOR_WARNING, "Invalid server password!");
        if(strlen(key) < 6 || strlen(key) > 32) return SCM(playerid, COLOR_GREY, "Parola trebuie sa contina minim 6 caractere sau maxim 32!");
        
        new query[256];
        mysql_format(SQL, query, sizeof(query), "UPDATE `users` SET `Security`='%s' WHERE `ID`='%d'", MD5_Hash(key), PlayerInfo[playerid][pSQLID]);
        mysql_tquery(SQL, query, "", "");
        format(PlayerInfo[id][pSecurity], 64, MD5_Hash(key));
        
        format(string, sizeof(string), "New security password for %s: %s", GetName(id), key);
        ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX, "Security password", string, "Close", "");
        return 1;
    }

     

    si as dori sa mai fac unde gen /setkeyme parola parolaserver , pentru playerul care da comanda in chat ..., sa nu poate seta si la alt player. Ma puteti ajuta va rog frumos ?? (e pe GM burned)

     

    In caz de nu am facut bine topic il voi modifica 

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.