01.04.2017, 15:36
This are.
Код:
public SetPlayerSpawn(playerid) { if(IsPlayerConnected(playerid)) { InHouse[playerid] = -1; InBussines[playerid] = -1; InHQ[playerid] = -1; if(MP3ON[playerid] == 0) StopAudioStreamForPlayer(playerid); StopAudioStreamForPlayer(playerid); SetPlayerVirtualWorld(playerid,0); SetPlayerSkin(playerid, PlayerInfo[playerid][pModel]); if(PlayerInfo[playerid][pTut] == 0) { gOoc[playerid] = 1; gNews[playerid] = 1; gFam[playerid] = 1; TogglePlayerControllable(playerid, 0); RegistrationStep[playerid] = 1; new sendername[30],stringy[128]; GetPlayerName(playerid, sendername, sizeof(sendername)); SendClientMessage(playerid, COLOR_TEAL, "----------------------------------------------------------------------------"); format(stringy,sizeof(stringy),"Welcome to RPG Live2Play, %s.", sendername); SendClientMessage(playerid, COLOR_YELLOW, stringy); SetPlayerInterior(playerid,0); SetPlayerVirtualWorld(playerid, 0); SetPlayerPosEx(playerid, 1742.9814,-1863.0938,16.2048); InterpolateCameraPos(playerid, 1804.1313,-1732.0179,21.7294, 1037.3715,-1732.7358,25.2859, 30000, CAMERA_MOVE); InterpolateCameraLookAt(playerid,1441.6654,-1732.0317,18.0373,1037.3715,-1732.7358,25.2859, 30000, CAMERA_MOVE); ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_MSGBOX, "Language", "Alege limba in care vrei sa fie afisate mesajele de pe server.\nChoose the language that you speak.", "Romana", "English"); return 1; } new rand, house = PlayerInfo[playerid][pPhousekey]; if(PlayerInfo[playerid][pPaintBallG] > 0) { SetPlayerVirtualWorld(playerid, 69); if(T_SAU_CT[playerid] == 2) { SetPlayerSkin(playerid, 285); GivePlayerWeaponEx(playerid, 24, 999); GivePlayerWeaponEx(playerid, 27, 999); GivePlayerWeaponEx(playerid, 31, 999); GivePlayerWeaponEx(playerid, 29, 999); SetPlayerPosEx(playerid, pozitie_tero[random(17)][0], pozitie_tero[random(17)][1], pozitie_tero[random(17)][2]); } if(T_SAU_CT[playerid] == 1) { SetPlayerSkin(playerid, 1); GivePlayerWeaponEx(playerid, 24, 999); GivePlayerWeaponEx(playerid, 25, 999); GivePlayerWeaponEx(playerid, 30, 999); GivePlayerWeaponEx(playerid, 28, 999); SetPlayerPosEx(playerid, pozitie_ctero[random(17)][0], pozitie_ctero[random(17)][1], pozitie_ctero[random(17)][2]); } if(incamerapaintball[playerid] > 1) { incamerapaintball[playerid] = 1; TogglePlayerControllable(playerid, 0); } if(paint_incepe < 0 && paint_jucatori > 1) { PlayerTextDrawHide(playerid, PaintTD[1]); PlayerTextDrawSetString(playerid, PaintTD[3], "OMOARA_JUCATORII_DIN_ECHIPA_ADVERSA"); PlayerTextDrawShow(playerid, PaintTD[0]); PlayerTextDrawShow(playerid, PaintTD[8]); PlayerTextDrawShow(playerid, PaintTD[2]); PlayerTextDrawShow(playerid, PaintTD[3]); AscundeTD[playerid] = 8; } return 1; } if(PlayerInfo[playerid][pPaintBallG] >= 1) { curatj[playerid] = 1; if(PlayerInfo[playerid][pPaintBallG] == 2 && paintt[PlayerInfo[playerid][pPaintBallG]] > 0) { SetPlayerArmourEx(playerid, 100.0); } if(PlayerInfo[playerid][pPaintBallG] == 1 || PlayerInfo[playerid][pPaintBallG] == 2) { if(paintg[PlayerInfo[playerid][pPaintBallG]] == 1 && paintt[PlayerInfo[playerid][pPaintBallG]] > 0) { GivePlayerWeaponEx(playerid, 24, 1000); GivePlayerWeaponEx(playerid, 31, 1000); GivePlayerWeaponEx(playerid, 16, 1); GivePlayerWeaponEx(playerid, 41, 1000); } else if(paintg[PlayerInfo[playerid][pPaintBallG]] == 2 && paintt[PlayerInfo[playerid][pPaintBallG]] > 0) { GivePlayerWeaponEx(playerid, 5, 1); } else if(paintg[PlayerInfo[playerid][pPaintBallG]] == 3 && paintt[PlayerInfo[playerid][pPaintBallG]] > 0) { GivePlayerWeaponEx(playerid, 9, 1); } } else if(PlayerInfo[playerid][pPaintBallG] == 3 && paintt[PlayerInfo[playerid][pPaintBallG]] > 0) { if(PlayerInfo[playerid][pPaintBallKills] >= 0 && PlayerInfo[playerid][pPaintBallKills] <= 1) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 24, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 2 && PlayerInfo[playerid][pPaintBallKills] <= 3) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 29, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 4 && PlayerInfo[playerid][pPaintBallKills] <= 5) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 28, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 6 && PlayerInfo[playerid][pPaintBallKills] <= 7) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 33, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 8 && PlayerInfo[playerid][pPaintBallKills] <= 9) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 32, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 10 && PlayerInfo[playerid][pPaintBallKills] <= 11) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 25, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 12 && PlayerInfo[playerid][pPaintBallKills] <= 13) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 26, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 14 && PlayerInfo[playerid][pPaintBallKills] <= 15) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 34, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 16 && PlayerInfo[playerid][pPaintBallKills] <= 17) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 27, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 18 && PlayerInfo[playerid][pPaintBallKills] <= 19) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 31, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 20 && PlayerInfo[playerid][pPaintBallKills] <= 21) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 30, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 22 && PlayerInfo[playerid][pPaintBallKills] <= 23) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 23, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 24 && PlayerInfo[playerid][pPaintBallKills] <= 25) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 22, 1000); } else if(PlayerInfo[playerid][pPaintBallKills] >= 26 && PlayerInfo[playerid][pPaintBallKills] <= 27) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 9, 1); } else if(PlayerInfo[playerid][pPaintBallKills] >= 28) { ResetPlayerWeaponsEx(playerid); ResetPlayerWeapons(playerid); GivePlayerWeaponEx(playerid, 4, 1); } } else if(PlayerInfo[playerid][pPaintBallG] == 4 && paintt[PlayerInfo[playerid][pPaintBallG]] > 0) { GivePlayerWeaponEx(playerid, 24, 1000); } if(paintm[PlayerInfo[playerid][pPaintBallG]] == 1) { rand = random(sizeof(gRandomSpawnRC)); SetPlayerPosEx(playerid,gRandomSpawnRC[rand][0],gRandomSpawnRC[rand][1],gRandomSpawnRC[rand][2]); SetPlayerSkin(playerid, 250); SetPlayerInterior(playerid, 10); if(PlayerInfo[playerid][pPaintBallG] == 1) { SetPlayerVirtualWorld(playerid,125); } else if(PlayerInfo[playerid][pPaintBallG] == 2) { SetPlayerVirtualWorld(playerid,126); } else if(PlayerInfo[playerid][pPaintBallG] == 3) { SetPlayerVirtualWorld(playerid,127); } else if(PlayerInfo[playerid][pPaintBallG] == 4) { SetPlayerVirtualWorld(playerid,128); } SetTimerEx("UnFreezeStation", 100, false, "i", playerid); } else if(paintm[PlayerInfo[playerid][pPaintBallG]] == 2) { rand = random(sizeof(gRandomSpawnTennis)); SetPlayerPosEx(playerid,gRandomSpawnTennis[rand][0],gRandomSpawnTennis[rand][1],gRandomSpawnTennis[rand][2]); SetPlayerSkin(playerid, 96); SetPlayerWorldBounds(playerid, -2712.4683, -2792.2351,-229.3094, -274.6794); SetPlayerInterior(playerid, 0); if(PlayerInfo[playerid][pPaintBallG] == 1) { SetPlayerVirtualWorld(playerid,125); } else if(PlayerInfo[playerid][pPaintBallG] == 2) { SetPlayerVirtualWorld(playerid,126); } else if(PlayerInfo[playerid][pPaintBallG] == 3) { SetPlayerVirtualWorld(playerid,127); } else if(PlayerInfo[playerid][pPaintBallG] == 4) { SetPlayerVirtualWorld(playerid,128); } SetTimerEx("UnFreezeStation", 100, false, "i", playerid); } else if(paintm[PlayerInfo[playerid][pPaintBallG]] == 3) { rand = random(sizeof(gRandomSpawnFarm)); SetPlayerPosEx(playerid,gRandomSpawnFarm[rand][0],gRandomSpawnFarm[rand][1],gRandomSpawnFarm[rand][2]); SetPlayerSkin(playerid, 158); SetPlayerWorldBounds(playerid, 135.3258, -287.9915, 57.6137 ,-74.2723); SetPlayerInterior(playerid, 0); if(PlayerInfo[playerid][pPaintBallG] == 1) { SetPlayerVirtualWorld(playerid,125); } else if(PlayerInfo[playerid][pPaintBallG] == 2) { SetPlayerVirtualWorld(playerid,126); } else if(PlayerInfo[playerid][pPaintBallG] == 3) { SetPlayerVirtualWorld(playerid,127); } else if(PlayerInfo[playerid][pPaintBallG] == 4) { SetPlayerVirtualWorld(playerid,128); } SetTimerEx("UnFreezeStation", 100, false, "i", playerid); } else if(paintm[PlayerInfo[playerid][pPaintBallG]] == 4) { rand = random(sizeof(gRandomSpawnBeach)); SetPlayerPosEx(playerid,gRandomSpawnBeach[rand][0],gRandomSpawnBeach[rand][1],gRandomSpawnBeach[rand][2]); SetPlayerSkin(playerid, 115); SetPlayerWorldBounds(playerid, 708.0417, 3449.1443,1948.9238,15.4930); SetPlayerInterior(playerid, 0); if(PlayerInfo[playerid][pPaintBallG] == 1) { SetPlayerVirtualWorld(playerid,125); } else if(PlayerInfo[playerid][pPaintBallG] == 2) { SetPlayerVirtualWorld(playerid,126); } else if(PlayerInfo[playerid][pPaintBallG] == 3) { SetPlayerVirtualWorld(playerid,127); } else if(PlayerInfo[playerid][pPaintBallG] == 4) { SetPlayerVirtualWorld(playerid,128); } SetTimerEx("UnFreezeStation", 100, false, "i", playerid); } else if(paintm[PlayerInfo[playerid][pPaintBallG]] == 5) { rand = random(sizeof(gRandomSpawnLSPD)); SetPlayerPosEx(playerid,gRandomSpawnLSPD[rand][0],gRandomSpawnLSPD[rand][1],gRandomSpawnLSPD[rand][2]); SetPlayerSkin(playerid, 285); //SetPlayerWorldBounds(playerid, 8064.9297, 8178.5098,-7521.1646,41.1745); SetPlayerInterior(playerid, 0); if(PlayerInfo[playerid][pPaintBallG] == 1) { SetPlayerVirtualWorld(playerid,125); } else if(PlayerInfo[playerid][pPaintBallG] == 2) { SetPlayerVirtualWorld(playerid,126); } else if(PlayerInfo[playerid][pPaintBallG] == 3) { SetPlayerVirtualWorld(playerid,127); } else if(PlayerInfo[playerid][pPaintBallG] == 4) { SetPlayerVirtualWorld(playerid,128); } SetTimerEx("UnFreezeStation", 100, false, "i", playerid); } return 1; } if(BeforeSpectate[playerid][pSpectating]) { SetPlayerVirtualWorld(playerid, BeforeSpectate[playerid][pWorld]); SetPlayerInterior(playerid, BeforeSpectate[playerid][pInt]); if(BeforeSpectate[playerid][pState] == PLAYER_STATE_DRIVER) PutPlayerInVehicle(playerid, BeforeSpectate[playerid][pInVehicle], 0); else if(BeforeSpectate[playerid][pState] == PLAYER_STATE_PASSENGER) PutPlayerInVehicle(playerid, BeforeSpectate[playerid][pInVehicle], 1 + random(3)); else SetPlayerPos(playerid, BeforeSpectate[playerid][pOldPos][0], BeforeSpectate[playerid][pOldPos][1], BeforeSpectate[playerid][pOldPos][2]); BeforeSpectate[playerid][pSpectating] = false; return 1; } if(PlayerInfo[playerid][pJailed] == 1) { SetPlayerWantedLevel(playerid, 0); DestroyDynamic3DTextLabel(WantedScris[playerid]); PlayerTextDrawHide(playerid, WantedText[playerid]); SetPlayerInterior(playerid, 6); rand = random(sizeof(gRandomJailSpawns)); SetPlayerPosEx(playerid,gRandomJailSpawns[rand][0],gRandomJailSpawns[rand][1],gRandomJailSpawns[rand][2]); TogglePlayerControllable(playerid, 0); SetTimerEx("UnFreezeStation", 1000, false, "i", playerid); if(PlayerInfo[playerid][pVirtualPD] == 3) { SetPlayerVirtualWorld(playerid, 3); } else { SetPlayerVirtualWorld(playerid, 0); } return 1; } if(PlayerInfo[playerid][pJailed] == 2) { DestroyDynamic3DTextLabel(WantedScris[playerid]); PlayerTextDrawHide(playerid, WantedText[playerid]); SetPlayerInterior(playerid, 10); rand = random(sizeof(gRandomAJailSpawns)); SetPlayerPosEx(playerid,gRandomAJailSpawns[rand][0],gRandomAJailSpawns[rand][1],gRandomAJailSpawns[rand][2]); TogglePlayerControllable(playerid, 0); SetTimerEx("UnFreezeStation", 1000, false, "i", playerid); return 1; } if(house != 999) { if(PlayerInfo[playerid][pSpawnChange] == 1) { SetPlayerToTeamColor(playerid); SetPlayerInterior(playerid,HouseInfo[house][hInterior]); SetPlayerPosEx(playerid, HouseInfo[house][hExitx], HouseInfo[house][hExity],HouseInfo[house][hExitz]); SetPlayerVirtualWorld(playerid, HouseInfo[house][hVirtual]); PlayerInfo[playerid][pLocal] = house; PlayerInfo[playerid][pInt] = HouseInfo[house][hInterior]; InHouse[playerid] = house; if(strlen(housestring[InHouse[playerid]]) > 0) { StopAudioStreamForPlayer(playerid); PlayAudioStreamForPlayer(playerid, housestring[InHouse[playerid]]); } return 1; } } if (PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1) // LSPD { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid, 246.7732,65.1425,1003.6406); SetPlayerFacingAngle(playerid, 270.0); SetPlayerInterior(playerid,6); PlayerInfo[playerid][pInt] = 6; return 1; } if (PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2) // FBI { SetPlayerToTeamColor(playerid); SetPlayerInterior(playerid, 3); SetPlayerPosEx(playerid, 230.0687,165.1646,1003.0234); PlayerInfo[playerid][pInt] = 3; InHQ[playerid] = 2; return 1; } if (PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3) // NG { SetPlayerToTeamColor(playerid); SetPlayerInterior(playerid, 0); SetPlayerPosEx(playerid, 213.8154,1866.6807,13.1406); PlayerInfo[playerid][pInt] = 0; return 1; } if (PlayerInfo[playerid][pMember] == 4 || PlayerInfo[playerid][pLeader] == 4) // Los Aztecas { SetPlayerToTeamColor(playerid); SetPlayerInterior(playerid, 6); SetPlayerPosEx(playerid, 774.213989,-48.924297,1000.585937); PlayerInfo[playerid][pInt] = 6; SetPlayerVirtualWorld(playerid, 1); InHQ[playerid] = 4; if(PlayerInfo[playerid][pGunLic] == 1) { GivePlayerWeaponEx(playerid, 24, 50); } return 1; } if (PlayerInfo[playerid][pMember] == 5 || PlayerInfo[playerid][pLeader] == 5) // Grove Street { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid,2496.049804,-1695.238159,1014.742187); SetPlayerInterior(playerid, 3); PlayerInfo[playerid][pInt] = 3; InHQ[playerid] = 5; if(PlayerInfo[playerid][pGunLic] == 1) { GivePlayerWeaponEx(playerid, 24, 50); } SetPlayerVirtualWorld(playerid,393); return 1; } if (PlayerInfo[playerid][pMember] == 6 || PlayerInfo[playerid][pLeader] == 6) // Los Vagos { SetPlayerToTeamColor(playerid); SetPlayerInterior(playerid, 12); SetPlayerPosEx(playerid, 2324.4199,-1145.5684,1050.7101); PlayerInfo[playerid][pInt] = 12; InHQ[playerid] = 6; if(PlayerInfo[playerid][pGunLic] == 1) { GivePlayerWeaponEx(playerid, 24, 50); } SetPlayerVirtualWorld(playerid,1); return 1; } if (PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pLeader] == 8) // LVPD { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid, 246.8886,64.7381,1003.6406); SetPlayerInterior(playerid,6); PlayerInfo[playerid][pInt] = 6; InHQ[playerid] = 8; SetPlayerVirtualWorld(playerid, 3); return 1; } if (PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pLeader] == 9) // News Reporter { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid, -2027.0515,-104.5211,1035.1719); SetPlayerInterior(playerid,3); PlayerInfo[playerid][pInt] = 3; GivePlayerWeaponEx(playerid,43,50); InHQ[playerid] = 9; return 1; } if (PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pLeader] == 10) // Ballas { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid, 964.106994,-53.205497,1001.124572); SetPlayerInterior(playerid,3); PlayerInfo[playerid][pInt] = 3; InHQ[playerid] = 10; if(PlayerInfo[playerid][pGunLic] == 1) { GivePlayerWeaponEx(playerid, 24, 50); } return 1; } if (PlayerInfo[playerid][pMember] == 11 || PlayerInfo[playerid][pLeader] == 11) // Hitman { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid, 2323.9993,-1148.0469,1050.7101); SetPlayerInterior(playerid,12); PlayerInfo[playerid][pInt] = 12; InHQ[playerid] = 11; SetPlayerVirtualWorld(playerid, 2); return 1; } if (PlayerInfo[playerid][pMember] == 12 || PlayerInfo[playerid][pLeader] == 12) // SI { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid,1494.325195,1304.942871,1093.289062); SetPlayerInterior(playerid,3); PlayerInfo[playerid][pInt] = 3; SetPlayerVirtualWorld(playerid, 3); InHQ[playerid] = 12; return 1; } if (PlayerInfo[playerid][pMember] == 13 || PlayerInfo[playerid][pLeader] == 13) // LS TAXI { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid,1700.9830,-1667.8865,20.2188); SetPlayerInterior(playerid,18); PlayerInfo[playerid][pInt] = 18; SetPlayerVirtualWorld(playerid, 5); InHQ[playerid] = 13; return 1; } if (PlayerInfo[playerid][pMember] == 14 || PlayerInfo[playerid][pLeader] == 14) // Paramedic { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid,1494.325195,1304.942871,1093.289062); SetPlayerInterior(playerid,3); PlayerInfo[playerid][pInt] = 3; SetPlayerVirtualWorld(playerid, 7); InHQ[playerid] = 14; return 1; } if (PlayerInfo[playerid][pMember] == 15 || PlayerInfo[playerid][pLeader] == 15) // LV TAXI { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid,1700.9830,-1667.8865,20.2188); SetPlayerInterior(playerid,18); PlayerInfo[playerid][pInt] = 18; SetPlayerVirtualWorld(playerid, 15); InHQ[playerid] = 15; return 1; } if (PlayerInfo[playerid][pMember] == 16 || PlayerInfo[playerid][pLeader] == 16) // SF TAXI { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid,1700.9830,-1667.8865,20.2188); SetPlayerInterior(playerid,18); PlayerInfo[playerid][pInt] = 18; SetPlayerVirtualWorld(playerid, 16); InHQ[playerid] = 16; return 1; } if (PlayerInfo[playerid][pMember] == 17 || PlayerInfo[playerid][pLeader] == 17) // SFPD { SetPlayerToTeamColor(playerid); SetPlayerPosEx(playerid, 246.8886,64.7381,1003.6406); SetPlayerInterior(playerid,6); PlayerInfo[playerid][pInt] = 6; InHQ[playerid] = 17; SetPlayerVirtualWorld(playerid, 4); return 1; } if (PlayerInfo[playerid][pMember] == 18 || PlayerInfo[playerid][pLeader] == 18) //TTR { SetPlayerToTeamColor(playerid); SetPlayerInterior(playerid, 17); SetPlayerPosEx(playerid, -959.7054,1953.4484,9.0000); PlayerInfo[playerid][pInt] = 17; InHQ[playerid] = 18; SetPlayerVirtualWorld(playerid,0); return 1; } if (PlayerInfo[playerid][pMember] == 19 || PlayerInfo[playerid][pLeader] == 19) //69PM { SetPlayerToTeamColor(playerid); SetPlayerInterior(playerid, 1); SetPlayerPosEx(playerid, 965.0608,2107.5391,1011.0303); PlayerInfo[playerid][pInt] = 1; InHQ[playerid] = 19; SetPlayerVirtualWorld(playerid,0); return 1; } if (PlayerInfo[playerid][pMember] == 0 || PlayerInfo[playerid][pLeader] == 0) // Civilian { SetPlayerPosEx(playerid, 1449.7380,-2286.8950,13.5469); SetPlayerFacingAngle(playerid, 6.9127); SetPlayerInterior(playerid,0); PlayerInfo[playerid][pInt] = 0; SetPlayerVirtualWorld(playerid, 0); return 1; } if ((gTeam[playerid]) == 3) { SetPlayerPosEx(playerid, 1449.7380,-2286.8950,13.5469); SetPlayerFacingAngle(playerid, 6.9127); SetPlayerInterior(playerid,0); PlayerInfo[playerid][pInt] = 0; SetPlayerVirtualWorld(playerid, 0); return 1; } else { SetPlayerToTeamColor(playerid); if(PlayerInfo[playerid][pOrigin] == 1) // Europa { SetPlayerPosEx(playerid, 1449.7380,-2286.8950,13.5469); SetPlayerFacingAngle(playerid, 6.9127); SetPlayerInterior(playerid,0); PlayerInfo[playerid][pInt] = 0; SetPlayerVirtualWorld(playerid, 0); } else if(PlayerInfo[playerid][pOrigin] == 2) // America { SetPlayerPosEx(playerid, 1449.7380,-2286.8950,13.5469); SetPlayerFacingAngle(playerid, 6.9127); SetPlayerInterior(playerid,0); PlayerInfo[playerid][pInt] = 0; SetPlayerVirtualWorld(playerid, 0); } else if(PlayerInfo[playerid][pOrigin] == 3) // Asia { SetPlayerPosEx(playerid, 1449.7380,-2286.8950,13.5469); SetPlayerFacingAngle(playerid, 6.9127); SetPlayerInterior(playerid,0); PlayerInfo[playerid][pInt] = 0; SetPlayerVirtualWorld(playerid, 0); } else if(PlayerInfo[playerid][pOrigin] == 4) // Africa { SetPlayerPosEx(playerid, 1449.7380,-2286.8950,13.5469); SetPlayerFacingAngle(playerid, 6.9127); SetPlayerInterior(playerid,0); PlayerInfo[playerid][pInt] = 0; SetPlayerVirtualWorld(playerid, 0); } else if(PlayerInfo[playerid][pOrigin] == 5) // Australia { SetPlayerPosEx(playerid, 1449.7380,-2286.8950,13.5469); SetPlayerFacingAngle(playerid, 6.9127); SetPlayerInterior(playerid,0); PlayerInfo[playerid][pInt] = 0; SetPlayerVirtualWorld(playerid, 0); } else { SetPlayerPosEx(playerid,358.0976,-1841.3488,5.1257); SetPlayerInterior(playerid,0); SetPlayerFacingAngle(playerid, 90.0); SetPlayerCameraPos(playerid,1460.0, -1324.0, 287.2); SetPlayerCameraLookAt(playerid,1374.5, -1291.1, 239.0); PlayerPlaySound(playerid, 1097,-119.9460,23.1096,12.2238); } } SetTimerEx("UpdateSecondary", 3000, false, "i", playerid); } return 1; }
Код:
public OnPlayerSpawn(playerid) { SetPlayerHealthEx(playerid, 100); SetPlayerArmourEx(playerid, 0); TextDrawShowForPlayer(playerid, Time); TextDrawShowForPlayer(playerid, Date); SetPlayerWantedLevel(playerid, PlayerInfo[playerid][pWantedLevel]); DestroyDynamic3DTextLabel(WantedScris[playerid]); if(PlayerInfo[playerid][pWantedLevel] > 0) { Tigaanel[playerid] = 1; DestroyDynamic3DTextLabel(WantedScris[playerid]); new str2[256]; format(str2,sizeof(str2),"{FF00FF}Wanted Level: %d", PlayerInfo[playerid][pWantedLevel]); WantedScris[playerid] = CreateDynamic3DTextLabel(str2, COLOR_WHITE, 0, 0, -20, 20, playerid); Streamer_SetFloatData(STREAMER_TYPE_3D_TEXT_LABEL, WantedScris[playerid] , E_STREAMER_ATTACH_OFFSET_Z, 0.48); } if(PlayerInfo[playerid][pWantedLevel] >= 1) { new str1[256]; PlayerTextDrawShow(playerid, WantedText[playerid]); format(str1,sizeof(str1),"~y~WANTED TIME: ~r~%d MINUTES",wantedlost[playerid]/60+1); PlayerTextDrawSetString(playerid, WantedText[playerid], str1); } SetPlayerScore(playerid, PlayerInfo[playerid][pLevel]); if(OnDuty[playerid] > 0) { if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1) { GivePlayerWeaponEx(playerid, 24, 500); GivePlayerWeaponEx(playerid, 3, 1); GivePlayerWeaponEx(playerid, 41, 500); GivePlayerWeaponEx(playerid, 29, 1000); GivePlayerWeaponEx(playerid, 31, 1000); SetPlayerArmourEx(playerid, 100); SetPlayerHealthEx(playerid, 100); } if(PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2) { GivePlayerWeaponEx(playerid, 24, 500); GivePlayerWeaponEx(playerid, 3, 1); GivePlayerWeaponEx(playerid, 41, 500); GivePlayerWeaponEx(playerid, 29, 1000); GivePlayerWeaponEx(playerid, 31, 1000); SetPlayerArmourEx(playerid, 100); SetPlayerHealthEx(playerid, 100); } if(PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3) { GivePlayerWeaponEx(playerid, 24, 500); GivePlayerWeaponEx(playerid, 41, 500); GivePlayerWeaponEx(playerid, 29, 1000); GivePlayerWeaponEx(playerid, 31, 1000); SetPlayerArmourEx(playerid, 100); SetPlayerHealthEx(playerid, 100); } if(PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pLeader] == 8) { GivePlayerWeaponEx(playerid, 24, 500); GivePlayerWeaponEx(playerid, 3, 1); GivePlayerWeaponEx(playerid, 41, 500); GivePlayerWeaponEx(playerid, 29, 1000); GivePlayerWeaponEx(playerid, 31, 1000); SetPlayerArmourEx(playerid, 100); SetPlayerHealthEx(playerid, 100); } if(PlayerInfo[playerid][pMember] == 17 || PlayerInfo[playerid][pLeader] == 17) { GivePlayerWeaponEx(playerid, 24, 500); GivePlayerWeaponEx(playerid, 3, 1); GivePlayerWeaponEx(playerid, 41, 500); GivePlayerWeaponEx(playerid, 29, 1000); GivePlayerWeaponEx(playerid, 31, 1000); SetPlayerArmourEx(playerid, 100); SetPlayerHealthEx(playerid, 100); } } if(!gPlayerAnimLibsPreloaded[playerid]) { PreloadAnimLib(playerid,"BOMBER"); PreloadAnimLib(playerid,"RAPPING"); PreloadAnimLib(playerid,"SHOP"); PreloadAnimLib(playerid,"BEACH"); PreloadAnimLib(playerid,"SMOKING"); PreloadAnimLib(playerid,"FOOD"); PreloadAnimLib(playerid,"ON_LOOKERS"); PreloadAnimLib(playerid,"DEALER"); PreloadAnimLib(playerid,"MISC"); PreloadAnimLib(playerid,"SWEET"); PreloadAnimLib(playerid,"RIOT"); PreloadAnimLib(playerid,"PED"); PreloadAnimLib(playerid,"POLICE"); PreloadAnimLib(playerid,"CRACK"); PreloadAnimLib(playerid,"CARRY"); PreloadAnimLib(playerid,"COP_AMBIENT"); PreloadAnimLib(playerid,"PARK"); PreloadAnimLib(playerid,"INT_HOUSE"); PreloadAnimLib(playerid,"FOOD"); gPlayerAnimLibsPreloaded[playerid] = 1; } if(PlayerInfo[playerid][pPin] == 0) return SendClientMessage(playerid, -1, "PIN: Nu ai un cont pin setat! Foloseste comanda /addpin !"); gTeam[playerid] = PlayerInfo[playerid][pTeam]; if(gTeam[playerid] == 4) { gTeam[playerid] = 4; } if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2 || PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3 || PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pLeader] == 8 || PlayerInfo[playerid][pMember] == 17 || PlayerInfo[playerid][pLeader] == 17) { gTeam[playerid] = 2; PlayerInfo[playerid][pTeam] = 2; } if(gPlayerLogged[playerid] == 0) { SendClientMessage(playerid, COLOR_LIGHTRED, "** This server requires a Login BEFORE spawn (Kicked) **"); Kick(playerid); return 1; } ChosenSkin[playerid] = 1; SetPlayerSpawn(playerid); SetPlayerToTeamColor(playerid); playerdeath[playerid] = 0; Undercover[playerid] = 0; SetPlayerTeam(playerid,4); if(MP3ON[playerid] == 0) StopAudioStreamForPlayer(playerid); StopAudioStreamForPlayer(playerid); return 1; }