Random coordinates
#1

I need alot (300+) of random exterior coordinates all around San Andreas for my script and I want to ask you guys if you want to contribute with some of them? Your name will be put in the credits of my script.

I'd love your coordinates if:

*They are exterior coordinates.
*They are spread across San Andreas. (I'd love city specific coordinates too)
*They are split with a comma.

I'd love you even more if you'd give me the whole array, so I can implement it easily, but no need for that.

Example:

pawn Code:
{1249.7258, -2047.9263, 59.9209, 90.2055},
{1241.2084, -2057.6521, 60.0190, 94.9352},
{1241.0105, -2052.6873, 59.9975, 2.8144},
{718.4906, -1477.3024, 5.4688, 357.9947},
{722.3772, -1477.2856, 5.4688, 272.3814},
{-2796.9854, 1224.8180, 20.5429, 192.0335},
{-2454.2170, 503.8759, 30.0790, 267.2932},
{-2669.7322, -6.0874, 6.1328, 89.8853},
Reply
#2

Area 51
Code:
{26.4734,1362.1244,9.1719}, // 1
{3.7642,1344.8734,9.1719}, // 2
{21.1455,1344.7678,9.1719}, // 3
{4.6067,1381.4210,9.1781}, // 4
{-1.3956,1395.5034,9.1719}, // 5
{-17.8874,1392.1027,9.1719}, // 6
{-29.8176,1363.9698,9.1719}, // 7
{-21.5320,1348.8701,9.1719}, // 8
{-87.5598,1378.4382,10.273} // 9
Bayside
Code:
{-2237.6675,2353.6357,4.9804}, // 1
{-2244.4297,2382.6162,5.0651}, // 2
{-2280.8123,2288.3540,4.9592}, // 3
{-2349.1038,2422.4600,7.3348}, // 4
{-2379.6294,2443.7397,10.1694}, // 5
{-2386.5432,2446.7439,10.1694}, // 6
{-2408.1724,2454.0754,13.0031}, // 7
{-2472.1128,2450.4846,17.3230}, // 8
{-2479.6860,2449.3577,17.3230}, // 9
{-2422.2366,2492.0024,13.1417}, // 10
{-2446.1724,2491.9753,15.3203}, // 11
{-2464.5906,2490.5576,16.8125}, // 12
{-2478.8467,2488.8369,18.2300}, // 13
{-2446.7429,2512.4402,15.7003}, // 14
{-2479.0059,2508.9224,17.7910}, // 15
{-2381.9663,2407.1270,8.8858}, // 16
{-2420.4670,2406.6948,13.0409}, // 17
{-2482.6694,2406.4666,17.1154}, // 18
{-2437.3914,2353.8271,4.9609}, // 19
{-2455.5942,2254.1738,4.9807}, // 20
{-2485.4236,2272.1384,4.9844}, // 21
{-2493.9551,2272.2332,4.9537}, // 22
{-2485.5320,2288.5393,4.9844}, // 23
{-2493.8901,2288.4854,4.9844}, // 24
{-2510.8262,2276.7490,4.9844}, // 25
{-2520.0254,2281.3076,4.9844}, // 26
{-2523.5359,2239.6621,5.3671}, // 27
{-2551.8118,2267.2979,5.4490}, // 28
{-2537.5444,2319.4932,4.9844}, // 29
{-2518.5354,2320.1204,4.9844}, // 30
{-2501.3713,2319.2898,4.9844}, // 31
{-2478.4834,2318.5718,4.9844}, // 32
{-2491.0913,2363.3721,10.2724}, // 33
{-2519.1113,2339.8892,4.9844}, // 34
{-2522.5203,2339.7744,4.9844}, // 35
{-2538.6680,2339.7317,4.9798}, // 36
{-2542.5051,2339.8647,4.9796}, // 37
{-2582.4805,2300.4995,7.0029}, // 38
{-2583.2078,2308.0552,7.0029}, // 39
{-2626.8638,2283.4148,8.3086}, // 40
{-2626.3899,2292.0630,8.3048}, // 41
{-2626.1743,2309.9878,8.3031}, // 42
{-2626.2063,2318.3826,8.3033}, // 43
{-2636.8171,2334.5730,8.4725}, // 44
{-2636.2891,2351.8054,8.5170}, // 45
{-2632.4487,2375.7893,9.0227}, // 46
{-2634.8933,2402.7507,11.2624}, // 47
{-2633.4346,2410.8716,13.9902}, // 48
{-2598.1265,2357.0999,9.8830}, // 49
{-2598.0171,2364.6636,9.8830} // 50
El Castillo Del Diablo
Code:
{-376.1929,2260.3374,43.0619}, // 1
{-377.5757,2242.1814,42.6185}, // 2
{-357.3189,2234.9360,42.4844}, // 3
{-362.4384,2222.3813,43.0078}, // 4
{-367.6448,2207.0874,42.4844}, // 5
{-383.7119,2206.3723,42.4236}, // 6
{-386.1368,2217.4868,42.4297}, // 7
{-389.2008,2230.9558,42.4297}, // 8
{-393.2216,2249.5173,42.4252}, // 9
{-404.1069,2258.2170,42.9105}, // 10
{-418.1620,2229.0820,42.4297}, // 11
{-431.0703,2240.3003,42.9834}, // 12
{-439.0085,2229.1797,42.4297}, // 13
{-453.7966,2229.2993,42.5009}, // 14
{-373.0963,2220.7695,42.4912} // 15
El Quebrados
Code:
{-1514.6758,2520.2603,55.9311}, // 1
{-1479.0077,2546.6387,56.2543}, // 2
{-1449.9937,2563.1714,55.8359}, // 3
{-1476.2640,2562.5850,56.1762}, // 4
{-1507.5504,2559.9294,55.8359}, // 5
{-1536.6355,2564.0869,55.8359}, // 6
{-1531.1212,2592.1909,55.8359}, // 7
{-1515.7974,2591.3223,55.8359}, // 8
{-1509.3804,2591.3933,55.8359}, // 9
{-1481.0229,2592.4141,55.8359}, // 10
{-1471.4684,2592.4592,55.8359}, // 11
{-1458.0313,2590.9031,55.9844}, // 12
{-1449.8424,2592.9199,55.8359}, // 13
{-1438.7703,2592.0073,55.8359}, // 14
{-1430.1046,2584.1597,56.8876}, // 15
{-1440.4445,2610.7317,55.8359}, // 16
{-1448.2361,2610.7341,55.8359}, // 17
{-1454.8694,2610.6704,55.8359}, // 18
{-1465.6504,2610.6116,55.8359}, // 19
{-1483.3496,2645.7507,58.7281}, // 20
{-1508.9755,2609.7957,55.8359}, // 21
{-1519.2333,2609.6870,55.8359}, // 22
{-1529.2393,2610.2319,55.8359}, // 23
{-1531.3433,2610.3740,55.8359}, // 24
{-1568.1296,2629.6514,55.8403}, // 25
{-1562.9111,2650.9521,55.8403}, // 26
{-1587.7061,2650.0928,55.8594}, // 27
{-1603.4050,2689.5569,55.2856}, // 28
{-1589.8732,2705.7065,56.1762}, // 29
{-1577.6796,2686.4326,55.8359}, // 30
{-1564.2253,2711.8772,55.8594}, // 31
{-1551.0396,2699.8911,56.2699}, // 32
{-1529.1263,2686.1060,55.8359}, // 33
{-1511.9796,2694.3684,55.8359}, // 34
{-1491.5396,2685.1860,55.8594}, // 35
{-1482.6282,2701.9036,56.2543}, // 36
{-1466.4425,2692.9146,56.2699}, // 37
{-1450.7448,2691.0474,56.1762}, // 38
{-1534.0801,2655.5239,56.2814}, // 39
{-1513.1240,2646.5605,56.1762}, // 40
{-1459.1064,2653.3696,55.8359}, // 41
{-1444.4083,2653.4124,56.2699}, // 42
{-1446.5964,2636.7217,56.2543}, // 43
{-1390.1387,2638.3479,55.9844}, // 44
{-1319.9745,2697.9158,50.2663}, // 45
{-1266.1964,2716.0247,50.2663} // 46
Hampton Barns
Code:
{747.9076,257.8517,27.0859}, // 1
{748.2360,278.6656,27.2605}, // 2
{723.5266,268.9130,22.4531}, // 2
{723.5266,268.9130,22.4531}, // 3
{705.5497,291.3535,20.4219}, // 4
{718.2568,300.6444,20.2344}, // 5
{747.0721,305.0904,20.2344}, // 6
{748.8600,350.1995,20.4346}, // 7
{772.3669,348.1352,20.1527}, // 8
{783.7886,353.4661,19.5938}, // 9
{805.4339,359.0071,19.7621}, // 10
{807.1572,372.2703,19.4208}, // 11
{783.6137,378.3091,21.2109}, // 12
{758.2032,375.0105,23.1952}, // 13
{752.6900,375.4529,23.2324}, // 14
More at Weedarr...

I don't need any credits on your script.
Reply
#3

Quote:
Originally Posted by Tayab
View Post
More at Weedarr...
Thanks, bro!
Reply
#4

Let MapAndreas generate some points for you. You don't really need to have the plugin loaded all the time. Create a loop that will pick random X and Y coordinates. Then use MapAndreas to find the appropriate Z coordinate. Save the results to a file.
Reply
#5

Quote:
Originally Posted by Vince
View Post
Let MapAndreas generate some points for you. You don't really need to have the plugin loaded all the time. Create a loop that will pick random X and Y coordinates. Then use MapAndreas to find the appropriate Z coordinate. Save the results to a file.
Wouldn't this make spawnpoints in the water and on roofs? I'll try the plugin.
Reply
#6

Ye, didn't really think of that. It'll also generate on top of buildings. ;/
I suppose you could weed out anything with a Z value below 5 or higher than 30.
Reply
#7

Quote:
Originally Posted by Vince
View Post
Ye, didn't really think of that. It'll also generate on top of buildings. ;/
I suppose you could weed out anything with a Z value below 5 or higher than 30.
Do you possibly know what the max X and Y coord inside world boundraries are?

EDIT: I looked at https://sampwiki.blast.hk/wiki/SetPlayerWorldBounds, if I'm thinking right I'll randomize 20000?

EDIT2: Isn't 20000 way beyond land?
Reply
#8

pawn Code:
new
    Float: random_x = random(4000) - 2000,
    Float: random_y = random(4000) - 2000;
Reply
#9

Worked splendit! My code:

pawn Code:
MapAndreas_Init(MAP_ANDREAS_MODE_FULL);
for(new a; a < 100; a++)
    {
        new
            x=random(4000)-2000,
            y=random(4000)-2000,
            Float:z;
           
        MapAndreas_FindZ_For2DCoord(x, y, z);
       
        if(z >= 5.0 && z < 30.0)
        {
            new File:txt = fopen("randomcoords.txt", io_append), str[30];
            format(str, sizeof str, "{%d, %d, %f},\r\n", x, y, z);
            fwrite(txt, str);
            fclose(txt);
        }
    }
Output:

Code:
{1112, 1162, 9.819999},
{1493, 1273, 9.819999},
{-1511, -462, 5.000000},
{650, -349, 17.209999},
{-1821, -178, 8.389999},
{-451, 590, 16.180000},
{-957, 962, 12.469999},
{779, -1801, 24.309999},
{209, 1165, 14.119999},
{-68, 1469, 10.670000},
{1324, 1751, 17.029998},
{358, 1386, 6.659999},
{1649, 1764, 9.670000},
{-1400, 1499, 6.099999},
{-716, 830, 14.969999},
{1051, 1851, 9.819999},
{1727, 1562, 9.670000},
{-1193, -303, 13.139999},
{-635, -416, 24.319999},
{-1214, -227, 13.139999},
{-27, 918, 20.939998},
{748, -351, 8.929999},
{382, 1432, 6.619999},
{913, 1959, 9.729999},
{-1557, 1796, 19.879999},
{169, 1516, 9.519999},
{954, 882, 15.599999},
{1287, 1260, 9.819999},
{1319, 1253, 19.329999},
{1812, 1076, 5.730000},
{1237, 33, 23.959999},
{167, 765, 18.670000},
{-783, 1612, 26.109998},
{1277, 648, 5.440000},
{-927, 1429, 29.139999},
{-609, -487, 24.519998},
{357, 1907, 16.639999},
{-174, 671, 18.090000},
{1342, -1341, 12.380000},
{1697, 1067, 9.819999},
{478, 1124, 12.619999},
{-591, -1445, 10.969999},
{1477, 238, 18.059999},
{-1175, 1596, 10.149999},
{1014, 1411, 9.809999},
{577, -1661, 18.659999},
{1919, 1345, 23.279998},
{736, 283, 19.750000},
{-1862, 1238, 26.840000},
{1640, -1948, 23.079999},
{-1244, -572, 13.139999},
{-797, 1413, 12.559999},
Reply
#10

It works fine for me though we do not use the same MapAndreas.

Why do you call MapAndreas_Init 10 times inside the loop?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)