Password saves "0"
#28

About the first case, in OnPlayerConnect I've got this

pawn Code:
if(fexist(UserPath(playerid)))
    {
        INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
        ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COL_WHITE"Login",""COL_WHITE"Type your password below to login.","Login","Quit");
    }
    else
    {
        ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,""COL_WHITE"Registering...",""COL_WHITE"Type your password below to register a new account.","Register","Quit");
    }
I believe it is working well.

On the second case, I think this is the problem, I think that I am checking the password wrongly, can you please check it? Here is the script:

pawn Code:
case DIALOG_LOGIN:
        {
            if ( !response ) return Kick ( playerid );
            if( response )
            {
                new buf[145];
                if(WP_Hash(buf, sizeof(buf), inputtext) == PlayerInfo[playerid][pPass])
                {
                    INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
                    GivePlayerMoney(playerid, PlayerInfo[playerid][pCash]);
                    ShowPlayerDialog(playerid, DIALOG_SUCCESS_2, DIALOG_STYLE_MSGBOX,""COL_WHITE"Success!",""COL_GREEN"You have successfully logged in!","Ok","");
                }
                else
                {
                    ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COL_WHITE"Login",""COL_RED"You have entered an incorrect password.\n"COL_WHITE"Type your password below to login.","Login","Quit");
                }
                return 1;
            }
        }
Reply


Messages In This Thread
Password saves "0" [Added the codes] - by Guitar - 07.09.2012, 11:08
Re: Password saves "0" - by doreto - 07.09.2012, 11:37
Re: Password saves "0" - by HuSs3n - 07.09.2012, 11:40
Re: Password saves "0" - by Guitar - 07.09.2012, 11:49
Re: Password saves "0" - by Guitar - 07.09.2012, 11:59
Re: Password saves "0" - by HuSs3n - 07.09.2012, 12:00
Re: Password saves "0" - by Guitar - 07.09.2012, 12:02
Re: Password saves "0" - by HuSs3n - 07.09.2012, 12:06
Re: Password saves "0" - by Guitar - 07.09.2012, 12:14
Re: Password saves "0" - by Cjgogo - 07.09.2012, 13:06
Re: Password saves "0" - by JaKe Elite - 07.09.2012, 13:10
Re: Password saves "0" - by Guitar - 07.09.2012, 20:27
Re: Password saves "0" - by RedFusion - 07.09.2012, 20:37
Re: Password saves "0" - by sniperwars - 07.09.2012, 20:37
Re: Password saves "0" - by Guitar - 08.09.2012, 06:04
Re: Password saves "0" - by Guitar - 08.09.2012, 10:15
Re: Password saves "0" - by JaKe Elite - 08.09.2012, 10:31
Re: Password saves "0" - by Guitar - 08.09.2012, 10:49
Re: Password saves "0" - by Kush - 08.09.2012, 10:54
Re: Password saves "0" - by JaKe Elite - 08.09.2012, 10:59
Re: Password saves "0" - by Guitar - 08.09.2012, 11:01
Re: Password saves "0" - by Aprezt - 08.09.2012, 11:03
Re: Password saves "0" - by JaKe Elite - 08.09.2012, 11:04
Re: Password saves "0" - by Guitar - 08.09.2012, 11:06
Re: Password saves "0" - by Kush - 08.09.2012, 11:11
Re: Password saves "0" - by Guitar - 08.09.2012, 11:14
Re: Password saves "0" - by Kush - 08.09.2012, 11:20
Re: Password saves "0" - by Guitar - 08.09.2012, 11:26
Re: Password saves "0" - by JaKe Elite - 08.09.2012, 11:31
Re: Password saves "0" - by Guitar - 08.09.2012, 11:36
Re: Password saves "0" - by Glint - 08.09.2012, 12:02

Forum Jump:


Users browsing this thread: 16 Guest(s)