PHP код:
public OnPlayerConnect(playerid)
{
blockpm[playerid] = 0;
morar[playerid] = 0;
moradia[playerid] = 0;
convitede[playerid] = 0;
PlayerInfo[playerid][LoginsFalsos] = 0;
pAdmin[playerid] = 0;
emcasa[playerid] = 0;
ResetPlayerGrana(playerid);
new aname[MAX_PLAYER_NAME];
GetPlayerName(playerid, aname, MAX_PLAYER_NAME);
format(file, sizeof(file), PASTA_CONTAS, aname);
if(dini_Int(file, "Casa") == 1)
{
Create3DTextLabel(aname,Amarelo,dini_Int(file, "CasaX"),dini_Int(file, "CasaY"),dini_Int(file, "CasaZ"),80.0,0);
}
dini_IntSet(file, "DM", 0);
TextDrawShowForPlayer(playerid, bottomblack);
TextDrawShowForPlayer(playerid, topblack);
TextDrawShowForPlayer(playerid, Textdraw0);
TextDrawShowForPlayer(playerid, Textdraw1);
TextDrawShowForPlayer(playerid, Textdraw2);
TextDrawShowForPlayer(playerid, Textdraw3);
//settimers
SetTimerEx("semporte", 1000, 1,"e",playerid);
//variavels
CPSERVICE_actualcp[playerid] = 0;
AFK[playerid]=0;
multar[playerid]= 0;
autoescola[playerid] = 0;
nogame[playerid] = 0;
noevento[playerid] = 0;
PlayerInfo[playerid][Logged] = 0;
vip[playerid] = 0;
GPS_Spawned[playerid] = 0;
DMLiberado[playerid] = 0;
Mute[playerid] = 0;
//news
new Pname[MAX_PLAYER_NAME];
new string[256];
new sstring[256];
//============================================================================================================
dini_IntSet(file,"aAdmin",0);
if(dini_Int("nickban.ini",PlayerName(playerid)) == 1)
{
SendClientMessage(playerid, 0x11B1FFAA, "Vocк foi banido Motivo: Vocк estб banido!");
format(sstring, sizeof(sstring), "%s (%d) Foi banido |Motivo|: Conta estб banida!", aname,playerid);
SendClientMessageToAll(0x11B1FFAA, sstring);
Kick(playerid);
return 1;
}
if(dini_Int("banidos.ini",PlayerName(playerid)) == 1)
{
SendClientMessage(playerid, 0x11B1FFAA, "Vocк foi kickado |Motivo|: Conta estб banida!");
format(sstring, sizeof(sstring), "%s (%d) Foi kickado |Motivo|: Conta estб banida", aname,playerid);
SendClientMessageToAll(0x11B1FFAA, sstring);
Kick(playerid);
return 1;
}
//============================================================================================================
GetPlayerName(playerid, Pname, sizeof(Pname));
format(string, sizeof(string), "» %s (%d) entrou no servidor.", Pname,playerid);
SendClientMessageToAll(0xFFFFFFAA,string);
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xFFFFFFAA, " ");
SendClientMessage(playerid, 0xA86400AA, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
SendClientMessage(playerid, 0x0081D8AA, "» Seja bem vindo(a) ao servidor!");
SendClientMessage(playerid, 0xE9FFE8AA, "» Para ver os comandos /comandos");
SendClientMessage(playerid, 0x0081D8AA, "» Para ver as regras /regras");
SendClientMessage(playerid, 0xE9FFE8AA, "» Para ver os crйditos /creditos");
SendClientMessage(playerid, 0x0081D8AA, "» Tenha Um Bom Jogo!");
SendClientMessage(playerid, 0xA86400AA, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~");
SetSpawnInfo(playerid, 1, dini_Int(file, "Skin"), dini_Int(file, "CasaX"), dini_Int(file, "CasaY"), dini_Int(file, "CasaZ"),0, 0, 0, 0, 0, 0, 0);
return 1;
}