PDA

View Full Version : System register problem (GF)


Addons
08/12/2013, 04:52 PM
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_PASSW ORD,"Register",regstring,"Register","Exit");
}
}
}


Pls help.

@ Sorry for my bad english, i'm from Romania.

manoc
08/12/2013, 07:17 PM
....

BizzyD
08/12/2013, 07:48 PM
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.

Addons
11/12/2013, 08:45 AM
No, he makes the account, then he disconnect from server. When he try to login on server receive "This nick-name already used!".