Change Password [dialog help] - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Change Password [dialog help] (
/showthread.php?tid=429465)
Change Password [dialog help] -
zT KiNgKoNg - 09.04.2013
Hey guys i have another problem this time with apart of my script that i'm developing
When you click check it closes all dialog and just stops you can't spawn ect
"Codes are generated randomly so there is no chance of somone getting the same code"
pawn Код:
if(dialogid == DIALOG_PASSFORGOT)
{
if(response)
{
format(string, sizeof(string), "SELECT * FROM `registered` WHERE `username` = '%s' AND `securityid` = '%s'", name, inputtext);
mysql_query(string);
mysql_store_result();
if(mysql_num_rows() == 0)
{
SendClientMessage(playerid, 0xFFFFFFFF, "The security code you've entered doesn't match the one our system have given this account");
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT, "Login", "Hello. Please, enter your password for authorization:", "Login", "Forgot?");
}else{
ShowPlayerDialog(playerid, DIALOG_SECURITYID_CHANGEPASS, DIALOG_STYLE_INPUT, "Change Password", "Please enter the password you would like this account to have.", "Change", "Go back");
}
}
if(!response)
{
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT, "Login", "Hello. Please, enter your password for authorization:", "Login", "Forgot?");
}
}
Re: Change Password [dialog help] -
Arpatos - 09.04.2013
Hum i'm not sure but, u forget a "!" there, if(response) ?
Re: Change Password [dialog help] -
zT KiNgKoNg - 09.04.2013
No i didn't, i for got to add this
Order
Change pass --------------------------------------------------
User Login -> (if selected Forgot?) -> Security Check -> if right ^ else If wrong -> back to login