12.07.2013, 13:22
PHP код:
public OnPlayerDisconnect(playerid, reason)
{
new caller = Mobile[playerid];
OnPlayerSave(playerid);
if(caller != 255)
{
if(caller < 255)
{
SendClientMessage(caller, COLOR_BLUE, "A Ligacao caiu...");
CellTime[caller] = 0;
CellTime[playerid] = 0;
Mobile[caller] = 255;
}
Mobile[playerid] = 255;
CellTime[playerid] = 0;
}
BusrouteEast[playerid][0] = 0;
BusrouteWest[playerid][0] = 0;
if(PlayerInfo[playerid][pAdmin] == 1356)
{
format(gstring, sizeof(gstring), "~p~%s: ~r~OFF", PlayerName(playerid));
for(new i=0; i<MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
GameTextForPlayer(i, gstring , 1000, 1);
}
}
}
return 1;
}