04.03.2013, 15:45
Hello, I want to use whirlpool but there is a issue..
Evrything works fine, expect that no matter what I input I get logged in. If my password is 123456 and I type asdsad I will get logged in.
Evrything works fine, expect that no matter what I input I get logged in. If my password is 123456 and I type asdsad I will get logged in.
pawn Код:
case DIALOG_LOGIN:
{
if ( !response ) return Kick ( playerid );
if( response )
{
//if(udb_hash(inputtext) == PlayerInfo[playerid][pPass])
new hashpass[129]; //Will create a new variable to hash his/her password
WP_Hash(hashpass,sizeof(hashpass),inputtext); //Will hash inputted password
if(!strcmp(hashpass,PlayerInfo[playerid][pPass]))
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
SetSpawnInfo(playerid, 265, 0, 1525.7687,-1667.9515,6.2188, 0, 0, 0, 0, 0, 0, 0 );
SpawnPlayer(playerid);
TogglePlayerSpectating( playerid, 0 );
SetPlayerSkin( playerid, PlayerInfo[playerid][pSkin] );
PlayerInfo[playerid][pLogs]++;
}
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;
}
}