07.04.2010, 13:24
Hi guys, i am wondering how to change spawn in LSLRP(Los Santos life roleplay) for factions, so i tried on public Setplayerspawn, public Onplayerdeath, everywhere :S..
I inserted this:
This is how looks mine SetPlayerSpawn
Help pls
I inserted this:
Код:
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 1) { SetPlayerPos(playerid, 1528.3640,-1691.8621,6.2252); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pMember] == 2) { SetPlayerPos(playerid, 1085.2373,-1227.3109,15.8203); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pMember] == 3) { SetPlayerPos(playerid, 2746.5344,-2453.9412,16.6562); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 4 || PlayerInfo[playerid][pMember] == 4) { SetPlayerPos(playerid, 1148.3036,-1362.2246,13.8324); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 5 || PlayerInfo[playerid][pMember] == 5) { SetPlayerPos(playerid, 2770.8198,-1628.3962,12.1775); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 6 || PlayerInfo[playerid][pMember] == 6) { SetPlayerPos(playerid, 976.1622,-1268.0581,16.9890); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 7 || PlayerInfo[playerid][pMember] == 7) { SetPlayerPos(playerid, 300.0059,-1154.7731,81.2141); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pMember] == 8) { SetPlayerPos(playerid,1101.8781,-300.9010,73.9922); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pMember] == 9) { SetPlayerPos(playerid,1576.3503,-1331.4772,16.4844); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pMember] == 10) { SetPlayerPos(playerid,2476.0647,-1536.0177,29.0934); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 11 || PlayerInfo[playerid][pMember] == 11) { SetPlayerPos(playerid,2494.9575,-1686.9678,13.5142); SetPlayerInterior(playerid, 0); }
Код:
public SetPlayerSpawn(playerid) { if(IsPlayerConnected(playerid)) { new rand; if(PlayerPaintballing[playerid] != 0) { ResetPlayerWeapons(playerid); GivePlayerWeapon(playerid, 29, 99999); GivePlayerWeapon(playerid, 24, 99999); GivePlayerWeapon(playerid, 31, 99999); GivePlayerWeapon(playerid, 34, 99999); rand = random(sizeof(PaintballSpawns)); SetPlayerPos(playerid, PaintballSpawns[rand][0], PaintballSpawns[rand][1], PaintballSpawns[rand][2]); SetPlayerInterior(playerid, 10); return 1; } if(MedicBill[playerid] == 1) { if(PlayerInfo[playerid][pMInsure] == 0) { PlayerInfo[playerid][pDeaths] += 1; SetPlayerInterior(playerid, 0); SetPlayerHealth(playerid, 100); MedicBill[playerid] = 0; GivePlayerMoney(playerid, -360); SendClientMessage(playerid, COLOR_LIGHTBLUE, " Your medical insurance did not cover the bill, you where charged $360. "); } if(PlayerInfo[playerid][pMInsure] == 1) { SetPlayerInterior(playerid, 0); SetPlayerHealth(playerid, 100); MedicBill[playerid] = 0; SendClientMessage(playerid, COLOR_LIGHTBLUE, " Your medical insurance covered the bill, you where not charged. "); } } if(PlayerInfo[playerid][pTut] == 0) { gOoc[playerid] = 1; gNews[playerid] = 1; gFam[playerid] = 1; SetPlayerSkin(playerid, 137); TogglePlayerControllable(playerid, 0); RegistrationStep[playerid] = 1; SendClientMessage(playerid, COLOR_GREEN, "Dobrodosli na Genius Gaming Roleplay, molimo registrirajte se."); ShowPlayerDialog(playerid, SEXMENU, DIALOG_STYLE_LIST, "Spol","Muski\nZenski ", "Select", "Cancel"); } if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pMember] == 1) { SetPlayerPos(playerid, 1528.3640,-1691.8621,6.2252); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pMember] == 2) { SetPlayerPos(playerid, 1085.2373,-1227.3109,15.8203); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pMember] == 3) { SetPlayerPos(playerid, 2746.5344,-2453.9412,16.6562); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 4 || PlayerInfo[playerid][pMember] == 4) { SetPlayerPos(playerid, 1148.3036,-1362.2246,13.8324); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 5 || PlayerInfo[playerid][pMember] == 5) { SetPlayerPos(playerid, 2770.8198,-1628.3962,12.1775); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 6 || PlayerInfo[playerid][pMember] == 6) { SetPlayerPos(playerid, 976.1622,-1268.0581,16.9890); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 7 || PlayerInfo[playerid][pMember] == 7) { SetPlayerPos(playerid, 300.0059,-1154.7731,81.2141); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pMember] == 8) { SetPlayerPos(playerid,1101.8781,-300.9010,73.9922); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pMember] == 9) { SetPlayerPos(playerid,1576.3503,-1331.4772,16.4844); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pMember] == 10) { SetPlayerPos(playerid,2476.0647,-1536.0177,29.0934); SetPlayerInterior(playerid, 0); } if(PlayerInfo[playerid][pMember] == 11 || PlayerInfo[playerid][pMember] == 11) { SetPlayerPos(playerid,2494.9575,-1686.9678,13.5142); SetPlayerInterior(playerid, 0); } else { SetPlayerPos(playerid,positionx,positiony,positionz); } } return 1; }