28.06.2012, 20:04
pawn Код:
public OnPlayerConnect(playerid)
{
SendClientMessage(playerid, -1, "{FFFFFF}|______________{0DF014}Welcome to SA-MP TDM{FFFFFF}___________|");
TextDrawShowForPlayer(playerid, Textdraw0);
LoadBanStatus(playerid);
ResetSettings(playerid);
IsLogged[playerid]=0;
TogglePlayerSpectating(playerid, 1);
new file[128], string[128],name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
format(file,sizeof(file),"/mRegistration/Users/%s.txt",name);
if(!fexist(file))
{
#if REGISTER_ON_CONNECT == true
THIS IS LINE 253! ShowPlayerDialog(playerid, REG1-1, DIALOG_STYLE_MSGBOX, ""GREEN"DM World v1.0", ""GREEN"Welcome To SA-MP TDM"GREEN"", "Register", "Skip");
#endif
}
if(fexist(file))
{
format(file,sizeof(file),"/mRegistration/Settings/%s.txt",name);
INI_ParseFile(file, "PrompScV", false, true, playerid, true, false);
PlayerInfo[playerid][PrompSc] = GetPVarInt(playerid,"PrompSc");
INI_ParseFile(file, "LoadAutoLog", false, true, playerid, true, false);
PlayerInfo[playerid][AutoLogin] = GetPVarInt(playerid,"AutoLog");
if
{
format(string, sizeof string, ""WHITE"Your IP doesn't Match With Username: "RED"%s "WHITE"\nYou Can Login By Entering Your Password",name);
ShowPlayerDialog(playerid, Login, DIALOG_STYLE_INPUT, ""RED"Login Failed", string, "OK", "Cancel");
}
}
return 1;
}