09.05.2010, 19:28
pawn Код:
public OnPlayerConnect(playerid)
{
new joinMsg[128], playerName[MAX_PLAYER_NAME]; GetPlayerName(playerid, playerName, sizeof playerName);
format(joinMsg, sizeof joinMsg, " >> <> %s has joined %s <> <<", playerName, GetServerHostName());
SendClientMessageToAll(colorWhite, joinMsg);
format(joinMsg, sizeof joinMsg, " >> <> Welcome %s to %s! <> <<", playerName, GetServerHostName());
SendClientMessageToAll(colorWhite, joinMsg);
new playerFile[128], registerText[128], loginText[128];
format(playerFile, sizeof playerFile, "/TSMS/%s.ini", playerName);
format(registerText, sizeof registerText, "Welcome %s to %s\nPlease register your account on this server", playerName, GetServerHostName());
format(loginText, sizeof loginText, "Welcome %s to %s\nPlease login to your account", playerName, GetServerHostName());
// if(!fexist(playerFile)) return*/ ShowPlayerDialog(playerid, 1234, DIALOG_STYLE_INPUT, "Register your Account", registerText, "Register", "Quit");
// if(fexist(playerFile)) return ShowPlayerDialog(playerid, 5678, DIALOG_STYLE_INPUT, "Login to your Account", loginText, "Login", "Quit");
ShowPlayerDialog(playerid, 1234, DIALOG_STYLE_INPUT, "Register your Account", "Welcome \nPlease register your account on this server", "Register", "Quit");
return 1;
}

