Jump to content

GigiGrasu

Member
  • Posts

    10
  • Joined

  • Last visited

About GigiGrasu

  • Birthday April 18

Profile Information

  • Gender
    Male

Previous Fields

  • Real name
    Marius
  • RPG Nickname
    ..Mariusik..

Contact Methods

  • Steam ID
    mariuik1800

Recent Profile Visitors

287 profile views

GigiGrasu's Achievements

Newbie

Newbie (1/14)

4

Reputation

  1. Nu radeti de mine.. stiu ca poate e cancer... am incercat si eu
  2. mooor, reclama subitla =]]] GG BOSS
  3. Asa am folosit cand am avut server, acum un an mai exact. Si nu au fost probleme, a mers bine
  4. Da.. scuze. Nu am fost atent.
  5. Welcome! Te asteptam pe: mix.b-zone.ro rpg1.b-zone.ro rpg2.b-zone.ro rpg3.b-zone.ro rpg4.b-zone.ro
  6. @Adi007 poti raspunde la PM, este important.

  7. Astazi m-am decis sa va arat cum se face un sistem de pin. Acest tutorial contine toate etapele si comenzile necesare sistemului. Nu ofer suport sa le puneti la voi in script, sper sa va fie de folos acest tutorial. 1.Adaugam la enum pInfo pUnlocked, pPin[5] 2. la OnPlayerConnect si OnPlayerDisconnect adaugam PlayerInfo[playerid][pUnlocked] = 0; 3. Acum adaugam un noi callback public CheckAccount(playerid); public CheckAccount(playerid) { new i; if(PlayerInfo[playerid][pUnlocked] == 0 && (strlen(PlayerInfo[playerid][pPin]) > 0)) { i = 0; } else i = 1; return i; } 4. Facem Comenzile: CMD:pin(playerid, params[]) { if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to login first."); new pin[128]; if(PlayerInfo[playerid][pUnlocked] != 0) return SCM(playerid, COLOR_LIGHTRED, "You already unlocked your account."); if(sscanf(params, "s[128]", pin)) return SCM(playerid, COLOR_SYN, "Syntax: /unlockacc <4-digit-code>"); if(strlen(pin) != 4) return SCM(playerid, COLOR_SYN, "Syntax: /unlockacc <4-digit-code>"); if(!IsNumeric(pin)) return SCM(playerid, COLOR_SYN, "Syntax: /unlockacc <4-digit-code>"); if(!strcmp(pin, PlayerInfo[playerid][pPin], true)) { PlayerInfo[playerid][pUnlocked] = 1; SCM(playerid, COLOR_LIGHTBLUE, "Contul tau a fost deblocat cu succes!"); } else { SCM(playerid, COLOR_LIGHTRED, "Ai introdus un PIN gresit!"); } return 1; } CMD:changepin(playerid, params[]) { if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to login first."); new pin[128],pin2[128], string[128]; if(strlen(PlayerInfo[playerid][pPin]) == 0) return SCM(playerid, COLOR_LIGHTRED, "You don't have a pin code. Type [/addpin] to add one."); if(sscanf(params, "s[128]s[128]", pin, pin2)) return SCM(playerid, COLOR_SYN, "Syntax: /changepin <current-pin> <4-digit-new-pin>"); if(!IsNumeric(pin)) return SCM(playerid, COLOR_SYN, "Syntax: /changepin <current-pin> <4-digit-new-pin>"); if(strlen(pin) != 4) return SCM(playerid, COLOR_SYN, "Syntax: /changepin <current-pin> <4-digit-new-pin>"); if(!IsNumeric(pin2)) return SCM(playerid, COLOR_SYN, "Syntax: /changepin <current-pin> <4-digit-new-pin>"); if(strlen(pin2) != 4) return SCM(playerid, COLOR_SYN, "Syntax: /changepin <current-pin> <4-digit-new-pin>"); if(strcmp(pin, PlayerInfo[playerid][pPin], true)) return SCM(playerid, COLOR_LIGHTRED, "You entered a wrong pin."); string[0] = (EOS); mysql_format(SQL, string, sizeof(string), "UPDATE `users` SET `Pin`='%s' WHERE `id`='%d'", pin2, PlayerInfo[playerid][pSQLID]); mysql_query(SQL, string); format(PlayerInfo[playerid][pPin], 5, "%s", pin2); format(string, sizeof(string), "Your new security pin code is %s. Don't forget it!", pin2); SCM(playerid, COLOR_LIGHTBLUE, string); return 1; } CMD:addpin(playerid, params[]) { if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to login first."); new pin[128], string[128]; if(strlen(PlayerInfo[playerid][pPin]) > 0) return SCM(playerid, COLOR_LIGHTRED, "You already have a pin code."); if(sscanf(params, "s[128]", pin)) return SCM(playerid, COLOR_SYN, "Syntax: /addpin <4-digit-code>"); if(!IsNumeric(pin)) return SCM(playerid, COLOR_SYN, "Syntax: /addpin <4-digit-code>"); if(strlen(pin) != 4) return SCM(playerid, COLOR_SYN, "Syntax: /addpin <4-digit-code>"); string[0] = (EOS); mysql_format(SQL, string, sizeof(string), "UPDATE `users` SET `Pin`='%s' WHERE `id`='%d'", pin, PlayerInfo[playerid][pSQLID]); mysql_query(SQL, string); format(PlayerInfo[playerid][pPin], 5, "%s", pin); format(string, sizeof(string), "Your new security pin code is %s. Don't forget it!", pin); SCM(playerid, COLOR_LIGHTBLUE, string); return 1; } 5. La OnPlayerConnect mai adaugam format(PlayerInfo[playerid][pPin], 5, "");
  8. Cat costa o casa de donator?

    1. Show previous comments  2 more
    2. eB Waldo

      eB Waldo

      Bobo se ocupa cu acele case, nu Kelton. Da-i un pm pe forum la Bobo.

    3. Calin Superstar

      Calin Superstar

      Bobo e real-estate agent.

    4. Kelton

      Kelton

      Adevărat. Bobo se ocupă cu vânzări de case.

×
×
  • 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.