System register problem (GF) - 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: System register problem (GF) (
/showthread.php?tid=480037)
System register problem (GF) -
Addons - 08.12.2013
Hi all.
I've a big fuckin' problem.
A player makes account on my server, then he disconnect. When he try to login on my server, he receive this message: "This account already exist!"
Code:
Код:
if(dialogid == 12345)
{
if(strlen(inputtext))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
format(string, sizeof(string), "Users/%s.ini", sendername);
new File: hFile = fopen(string, io_read);
if (hFile)
{
SendClientMessage(playerid, COLOR_YELLOW, "* This name already exist!");
fclose(hFile);
return 1;
}
new tmppass[64];
strmid(tmppass, inputtext, 0, strlen(inputtext), 255);
OnPlayerRegister(playerid,tmppass);
}
else
{
new regstring[128];
new regname[64];
GetPlayerName(playerid,regname,sizeof(regname));
format(regstring,sizeof(regstring),"{FFFFFF}Welcome, {AA3333}%s \n \n{32CD32}Type a password:",regname);
ShowPlayerDialog(playerid,12345,DIALOG_STYLE_PASSWORD,"Register",regstring,"Register","Exit");
}
}
}
Pls help.
@ Sorry for my bad english, i'm from Romania.
Re: System register problem (GF) -
manoc - 08.12.2013
....
Re: System register problem (GF) -
BizzyD - 08.12.2013
Thats because he makes the account?
Do a variable to check if he is in the tutorial, and when he leaves and its set to 1, remove the account.
Re: System register problem (GF) -
Addons - 11.12.2013
No, he makes the account, then he disconnect from server. When he try to login on server receive "This nick-name already used!".