26.08.2016, 10:25
Quote:
C:\Documents and Settings\All Users\Desktop\fsad\pawno\include\easydb.inc(1189) : error 010: invalid function or declaration Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase |
Line 1189:
Код:
format(string, sizeof (string), ""COL_WHITE"This happens, that's why we had a simple security question system for you to easily recover your password now.\nPlease answer the security question to reset your password. [You have "COL_CORAL"%i/%i tries"COL_WHITE" left]\n\n"COL_LIGHT_BLUE"%s", p_Data[playerid][E_PDATA_ATTEMPTS], g_Settings[E_SETTINGS_MAX_ANSWER_ATTEMPTS], ReturnQuestion(p_Account[playerid][E_ACCOUNT_SECURITY_QUESTION]));
Код:
Dialog:DIALOG_REGISTER(playerid, response, listitem, inputtext[]) { if (!response) { if (g_Settings[E_SETTINGS_GUEST_LOGIN]) { p_Data[playerid][E_PDATA_LOGIN_STATUS] = 2; new name[MAX_PLAYER_NAME + 6]; GetPlayerName(playerid, name, MAX_PLAYER_NAME); strins(name, "guest_", 0); if (strlen(name) + 6 > MAX_PLAYER_NAME) strdel(name, (MAX_PLAYER_NAME - (6 + 1)), (MAX_PLAYER_NAME - 1)); SetPlayerName(playerid, name); static string[150]; SendClientMessage(playerid, COLOR_GREEN, "_______________________________________________"); SendClientMessage(playerid, COLOR_GREEN, " "); format(string, sizeof (string), "You have joined as a guest! Your admin level is %i and vip level is %i.", p_Account[playerid][E_ACCOUNT_ADMIN_LEVEL], p_Account[playerid][E_ACCOUNT_VIP_LEVEL]); SendClientMessage(playerid, COLOR_GREEN, string); SendClientMessage(playerid, COLOR_GREEN, " "); SendClientMessage(playerid, COLOR_GREEN, "_______________________________________________"); ResetPlayerMoney(playerid); SetPlayerScore(playerid, 0); return 1; } else return Kick(playerid); } if (!inputtext[0] || inputtext[0] == ' ') { SendClientMessage(playerid, COLOR_TOMATO, "Error: Invalid password length, cannot be empty."); static string[500]; if (g_Settings[E_SETTINGS_GUEST_LOGIN]) { format(string, sizeof (string), ""COL_WHITE"Hello "COL_TOMATO"%s"COL_WHITE". Please insert a complicated password to register a new account or Click 'Guest' to join with a temporary account.", ReturnPlayerName(playerid)); Dialog_Show(playerid, DIALOG_REGISTER, DIALOG_STYLE_PASSWORD, "Register account...", string, "Continue", "Guest"); } else { format(string, sizeof (string), ""COL_WHITE"Hello "COL_TOMATO"%s"COL_WHITE". Please insert a complicated password to register a new account or Click 'Quit' to exit game to desktop.", ReturnPlayerName(playerid)); Dialog_Show(playerid, DIALOG_REGISTER, DIALOG_STYLE_PASSWORD, "Register account...", string, "Continue", "Quit"); } return 1; } new len = strlen(inputtext); if (len > MAX_PASSWORD_LENGTH || len < MIN_PASSWORD_LENGTH) { static string[500]; format(string, sizeof (string), "Error: Invalid password length, must be between %i - %i chars.", MIN_PASSWORD_LENGTH, MAX_PASSWORD_LENGTH); SendClientMessage(playerid, COLOR_TOMATO, string); if (g_Settings[E_SETTINGS_GUEST_LOGIN]) { format(string, sizeof (string), ""COL_WHITE"Hello "COL_TOMATO"%s"COL_WHITE". Please insert a complicated password to register a new account or Click 'Guest' to join with a temporary account.", ReturnPlayerName(playerid)); Dialog_Show(playerid, DIALOG_REGISTER, DIALOG_STYLE_PASSWORD, "Register account...", string, "Continue", "Guest"); } else { format(string, sizeof (string), ""COL_WHITE"Hello "COL_TOMATO"%s"COL_WHITE". Please insert a complicated password to register a new account or Click 'Quit' to exit game to desktop.", ReturnPlayerName(playerid)); Dialog_Show(playerid, DIALOG_REGISTER, DIALOG_STYLE_PASSWORD, "Register account...", string, "Continue", "Quit"); } return 1; } SHA256_PassHash(inputtext, PASSWORD_SALT, p_Account[playerid][E_ACCOUNT_PASSWORD], 64); new File:h = fopen(DIRECTORY "questions.ini", io_read); new line[100]; new info[15 * sizeof (line)]; new count; while (fread(h, line)) { strcat(info, line); strcat(info, "\n"); if (++count > 15) break; } fclose(h); PlayerPlaySound(playerid, 1054, 0.0, 0.0, 0.0); Dialog_Show(playerid, DIALOG_SEC_QUESTION, DIALOG_STYLE_LIST, "[1/2] Select your security question:", info, "Continue", ""); return 1; }