Another Login Problem!
#1

Hi,

After i fixed my previous problem now i have this! Read carefully, When i have to register my password got saved for sure all fine example (mypassword123), but when i came to login and type example (123) which isn't not my password i got message "The password you entered is incorrect" BUT I am logged in and i can counitnue with gaming I'm really confused right now! All help with be appricated +REP if helped!

Код:
if( response )
	{
		new string1[30], hashpass[129];
  		WP_Hash(hashpass,sizeof(hashpass),inputtext);
	        if(!strcmp(hashpass, PlayerInfo[playerid][PASSWORD], false))
		{
			INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
			GivePlayerMoney(playerid, PlayerInfo[playerid][MONEY]);
			SetPVarInt(playerid, "gLogged", 1);
			SendClientMessage(playerid, -1, "SERVER: You have successfully logged!");
		}
  		else
		{
  		  	if(GetPVarInt(playerid, "FailedLoginAttempt") == 0)
                        {
   				SetPVarInt(playerid, "FailedLoginAttempt", 1);
   				SendClientMessage(playerid, -1, "SERVER: The password you have entered is incorrect (1/3 attempts used).");
			}
			else if(GetPVarInt(playerid, "FailedLoginAttempt") == 1)
			{
   				SetPVarInt(playerid, "FailedLoginAttempt", 2);
   				SendClientMessage(playerid, -1, "SERVER: The password you have entered is incorrect (2/3 attempts used).");
			}
			else if(GetPVarInt(playerid, "FailedLoginAttempt") == 2)
			{
   				SetPVarInt(playerid, "FailedLoginAttempt", 3);
   				SendClientMessage(playerid, -1, "SERVER: The password you have entered is incorrect (3/3 attempts used).");
			}
			else if(GetPVarInt(playerid, "FailedLoginAttempt") == 3)
			{
   				DeletePVar(playerid, "FailedLoginAttempt");
   				SendClientMessage(playerid, -1, "SERVER: You have used up all your login attempts, and hence got kicked.");
			    Kick(playerid);
			}
   			ShowPlayerDialog(playerid, LOGIN, DIALOG_STYLE_INPUT, "Login", string1, "Login", "Cancel");
   		}

	}
}
}
return 1;
}
Reply


Messages In This Thread
Another Login Problem! - by Hunud - 10.04.2017, 09:58
Re: Another Login Problem! - by Kane - 10.04.2017, 10:02
Re: Another Login Problem! - by Hunud - 10.04.2017, 10:07
Re: Another Login Problem! - by khRamin78 - 10.04.2017, 10:20
Re: Another Login Problem! - by Hunud - 10.04.2017, 10:36
Re: Another Login Problem! - by khRamin78 - 10.04.2017, 10:40
Re: Another Login Problem! - by Hunud - 10.04.2017, 10:44
Re: Another Login Problem! - by coool - 10.04.2017, 10:45
Re: Another Login Problem! - by Hunud - 10.04.2017, 10:56
Re: Another Login Problem! - by khRamin78 - 10.04.2017, 11:09

Forum Jump:


Users browsing this thread: 1 Guest(s)