31.07.2014, 19:02
Hi.I have a big problem with my system login/register and this it works on INI.
Originally login dialogs were made in public OnPlayerConnect and i moved this dialog in public OnPlayerRequestClass.Now, the problem is that the dialogs, not working correctly.When i login in server and i have a new name and name is not register, i not receive the dialog register but i receive the dialog login and this thing is not correctly.Before moved the dialogs, everything was perfect.This is the script i moved
Mention that I put the same script in public OnPlayerSpawn san public OnPlayerRequestSpawn!
Sorry for my english but i have really need to help, please!
Originally login dialogs were made in public OnPlayerConnect and i moved this dialog in public OnPlayerRequestClass.Now, the problem is that the dialogs, not working correctly.When i login in server and i have a new name and name is not register, i not receive the dialog register but i receive the dialog login and this thing is not correctly.Before moved the dialogs, everything was perfect.This is the script i moved
PHP код:
if(!fexist(UserPath(playerid)))
{
ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,""COL_LIGHTBLUE"Inregistrare...",""COL_GREEN"Salut!nScrie o parola pentru a te inregistra.","Register","Quit");
}
else if(fexist(UserPath(playerid)))
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
//GivePlayerMoney(playerid, PlayerInfo[playerid][Money]);
//SetPlayerScore(playerid, PlayerInfo[playerid][Level]);
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COL_LIGHTBLUE"Login",""COL_GREEN"Bun Venit!\n\nScrie parola pentru a te loga!","Login","Quit");
}
Sorry for my english but i have really need to help, please!