15.03.2013, 17:38
This is something i've been posting over and over for the last week, and I haven't gotten ONE answer, i don't know if it's too hard or i'm not explaining it enough.
I have LuxAdmin as an admin system. If i put the below code into OnPlayerSpawn, then it will work good. But, if i put it in to OnPlayerConnect, it does not work, the dialog appears, but when you type into the dialog and press enter, the dialog closes and nothing happens (No logging in, registering) I don't know what the problem is.
I have LuxAdmin as an admin system. If i put the below code into OnPlayerSpawn, then it will work good. But, if i put it in to OnPlayerConnect, it does not work, the dialog appears, but when you type into the dialog and press enter, the dialog closes and nothing happens (No logging in, registering) I don't know what the problem is.
pawn Код:
//==============================================================================
// Request Register
//==============================================================================
if(AccInfo[playerid][Registered] == 0 && ServerInfo[MustRegister] == 1)
{
#if USE_DIALOGS == true
new rstring[256];
format(rstring,256,"Welcome to the '%s'\n\nAccount '%s' is not registred!\n\nEnter the password to Register your Account:",GetServerHostName(),pName(playerid));
ShowPlayerDialog(playerid,DIALOGID+66,DIALOG_STYLE_INPUT,"Register Account",rstring,"Register","Quit");
#endif
return 1;
}
//==============================================================================
// Request Login
//==============================================================================
if(ServerInfo[MustLogin] == 1 && AccInfo[playerid][Registered] == 1 && AccInfo[playerid][LoggedIn] == 0)
{
#if USE_DIALOGS == true
new lstring[256];
format(lstring,green,"That account '%s 'is Registered!\n\n Login to access your Account:",pName(playerid));
ShowPlayerDialog(playerid,DIALOGID+67,DIALOG_STYLE_INPUT, "Login Account",lstring,"Login","Quit");
#endif
return 1;
}