Jump to content
  • 0

Login/register dialog bug


enjatsred

Question

4 answers to this question

Recommended Posts

P?i folosesc LuxAdmin,are toate comenzile incluse,login ?i register...

public OnPlayerRequestSpawn(playerid)
{
	// Request Register
	#if USE_DIALOGS == false
	if(AccInfo[playerid][Registered] == 0 && ServerInfo[MustRegister] == 1 && (!IsPlayerNPC(playerid))){
	SendClientMessage(playerid,lightred,"SERVER: Your account isn't registered. Please Register! | /"#RegisterCommand" [Password]");
	return 0;
	}
	// Request Login
	if(ServerInfo[MustLogin] == 1 && AccInfo[playerid][Registered] == 1 && AccInfo[playerid][LoggedIn] == 0 && (!IsPlayerNPC(playerid))){
 	SendClientMessage(playerid,lightred,"SERVER: Your account is registered. Please Login! | /"#LoginCommand" [Password]");
	return 0;
	}
	#endif
	return 1;
	}
?i mai jos:
//==============================================================================
//-------------------------------------------------
// Player Spawn
//-------------------------------------------------
//==============================================================================
public OnPlayerSpawn(playerid)
{
//==============================================================================
// 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;
	}

Link to comment
Share on other sites

Incearca cu asta

public OnPlayerRequestSpawn(playerid)
{
	// Request Register
	#if USE_DIALOGS == false
	if(AccInfo[playerid][Registered] == 1 && ServerInfo[MustRegister] == 0 && (!IsPlayerNPC(playerid))){
	SendClientMessage(playerid,lightred,"SERVER: Your account isn't registered. Please Register! | /"#RegisterCommand" [Password]");
	return 0;
	}
	// Request Login
	if(ServerInfo[MustLogin] == 0 && AccInfo[playerid][Registered] == 0 && AccInfo[playerid][LoggedIn] == 0 && (!IsPlayerNPC(playerid))){
 	SendClientMessage(playerid,lightred,"SERVER: Your account is registered. Please Login! | /"#LoginCommand" [Password]");
	return 0;
	}
	#endif
	return 1;
	}
//==============================================================================
//-------------------------------------------------
// Player Spawn
//-------------------------------------------------
//==============================================================================
public OnPlayerSpawn(playerid)
{
//==============================================================================
// Request Register
//==============================================================================
	if(AccInfo[playerid][Registered] == 0 && ServerInfo[MustRegister] == 0)
	{
		#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;
	}

Cumpar sistem de garaje , /pm

logo.png

Proprietar Xerom Zone

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.