14.10.2012, 13:04
Hey..
I have been testing my GM on localhost..
It can't connect,it just says connecting to 127.0.0.1:7777..
Server doesn't accepts connection.
Here is OnPlayer Connect Callback
I have been testing my GM on localhost..
It can't connect,it just says connecting to 127.0.0.1:7777..
Server doesn't accepts connection.
Here is OnPlayer Connect Callback
PHP код:
public OnPlayerConnect(playerid)
{
if(! IsPlayerNPC(playerid))
{
new string[128], Name[MAX_PLAYER_NAME];
GetPlayerName(playerid, Name, sizeof(Name));
format(string, sizeof(string), "Accounts/%s.ini", Name);
Reset(playerid);
SetPlayerColor(playerid, GREY);
TotalConnections++;
PlayersOn++;
if(PlayersOn > MaxVisitors)
{
MaxVisitors = PlayersOn;
UpdateAnalysis();
}
TextDrawShowForPlayer(playerid, Textdraw1);
if(fexist(string))
{
ShowPlayerDialog(playerid, 3894, DIALOG_STYLE_INPUT, "Authentication", "Welcome to DHN DM\n\nYou have an account, please enter your password to authenticate.", "Login", "Help");
SendClientMessage(playerid, WHITE, "This name is registered. If you're the account owner, please login with your account credentials to proceed.");
}
else
{
ShowPlayerDialog(playerid, 3895, DIALOG_STYLE_INPUT, "Registration", "Please enter your password to register your new account.", "Register", "Cancel");
SendClientMessage(playerid, WHITE, "This username is not registered. If you register, you'll automatically be logged in!");
}
}
return 1;
}