PHP код:
public OnPlayerSpawn(playerid)
{
if(IsBotServer[playerid])
{
switch(random(7))
{
case 0: SetPlayerPos(playerid, 961.9239,-7.8796,1001.1484);
case 1: SetPlayerPos(playerid, 957.6115,-8.0866,1001.1484);
case 2: SetPlayerPos(playerid, 957.2470,-5.2198,1001.1484);
case 3: SetPlayerPos(playerid, 958.5219,-10.3474,1001.1484);
case 4: SetPlayerPos(playerid, 962.0108,-7.6954,1001.1484);
case 5: SetPlayerPos(playerid, 961.9239,-7.8796,1001.1484);
case 6: SetPlayerPos(playerid, 959.5529,-5.2575,1001.1484);
}
SetPlayerInterior(playerid, 2);
SetPlayerVirtualWorld(playerid, playerid+1);
return 1;
}
if(GetPVarInt(playerid,"request_use")) return 1;
if(GetPVarInt(playerid,"pteam1")) DeletePVar(playerid,"pteam1");
GetPlayerPos(playerid,PlayerPos[playerid][0],PlayerPos[playerid][1],PlayerPos[playerid][2]);
PosTime[playerid] += 3 + floatround(GetPlayerPing(playerid)/100);
GetPlayerPos(playerid,PVHFL[playerid][0],PVHFL[playerid][1],PVHFL[playerid][2]);
AC_Healthtime[playerid] = 3+floatround(GetPlayerPing(playerid)/100);
if(MinerDraw[playerid] != PlayerText:-1)
{
PlayerTextDrawHide(playerid,MinerDraw[playerid]);
}
if(ZoneMafiaStatus && ZoneMafiaWarslot != -1)
{
if(p_info[playerid][tMember] == ZoneMafiaNapad || p_info[playerid][tMember] == GangZoneMafiaFraction[ZoneMafiaWarslot])
{
if(!GetPVarInt(playerid,"mpokaz"))
{
TextDrawShowForPlayer(playerid,Bizwar2[3]);
TextDrawShowForPlayer(playerid,Bizwar2[0]);
TextDrawShowForPlayer(playerid,Bizwar2[1]);
TextDrawShowForPlayer(playerid,Bizwar2[2]);
GangZoneFlashForPlayer(playerid,GangZoneMafiaPosID[ZoneMafiaWarslot],GetMafiaColor(ZoneMafiaNapad));
SetPVarInt(playerid,"mpokaz",true);
}
}
}
DeletePVar(playerid,"K_Times");
SetPVarInt(playerid,"PreloadAllAnims",4);
PlayerWeaponTime[playerid]=12+floatround(GetPlayerPing(playerid)/100);
AC_NoDeath[playerid] = false;
PlayerHP[playerid] = 100.0;
UpdatePlayerShield(playerid, 0.0);
UsingShield[playerid] = false;
p_info[playerid][pShield] = 0.0;
if(GetPVarInt(playerid,"editadvert"))
{
gAdvert[GetPVarInt(playerid,"editadvert")-1][adCheking]=false;
}
if(IsPlayerAuthorized(playerid) == PLAYER_OFFLINE)
{
SendErr(playerid, "Вам нужно авторизироватся");
return 0;
}
if(IsPlayerAuthorized(playerid) == PLAYER_ONLINE)
{
SetPVarInt(playerid,"check_teleport", 4);
if(p_info[playerid][tMember])
{
SetPlayerSkin(playerid,(StartWork(playerid) && !GetPVarInt(playerid,"StartWork")) ? (p_info[playerid][pChar]) : (p_info[playerid][pModel]));
}
else if(p_info[playerid][tMember] <= 0)
{
SetPlayerSkin(playerid, p_info[playerid][pChar]);
}
AC_SetPlayerHealth(playerid, 100.0);
SetPlayerSpawn(playerid);
DP_SetPlayerFightingStyle(playerid);
for(new index = 0; index < MAX_PLAYER_ATTACHED_OBJECTS; index++)
{
if(IsPlayerAttachedObjectSlotUsed(playerid, index))
{
RemovePlayerAttachedObject(playerid,index);
}
if(!GP_AO[playerid][index][g_modelid]) continue;
SetPlayerAttachedObject(playerid,index,GP_AO[playerid][index][g_modelid],GP_AO[playerid][index][g_boneid],
GP_AO[playerid][index][g_fOffsetX],GP_AO[playerid][index][g_fOffsetY],GP_AO[playerid][index][g_fOffsetZ],
GP_AO[playerid][index][g_fRotX],GP_AO[playerid][index][g_fRotY],GP_AO[playerid][index][g_fRotZ],
0.0,0.0,0.0);
}
//if(LoveGive[playerid] > 0) UpdateHeart(playerid);
}
AC_plsp[playerid]=true;
return 1;
}