23.07.2011, 02:15
Well, i'm having a problem figuring out how to compare the text from inputtext (dialogs) to a file - It should work, but yet, it doesn't.
Any idea what's wrong here?
pawn Код:
case LOGIN_DIALOG:
{
if(response)
{
if(strlen(inputtext) <= 32)
{
if(strcmp(SInfo[playerid][Password], inputtext, true)) //This is the problem.
{
OnPlayerLogin(playerid, inputtext);
}
else return ShowPlayerDialog(playerid, LOGIN_DIALOG, DIALOG_STYLE_INPUT, "Welcome back!", "You appear to have an account on this server!\nPlease login by typing in your password below:", "Submit", "Quit");
}
else
{
ShowPlayerDialog(playerid, LOGIN_DIALOG, DIALOG_STYLE_INPUT, "Welcome back!", "You appear to have an account on this server!\nPlease login by typing in your password below:", "Submit", "Quit");
}
}
else return Kick(playerid);
}