SA-MP Forums Archive
Little bit 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: Little bit dialog help. (/showthread.php?tid=493146)



Little bit dialog help. - tuuler - 07.02.2014

Hello, I'm making a login/register system currently.
And I'm making an password failing system, it works fine, but just one question.
Can i make it like that, if player types in wrong password into the dialog, then it wont send him into class selection? And just the camera pos will stay at the same position?
I hope you guys understand me, thanks.
(Sorry for low english)


Re: Little bit dialog help. - Smileys - 07.02.2014

pawn Код:
if( inputtext != password )
{
// do something here
}
else
{
// player has successfully logged in.
}
get the password variable somewhere out of a database or ini file.

I also suggest you encrypt them.


Re: Little bit dialog help. - MatriXgaMer - 07.02.2014

@Smileys
pawn Код:
new tmp;
tmp = dini_Int(SERVERLOCATION, "Password", inputtext); //not tested
if(udb_hash(inputtext) !=tmp)
{
      SCM(playerid, -1, "Wrong Password sir!");
      ShowPlayerDialog(playerid, blah, blah);//replace with your variables
}
else
{
    SCM(playerid, -1, "Welcome!");
}



Re: Little bit dialog help. - ca2k - 07.02.2014

udb_hash... really? https://sampforum.blast.hk/showthread.php?tid=65290