public OnPlayerRegister(playerid, password[]) { //FuncLog("OnPlayerRegister"); if(IsPlayerConnected(playerid)) { MySQLCheckConnection(); new playername[MAX_PLAYER_NAME]; new playername3[MAX_PLAYER_NAME]; new newpass[64]; GetPlayerName(playerid, playername3, sizeof(playername3)); mysql_real_escape_string(playername3, playername); mysql_real_escape_string(password, newpass); new query[128];//PASSWORD format(query, sizeof(query), "INSERT INTO `userinfo` (UserName) VALUES ('%s');", playername); mysql_query(query); new newaccountsqlid = MySQLCheckAccount(playername3); if (newaccountsqlid != 0) { format(query, sizeof(query), "INSERT INTO `uservehicles` (ID, UserName) VALUES (%d, '%s');", newaccountsqlid, playername); mysql_query(query); format(query, sizeof(query), "INSERT INTO `userstrings` (ID, UserName, Password) VALUES (%d, '%s', '%s');", newaccountsqlid, playername, newpass); mysql_query(query); format(query, sizeof(query), "INSERT INTO `userlocker` (ID, Username) VALUES (%d, '%s');", newaccountsqlid, playername); mysql_query(query); PlayerInfo[playerid][pSQLID] = newaccountsqlid; strmid(PlayerInfo[playerid][pKey], password, 0, strlen(password), 127); //SendClientMessage(playerid, COLOR_YELLOW, "Account registered, you can now login."); //ShowPlayerDialog(playerid, 115, DIALOG_STYLE_INPUT, "{00BFFF}Westcoast Roleplay", "This account is Registered!\nPlease enter your Password!", "Login", "Exit"); gPlayerAccount[playerid] = 1; OnPlayerLogin(playerid, password); } } return 1; } |
did you make a folder called bla bla registered players or something like that?
|
filterscripts register/loginsystem script2 script 3 ETC