SA-MP Forums Archive
Help me on PlayerSpawn - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help me on PlayerSpawn (/showthread.php?tid=500898)



Help me on PlayerSpawn - [IND]Crazy - 15.03.2014

anyone help me please , i have added random spawn on my gm but still bug i always spawn in BB -_-"

This my script

Код:
new Float:gRandomPlayerSpawns[][] = {
{1958.3783,1343.1572,15.3746},
{2199.6531,1393.3678,10.8203},
{2483.5977,1222.0825,10.8203},
{2637.2712,1129.2743,11.1797},
{2000.0106,1521.1111,17.0625},
{2024.8190,1917.9425,12.3386},
{2261.9048,2035.9547,10.8203},
{2262.0986,2398.6572,10.8203},
{2244.2566,2523.7280,10.8203},
{2335.3228,2786.4478,10.8203},
{2150.0186,2734.2297,11.1763},
{2158.0811,2797.5488,10.8203},
{1969.8301,2722.8564,10.8203},
{1652.0555,2709.4072,10.8265},
{1564.0052,2756.9463,10.8203},
{1271.5452,2554.0227,10.8203},
{1441.5894,2567.9099,10.8203},
{1480.6473,2213.5718,11.0234},
{1400.5906,2225.6960,11.0234},
{1598.8419,2221.5676,11.0625},
{1318.7759,1251.3580,10.8203},
{1558.0731,1007.8292,10.8125},
//{-857.0551,1536.6832,22.5870},   Out of Town Spawns
//{817.3494,856.5039,12.7891},
//{116.9315,1110.1823,13.6094},
//{-18.8529,1176.0159,19.5634},
//{-315.0575,1774.0636,43.6406},
{1705.2347,1025.6808,10.8203},
{1311.0511,-859.5232,39.5781},
{1266.4478,-886.8973,42.8828},
{1215.1746,-985.5792,43.4766},
{1036.0188,-1033.2394,31.8875},
{899.3657,-1101.6421,23.5000},
{1266.3933,-1155.4716,23.8281},
{1934.1178,-1165.0901,21.5199},
{2075.6453,-1143.9193,23.7344},
{1808.8132,-1431.8883,13.4297},
{2092.1519,-1599.2207,13.3644},
{2475.0137,-1682.6040,13.3990},
{2484.7813,-1756.9534,13.5469},
{2154.5181,-1758.0615,13.5401},
{2011.8098,-2058.1787,13.5469},
{2378.9795,-2206.4636,13.5469},
{2446.0144,-2466.0679,13.6262},
{1085.8051,-1836.0471,13.5844},
{603.4995,-1829.7418,5.9682},
{157.2219,-1596.3412,13.2774},
{333.3855,-1291.6586,54.2239},
{1712.1257,-1103.1752,24.0781},
{2143.4961,-1183.9995,23.9922},
{2712.9771,-1190.5815,69.3918},
{2834.6213,-1181.4551,24.7126},
{-2000.8451,137.9753,27.6799},
{-1468.8646,-196.2904,14.1484},
{-2711.9351,202.5989,4.3281},
{-2712.4509,-301.7253,7.1875},
{-1456.7698,465.6056,7.1875},
{-1853.0000,1404.0000,7.1841},
{-2644.8748,1369.1454,7.1634},
{397.3987,2529.5020,16.5617},
{-2130.7727,-440.3822,35.3359},
{-2427.4055,56.9957,35.1719},
{-2761.1123,133.5347,7.0114},
{-2872.8289,490.0020,4.9141},
{-2679.5112,577.0090,14.6322},
{-2666.5212,904.4432,79.6595},
{-2394.1724,1118.8451,55.8425},
{-2527.1565,2389.9065,16.2889},
{-2386.4214,2218.0977,4.9844},
{-2580.6206,2251.3718,4.9844}
};
Код:
public OnPlayerSpawn(playerid)
{
	new Random = random(sizeof(gRandomPlayerSpawns));
    SetPlayerPos(playerid, gRandomPlayerSpawns[Random][0], gRandomPlayerSpawns[Random][1], gRandomPlayerSpawns[Random][2]);
anyone help me please


Re: Help me on PlayerSpawn - MythicalMarauder - 15.03.2014

Try this out:
pawn Код:
new Random = random(3);
    SetPlayerPos(playerid, gRandomPlayerSpawns[Random][0], gRandomPlayerSpawns[Random][1], gRandomPlayerSpawns[Random][2]);
SetPlayerFacingAngle(playerid, gRandomPlayerSpawns[Random][3];
Tested.


Re: Help me on PlayerSpawn - [IND]Crazy - 16.03.2014

Still bugged . how to recreate random spawn ?
i use GM Moneypimp SATMD_v9


Re: Help me on PlayerSpawn - AroseKhanNiazi - 16.03.2014

randmon spawn just go to that place and typr /save where u want it and add it here https://sampwiki.blast.hk/wiki/File_Functions