Dini not working. - 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: Dini not working. (
/showthread.php?tid=404509)
Dini not working. -
Gangster-rocks - 03.01.2013
pawn Код:
if(dialogid == dregister)
{
if(!response) return Kick(playerid);
if(response)
{
if(!strlen(inputtext))
{
ShowPlayerDialog(playerid,dregister,DIALOG_STYLE_INPUT,"Register","Welcome! This account is not registered.\nEnter your own password to create a new account.\nPlease enter the password!","Register","Quit");
return 1;
}
if(!dini_Exists(Path(playerid)))
{
new password[129];
dini_Create(Path(playerid));
WP_Hash(password,sizeof(password),inputtext);
dini_Set(Path(playerid),"Password",password);
ShowPlayerDialog(playerid,dlogin,DIALOG_STYLE_PASSWORD,"Login","Welcome back. This account is registered. \nInsert your password to login to your account.","Login","Quit");
}
return 1;
}
}
Its not writing the password or showing the login dialog
Re: Dini not working. -
Affan - 03.01.2013
Edit : Sorry I didn't see. please delete this post.
Re: Dini not working. -
Gangster-rocks - 03.01.2013
OMG That's Y-INI i said Dini.
Re: Dini not working. -
Gangster-rocks - 03.01.2013
Bumb!
Re: Dini not working. -
Gangster-rocks - 03.01.2013
Can any one help me??
Re: Dini not working. -
papedo - 03.01.2013
use print( ); for debugging.. and you will see where it stops..
example:
pawn Код:
if(dialogid == dregister)
{
print("Code pos #1");
if(!response) return Kick(playerid);
print("Code pos #2");
if(response)
{
print("Code pos #3");
if(!strlen(inputtext))
{
print("Code pos #4");
ShowPlayerDialog(playerid,dregister,DIALOG_STYLE_INPUT,"Register","Welcome! This account is not registered.\nEnter your own password to create a new account.\nPlease enter the password!","Register","Quit");
return 1;
}
print("Code pos #5");
if(!dini_Exists(Path(playerid)))
{
print("Code pos #6");
new password[129];
dini_Create(Path(playerid));
WP_Hash(password,sizeof(password),inputtext);
dini_Set(Path(playerid),"Password",password);
ShowPlayerDialog(playerid,dlogin,DIALOG_STYLE_PASSWORD,"Login","Welcome back. This account is registered. \nInsert your password to login to your account.","Login","Quit");
}
print("Code pos #7");
return 1;
}
}
and watch server log
Re: Dini not working. -
Gangster-rocks - 03.01.2013
I used it and there is no problem at all, But its still not working.
Re: Dini not working. -
Gangster-rocks - 03.01.2013
ANY ONE?
Re: Dini not working. -
Gangster-rocks - 04.01.2013
Solvied