PDA

View Full Version : Help! 21Error while compiling


Youssefree
08/07/2016, 11:36 PM
Hello,
While compiling this filterscript(http://pastebin.com/xcc9ZQf6) i get the following errors :
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(226) : warning 217: loose indentation
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(292) : error 017: undefined symbol "cmdtext"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(294) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(295) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(296) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(296) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(297) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(297) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(298) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(300) : error 033: array must be indexed (variable "RaceVehicles")
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(306) : error 033: array must be indexed (variable "PlaceInfo")
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(312) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(313) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(319) : error 017: undefined symbol "cmdtext"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(321) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(321) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(322) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(337) : warning 209: function "OnPlayerCommandText" should return a value
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(361) : error 033: array must be indexed (variable "RaceVehicles")
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : error 017: undefined symbol "RacesVehicles"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : warning 215: expression has no effect
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : error 001: expected token: ";", but found "]"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : error 029: invalid expression, assumed zero
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


21 Errors.

Help me please!

Decurse
08/07/2016, 11:37 PM
can i see your code ?

WrathOfGenesis
09/07/2016, 12:06 AM
You need to replace

OnPlayerCommandText()

With

OnPlayerCommandText ( playerid , cmdtext [ ] )

That should solve most of your problems. For the ones which say they must be indexed, you've created an array, but attempted to use it as a standard variable. Arrays are used when you want to save the same variable for multiple instances (e.g. saving AdminLevel for all players, rather than building a seperate variable for each one).

Without arrays, to create an AdminLevel variable for all players and set player 10's level to 5 you would need

new player1AdminLevel;
new player2AdminLevel;
new player3AdminLevel;
...
new player1000AdminLevel;

player10AdminLevel = 5;

Using an array let's you turn hundreds of lines into one, when used like this:

new AdminLevel [ MAX_PLAYERS ];
AdminLevel [ 10 ] = 5;

When making an array, it must be used like this:

new Variable [ MAX_PLAYERS ];
Variable [ playerid ] = 10;

And not like this: (note the missing square brackets and destination value in the bottom line)

new Variable [ MAX_PLAYERS ];
Variable = 10;

Mencent
09/07/2016, 12:06 PM
public OnPlayerCommandText()
to
public OnPlayerCommandText(playerid,cmdtext[])

Youssefree
09/07/2016, 12:06 PM
can i see your code ?

" http://pastebin.com/xcc9ZQf6 "

Youssefree
09/07/2016, 12:11 PM
public OnPlayerCommandText()
to
public OnPlayerCommandText(playerid,cmdtext[])

D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(226) : warning 217: loose indentation
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(300) : error 033: array must be indexed (variable "RaceVehicles")
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(306) : error 033: array must be indexed (variable "PlaceInfo")
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(337) : warning 209: function "OnPlayerCommandText" should return a value
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(361) : error 033: array must be indexed (variable "RaceVehicles")
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : error 017: undefined symbol "RacesVehicles"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : warning 215: expression has no effect
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : error 001: expected token: ";", but found "]"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : error 029: invalid expression, assumed zero
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(363) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


7 Errors.

Mencent
09/07/2016, 12:15 PM
So. Try this:

#define winner_money 100000
#define COLOR_RED 0xFF0000FF

enum RacePlaces
{
Float:Pos_X,
Float:Pos_Y,
Float:Pos_Z,
Float:Pos_A
};

new Float:PlaceInfo[14][RacePlaces] =
{
{-2824.0039,-427.6653,6.7661,2.2123},
{-2819.6379,-427.0293,6.7661,4.8471},
{-2823.9612,-434.4253,6.7661,1.8761},
{-2819.2588,-434.2224,6.7661,3.9896},
{-2823.5215,-441.6822,6.7661,3.4580},
{-2819.0369,-440.9862,6.7661,4.0346},
{-2822.8516,-448.9981,6.7661,7.3302},
{-2818.2061,-447.7987,6.7661,9.9531},
{-2820.7480,-456.4541,6.7661,20.0191},
{-2816.6711,-454.4347,6.7661,20.6467},
{-2817.3955,-463.4321,6.7661,33.4693},
{-2813.7688,-460.4954,6.7661,31.8096},
{-2812.2830,-469.7811,6.8356,46.6252},
{-2808.9436,-466.4615,6.8417,42.1020}
};

new g_Object[60];
new g_Pickup[2];
new ThreeWinner[3][MAX_PLAYER_NAME];
new bool:IsRaceStart;
new PlayerRaceTimer[MAX_PLAYERS];
new PlayerCheckTime[MAX_PLAYERS];
new bool:IsInRace[MAX_PLAYERS];
new bool:RacePlaceUse[14];
new RaceVehicles[MAX_VEHICLES];

//CPs
new Float:CheckPoints[159][3] =
{
{-2819.783,-398.911,6.766},
{-2809.968,-252.147,6.758},
{-2810.080,-225.016,6.758},
{-2794.481,-211.181,6.765},
{-2644.037,-211.783,3.889},
{-2605.936,-202.407,3.906},
{-2605.816,-181.893,3.906},
{-2612.862,-72.281,3.936},
{-2762.824,-69.563,6.861},
{-2809.610,-54.324,6.758},
{-2808.544,-34.176,6.767},
{-2808.079,-13.900,6.759},
{-2809.586,21.216,6.759},
{-2791.962,39.080,6.764},
{-2514.187,40.846,24.528},
{-2501.485,25.409,25.217},
{-2495.585,-71.188,25.284},
{-2344.810,-70.143,34.891},
{-2194.779,-70.182,34.899},
{-2044.122,-70.323,34.895},
{-2010.780,-60.937,34.896},
{-2006.482,12.679,32.920},
{-2024.180,28.823,33.375},
{-2107.160,43.043,34.891},
{-2106.622,73.367,34.891},
{-2105.858,95.616,34.891},
{-2120.015,111.003,34.900},
{-2150.456,120.943,34.896},
{-2148.517,140.975,34.898},
{-2146.512,167.034,34.898},
{-2148.205,221.273,34.898},
{-2136.215,318.486,34.888},
{-1988.034,344.208,34.617},
{-1878.934,367.942,22.763},
{-1876.119,387.952,18.374},
{-1867.623,406.948,16.744},
{-1818.817,492.369,26.417},
{-1917.438,604.859,34.743},
{-1998.778,597.280,34.774},
{-2116.668,504.444,34.742},
{-2229.343,489.635,34.743},
{-2253.935,341.613,33.600},
{-2262.293,319.931,34.957},
{-2400.340,257.083,27.458},
{-2515.275,162.980,3.902},
{-1550.646,854.280,6.763},
{-1699.558,850.754,24.461},
{-1716.607,887.708,24.468},
{-1692.472,922.648,24.466},
{-1543.459,936.569,6.766},
{-1529.301,961.379,6.774},
{-1588.902,1075.087,6.766},
{-1587.704,1109.483,6.766},
{-1607.894,1204.251,6.867},
{-1714.381,1181.824,24.703},
{-1790.326,1052.496,34.903},
{-1818.023,928.836,24.621},
{-1897.709,897.294,34.742},
{-1918.052,842.910,35.584},
{-2004.154,851.398,45.025},
{-2002.552,871.965,45.023},
{-2001.536,901.342,45.026},
{-2038.909,945.553,49.893},
{-2043.492,926.222,52.245},
{-2059.052,937.818,57.985},
{-2071.125,922.622,63.013},
{-2088.739,930.117,69.099},
{-2100.732,915.239,75.637},
{-2205.752,811.135,49.734},
{-2261.793,781.881,49.023},
{-2333.936,668.207,39.265},
{-2384.494,680.117,34.742},
{-2397.705,707.966,34.740},
{-2524.940,698.340,27.547},
{-2526.614,548.289,14.195},
{-2544.608,470.934,14.191},
{-2604.399,474.915,14.180},
{-2606.405,508.682,14.188},
{-2605.525,532.551,14.188},
{-2619.037,564.501,14.187},
{-2748.431,577.849,14.189},
{-2751.263,597.592,19.938},
{-2751.317,616.896,26.486},
{-2751.038,640.239,27.517},
{-2751.864,663.837,34.409},
{-2737.593,710.333,40.852},
{-2602.196,722.245,27.939},
{-2608.375,741.220,29.922},
{-2607.763,760.697,36.951},
{-2607.269,780.863,44.238},
{-2607.237,800.320,49.566},
{-2588.440,808.987,49.555},
{-2438.742,808.788,34.758},
{-2386.951,825.893,35.839},
{-2387.134,846.578,39.591},
{-2386.840,866.889,43.250},
{-2387.543,887.601,45.035},
{-2389.180,916.507,45.024},
{-2374.370,961.342,45.025},
{-2264.093,977.634,69.981},
{-2263.649,996.398,77.735},
{-2261.835,1015.659,83.355},
{-2141.989,1051.812,79.578},
{-2142.057,1072.123,79.572},
{-2141.202,1094.344,79.573},
{-2140.512,1114.171,76.182},
{-2136.590,1135.054,66.807},
{-2141.202,1162.380,55.732},
{-2123.782,1173.561,55.305},
{-1973.678,1178.306,45.024},
{-1969.577,1158.157,45.666},
{-1921.757,1076.451,49.276},
{-1888.479,1085.558,45.023},
{-1882.654,1135.954,45.023},
{-1884.286,1193.410,44.726},
{-1883.610,1213.465,39.296},
{-1813.030,1270.991,14.826},
{-1722.636,1300.601,6.769},
{-1730.122,1320.285,6.766},
{-1831.370,1357.048,6.765},
{-1965.259,1287.976,6.766},
{-2114.736,1273.396,18.491},
{-2259.656,1248.353,43.695},
{-2262.136,1102.384,80.395},
{-2261.132,953.020,66.199},
{-2265.061,804.366,49.023},
{-2385.620,782.456,34.748},
{-2386.178,632.208,34.159},
{-2404.503,564.596,24.468},
{-2525.650,554.373,14.196},
{-2547.135,469.858,14.191},
{-2696.775,466.217,3.840},
{-2846.741,470.903,3.845},
{-2698.665,1425.354,6.828},
{-2698.613,1296.335,6.859},
{-2562.500,1360.112,6.766},
{-2411.544,1375.003,6.766},
{-2264.432,1341.189,6.881},
{-2114.355,1329.725,6.766},
{-1964.401,1310.800,6.766},
{-1821.162,1357.624,6.769},
{-1693.904,1277.917,6.765},
{-1619.589,1186.826,6.811},
{-1768.902,1184.330,24.699},
{-1882.827,1160.853,45.024},
{-1920.489,1075.402,49.047},
{-2071.738,1076.356,55.294},
{-2224.531,1078.005,55.305},
{-2374.350,1096.843,55.307},
{-2524.050,1119.506,55.305},
{-2654.446,1195.754,55.157},
{-2677.200,1277.373,55.156},
{-2673.988,1318.617,55.156},
{-2674.625,1469.327,55.378},
{-2674.946,1619.605,64.859},
{-2675.255,1770.901,67.840},
{-2675.534,1922.283,64.319},
{-2675.554,1948.037,63.091},
{-2673.385,2036.146,57.420}
};

new Player_CheckPoint[MAX_PLAYERS];
new bool:IsRaceRunning = false;
new WinnerName[MAX_PLAYER_NAME];
new stringwin[64];

#if defined FILTERSCRIPT
// Init
public OnFilterScriptInit()
{
Create3DTextLabel("Welcome To FSFR!", 0x008080FF, -2821.2642, -443.1027, 7.0391, 40.0, 0, 0);
Create3DTextLabel("The BIG SF RACE,", 0x008080FF, -2821.2642, -444.1027, 7.0391, 40.0, 0, 0);
Create3DTextLabel("By Youssefree ,", 0xFFA200FF, -2821.2642, -445.1027, 7.0391, 40.0, 0, 0);
Create3DTextLabel("Winner Will Get 200000$,", 0x0A4DA4FF, -2821.2642, -446.1027, 7.0391, 40.0, 0, 0);

g_Object[0] = CreateObject(2904, -2805.5964, -468.5556, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[1] = CreateObject(620, -2809.3510, -474.8958, 6.2093, 0.0000, 0.0000, 0.0000); //veg_palm04
g_Object[2] = CreateObject(620, -2804.1604, -467.6058, 6.2093, 0.0000, 0.0000, 0.0000); //veg_palm04
g_Object[3] = CreateObject(2904, -2806.9382, -470.4234, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[4] = CreateObject(2904, -2808.3623, -472.4049, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[5] = CreateObject(2904, -2809.4892, -473.9722, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[6] = CreateObject(2904, -2805.5627, -468.5021, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[7] = CreateObject(2904, -2806.9458, -470.4124, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[8] = CreateObject(2904, -2808.1887, -472.1420, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[9] = CreateObject(2904, -2809.4628, -473.9122, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[10] = CreateObject(2878, -2807.7458, -471.7142, 7.3435, 0.0000, 0.0000, 53.9999); //CJ_Victim_DOOR
g_Object[11] = CreateObject(16500, -2812.0273, -473.1810, 8.1200, 0.0000, 0.0000, 44.6999); //cn2_savgardr1_
g_Object[12] = CreateObject(16500, -2815.4487, -469.6052, 8.1200, 0.0000, 0.0000, 42.8999); //cn2_savgardr1_
g_Object[13] = CreateObject(16500, -2815.4487, -469.6052, 8.1200, 0.0000, 0.0000, 42.8999); //cn2_savgardr1_
g_Object[14] = CreateObject(16500, -2818.4733, -465.7384, 8.1200, 0.0000, 0.0000, 33.8000); //cn2_savgardr1_
g_Object[15] = CreateObject(16500, -2821.0205, -461.5421, 8.1200, 0.0000, 0.0000, 28.8000); //cn2_savgardr1_
g_Object[16] = CreateObject(16500, -2822.9963, -457.0747, 8.1200, 0.0000, 0.0000, 18.9000); //cn2_savgardr1_
g_Object[17] = CreateObject(16500, -2824.3903, -452.3598, 8.1200, 0.0000, 0.0000, 14.0000); //cn2_savgardr1_
g_Object[18] = CreateObject(16500, -2825.3864, -447.5438, 8.1200, 0.0000, 0.0000, 9.3000); //cn2_savgardr1_
g_Object[19] = CreateObject(16500, -2825.9365, -442.6497, 8.1200, 0.0000, 0.0000, 3.6000); //cn2_savgardr1_
g_Object[20] = CreateObject(16500, -2826.2458, -437.7394, 8.1200, 0.0000, 0.0000, 3.6000); //cn2_savgardr1_
g_Object[21] = CreateObject(16500, -2826.5556, -432.8391, 8.1200, 0.0000, 0.0000, 3.6000); //cn2_savgardr1_
g_Object[22] = CreateObject(16500, -2826.7548, -427.9270, 8.1200, 0.0000, 0.0000, 1.0000); //cn2_savgardr1_
g_Object[23] = CreateObject(16500, -2826.8383, -422.9877, 8.1200, 0.0000, 0.0000, 1.0000); //cn2_savgardr1_
g_Object[24] = CreateObject(16500, -2826.9233, -418.0583, 8.1200, 0.0000, 0.0000, 1.0000); //cn2_savgardr1_
g_Object[25] = CreateObject(16500, -2806.5844, -465.7168, 8.1200, 0.0000, 0.0000, 42.0999); //cn2_savgardr1_
g_Object[26] = CreateObject(16500, -2809.7097, -461.9146, 8.1200, 0.0000, 0.0000, 36.5999); //cn2_savgardr1_
g_Object[27] = CreateObject(16500, -2812.4201, -457.8130, 8.1200, 0.0000, 0.0000, 30.1999); //cn2_savgardr1_
g_Object[28] = CreateObject(16500, -2814.4536, -453.3471, 8.1200, 0.0000, 0.0000, 18.7999); //cn2_savgardr1_
g_Object[29] = CreateObject(16500, -2815.7155, -448.6064, 8.1200, 0.0000, 0.0000, 10.9999); //cn2_savgardr1_
g_Object[30] = CreateObject(16500, -2816.3852, -443.7413, 8.1200, 0.0000, 0.0000, 4.4999); //cn2_savgardr1_
g_Object[31] = CreateObject(16500, -2816.7724, -438.8165, 8.1200, 0.0000, 0.0000, 3.5999); //cn2_savgardr1_
g_Object[32] = CreateObject(16500, -2817.0820, -433.8965, 8.1200, 0.0000, 0.0000, 3.5999); //cn2_savgardr1_
g_Object[33] = CreateObject(16500, -2817.3225, -428.9743, 8.1200, 0.0000, 0.0000, 1.4999); //cn2_savgardr1_
g_Object[34] = CreateObject(16500, -2817.4011, -424.0357, 8.1200, 0.0000, 0.0000, 0.1999); //cn2_savgardr1_
g_Object[35] = CreateObject(16500, -2817.4162, -419.0958, 8.1200, 0.0000, 0.0000, 0.1999); //cn2_savgardr1_
g_Object[36] = CreateObject(16500, -2817.4196, -417.5459, 8.1200, 0.0000, 0.0000, 0.1999); //cn2_savgardr1_
g_Object[37] = CreateObject(11431, -2809.4099, -479.3891, 7.6007, 0.0000, 0.0000, -37.0999); //des_tepeoff01
g_Object[38] = CreateObject(7073, -2809.9130, -480.1479, 27.0409, 2.3000, 0.0000, 6.6999); //vegascowboy1
g_Object[39] = CreateObject(3749, -2822.1730, -414.8966, 11.9603, 0.0000, 0.0000, 0.0000); //ClubGate01_LAx
g_Object[40] = CreateObject(16500, -2815.1440, -414.2999, 8.1200, 0.0000, 0.0000, -70.4001); //cn2_savgardr1_
g_Object[41] = CreateObject(16500, -2829.0209, -414.3475, 8.1200, 0.0000, 0.0000, -121.9000); //cn2_savgardr1_
g_Object[42] = CreateObject(980, -2821.9953, -414.1422, 8.8947, 0.0000, 0.0000, 0.0000); //airportgate
g_Object[43] = CreateObject(18647, -2811.7165, -463.4261, 5.8051, 0.0000, 0.0000, -47.5999); //RedNeonTube1
g_Object[44] = CreateObject(18647, -2815.4831, -467.1696, 5.7951, 0.0000, 0.0000, -40.2999); //RedNeonTube1
g_Object[45] = CreateObject(18648, -2815.7639, -457.3795, 6.1944, 0.0000, 0.0000, -60.8999); //BlueNeonTube1
g_Object[46] = CreateObject(18648, -2819.6264, -459.5291, 6.1944, 0.0000, 0.0000, -60.8999); //BlueNeonTube1
g_Object[47] = CreateObject(18650, -2823.2763, -445.4010, 6.2068, 0.0000, 0.0000, -83.0000); //YellowNeonTube1
g_Object[48] = CreateObject(18649, -2817.9553, -450.8033, 6.2660, -0.6999, 0.0000, -73.9999); //GreenNeonTube1
g_Object[49] = CreateObject(18649, -2822.0620, -452.3346, 6.3194, -0.6999, 0.0000, -73.9999); //GreenNeonTube1
g_Object[50] = CreateObject(18650, -2818.8627, -444.4053, 6.2068, 0.0000, 0.0000, -83.0000); //YellowNeonTube1
g_Object[51] = CreateObject(18651, -2819.3071, -437.3047, 6.3310, 0.0000, 0.0000, -84.1999); //PinkNeonTube1
g_Object[52] = CreateObject(18651, -2823.9138, -437.7725, 6.3310, 0.0000, 0.0000, -84.1999); //PinkNeonTube1
g_Object[53] = CreateObject(18652, -2824.2817, -431.1313, 6.4255, 0.0000, 0.0000, 95.4000); //WhiteNeonTube1
g_Object[54] = CreateObject(18652, -2819.7119, -430.6991, 6.4255, 0.0000, 0.0000, 92.9000); //WhiteNeonTube1
g_Object[55] = CreateObject(18647, -2818.6191, -423.3435, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1
g_Object[56] = CreateObject(18647, -2820.7727, -423.5280, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1
g_Object[57] = CreateObject(18647, -2822.9631, -423.7160, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1
g_Object[58] = CreateObject(18647, -2825.2641, -423.9133, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1

g_Pickup[0] = CreatePickup(1313, 1, -2807.0219, -471.4404, 7.1375, -1); //killfrenzy2plyr
g_Pickup[1] = CreatePickup(1314, 1, -2807.3757, -478.2558, 7.6394, -1); //twoplayer
}

public OnPlayerCommandText()
{
if(!strcmp(cmdtext,"/joinrace",true))
{
GivePlayerMoney(playerid, -10000);
SendClientMessage(playerid, COLOR_RED, "You paid 10,000$ due to tax and skills reasons :3");
if(!IsPlayerInRangeOfPoint(playerid,4.0,-2807.7458, -471.7142, 7.3435))return SendClientMessage(playerid,-1,"You aren't in range of the vicitim door!");
if(IsInRace[playerid] == true)return SendClientMessage(playerid,-1,"You already joined the race!");
IsInRace[playerid] = true;
new veh_index;
for(new i;i<sizeof(RaceVehicles);i++)
{
if(RaceVehicles[i] > 0)continue;
veh_index = i;
break;
}
for(new i;i<sizeof(PlaceInfo);i++)
{
if(RacePlaceUse[i] == true)continue;
RacePlaceUse[i] = true;
RaceVehicles[veh_index] = CreateVehicle(411,PlaceInfo[i][Pos_X],PlaceInfo[i][Pos_Y],PlaceInfo[i][Pos_Z],PlaceInfo[i][Pos_A],-1,-1,-1);
SetVehicleHealth(RaceVehicles[veh_index],100000);
PutPlayerInVehicle(playerid,RaceVehicles[veh_index],0);
TogglePlayerControllable(playerid,0);
break;
}
SendClientMessageToAll(-1,"Join the race! (/joinrace)");
return 1;
}
else if(!strcmp(cmdtext,"/startrace",true))
{
if(!IsPlayerAdmin(playerid))return SendClientMessage(playerid,-1,"You have to log in RCON!");
if(IsRaceStart == true)return SendClientMessage(playerid,-1,"The race is already started!");
IsRaceStart = true;
MoveObject(g_Object[42],-2821.9953, -414.1422, -10.8947,9.0);//When it's to slowly, then increase 2.0 - lower when it's the other way around
SendClientMessageToAll(-1,"The race starts!!!!!");
for(new i;i<MAX_PLAYERS;i++)
{
if(IsInRace[i] == true)
{
TogglePlayerControllable(i,1);
PlayerRaceTimer[i] = SetTimerEx("RaceTimer",1000,1,"i",i);
PlayerCheckTime[i] = gettime()+20;
}
}
return 1;
}
return 0;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
if(IsRaceRunning == true)
{
DisablePlayerRaceCheckpoint(playerid);
Player_CheckPoint[playerid] ++;
if(Player_CheckPoint[playerid] < 158)
{
PlayerCheckTime[playerid] = gettime()+20;
SetPlayerRaceCheckpoint(playerid,0,CheckPoints[Player_CheckPoint[playerid]][0],CheckPoints[Player_CheckPoint[playerid]][1],CheckPoints[Player_CheckPoint[playerid]][2],CheckPoints[Player_CheckPoint[playerid]+1][0],CheckPoints[Player_CheckPoint[playerid]+1][1],CheckPoints[Player_CheckPoint[playerid]+1][2],9.7);
}
else if(Player_CheckPoint[playerid] == 158)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsInRace[i] == true)
{
DisablePlayerRaceCheckpoint(i);
SetPlayerPos(i,-2804.5796,-472.9876,7.1875);// CoorDs Outside
IsInRace[i] = false;
}
}
for(new i;i<sizeof(RaceVehicles);i++)
{
if(RaceVehicles[i] == GetPlayerVehicleID(playerid))
{
DestroyVehicle(RaceVehicles[i]);
RaceVehicles[i] = 0;
}
}
GetPlayerName(playerid,WinnerName,sizeof(WinnerNam e));
if(!strlen(ThreeWinner[0]))format(ThreeName[0],MAX_PLAYER_NAME,WinnerName);
else if(!strlen(ThreeWinner[1]))format(ThreeName[1],MAX_PLAYER_NAME,WinnerName);
else if(!strlen(ThreeWinner[2]))format(ThreeName[2],MAX_PLAYER_NAME,WinnerName);
format(stringwin,sizeof(stringwin),"[RACE] The race is over, %s has won and achieved $%d!",ThreeWinner[0],winner_money);
SendClientMessageToAll(0xFF0000FF,stringwin);
GivePlayerMoney(GetIDofName(ThreeWinner[0]),10000);
GivePlayerMoney(GetIDofName(ThreeWinner[1]),9000);
GivePlayerMoney(GetIDofName(ThreeWinner[2]),8000);
IsRaceStart = false;
return 1;
}
}
return 1;
}
public OnPlayerConnect(playerid)
{
// Credits and Start Place
Player_CheckPoint[playerid] = 0;
SetPlayerRaceCheckpoint(playerid,0,CheckPoints[0][0],CheckPoints[0][1],CheckPoints[0][2],CheckPoints[1][0],CheckPoints[1][1],CheckPoints[1][2],9.7);
IsRaceRunning = true;
return 1;
}

forward RaceTimer(playerid);
public RaceTimer(playerid)
{
if(gettime() > PlayerCheckTime[playerid])
{
for(new i;i<sizeof(RaceVehicles);i++)
{
if(RacesVehicles[i] == GetPlayerVehicleID(playerid))
{
RacesVehicles[i] = 0;
break;
}
}
DestroyVehicle(GetPlayerVehicleID(playerid));
IsInRace[playerid] = false;
KillTimer(PlayerRaceTimer[playerid]);
SetPlayerPos(playerid,-2804.5796,-472.9876,7.1875);//CoorDs Outside
}
return 1;
}

stock GetIDofName(name_[])
{
new get_name[MAX_PLAYER_NAME];
for(new i;i<MAX_PLAYERS;i++)
{
if(!GetPlayerName(i,get_name,MAX_PLAYER_NAME))retu rn -1;
if(!strcmp(get_name,name_,false))return i;
}
return -1;
}

Youssefree
09/07/2016, 12:33 PM
So. Try this:

#define winner_money 100000
............
return -1;
}

D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(32) : error 017: undefined symbol "MAX_PLAYER_NAME"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(34) : error 017: undefined symbol "MAX_PLAYERS"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(35) : error 017: undefined symbol "MAX_PLAYERS"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(36) : error 017: undefined symbol "MAX_PLAYERS"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(38) : error 017: undefined symbol "MAX_VEHICLES"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(204) : error 017: undefined symbol "MAX_PLAYERS"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(206) : error 017: undefined symbol "MAX_PLAYER_NAME"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : error 001: expected token: "#endif", but found "-end of file-"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "CheckPoints"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "IsInRace"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "IsRaceRunning"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "IsRaceStart"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "PlaceInfo"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "PlayerCheckTime"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "PlayerRaceTimer"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "Player_CheckPoint"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "RacePlaceUse"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "RaceVehicles"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "ThreeWinner"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "WinnerName"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "g_Object"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "g_Pickup"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : warning 203: symbol is never used: "stringwin"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(417) : error 013: no entry point (no public functions)
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


9 Errors.

Mencent
09/07/2016, 01:34 PM
You have to put this at the top of the script:
/* 01011001 01101111 01110101 01110011 01110011
01100101 01100110 01110010 01100101 01100101
*FSFR - Full San Fierro Race by Youssefree* */

#include <a_samp>

#define FILTERSCRIPT

Youssefree
09/07/2016, 01:45 PM
You have to put this at the top of the script:
/* 01011001 01101111 01110101 01110011 01110011
01100101 01100110 01110010 01100101 01100101
*FSFR - Full San Fierro Race by Youssefree* */

#include <a_samp>

#define FILTERSCRIPT

D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(292) : error 017: undefined symbol "cmdtext"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(294) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(295) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(296) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(296) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(297) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(297) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(298) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(312) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(313) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(319) : error 017: undefined symbol "cmdtext"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(321) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(321) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(322) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : error 017: undefined symbol "ThreeName"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : warning 215: expression has no effect
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : error 001: expected token: ";", but found "]"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : error 029: invalid expression, assumed zero
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


18 Errors.

Youssefree
09/07/2016, 01:49 PM
:'( !

Mencent
09/07/2016, 02:03 PM
Can you send me your currently code? ;)

Youssefree
09/07/2016, 02:22 PM
Can you send me your currently code? ;)

/* 01011001 01101111 01110101 01110011 01110011
01100101 01100110 01110010 01100101 01100101
*FSFR - Full San Fierro Race by Youssefree* */

#include <a_samp>

#define FILTERSCRIPT

#define winner_money 100000
#define COLOR_RED 0xFF0000FF

enum RacePlaces
{
Float:Pos_X,
Float:Pos_Y,
Float:Pos_Z,
Float:Pos_A
};

new Float:PlaceInfo[14][RacePlaces] =
{
{-2824.0039,-427.6653,6.7661,2.2123},
{-2819.6379,-427.0293,6.7661,4.8471},
{-2823.9612,-434.4253,6.7661,1.8761},
{-2819.2588,-434.2224,6.7661,3.9896},
{-2823.5215,-441.6822,6.7661,3.4580},
{-2819.0369,-440.9862,6.7661,4.0346},
{-2822.8516,-448.9981,6.7661,7.3302},
{-2818.2061,-447.7987,6.7661,9.9531},
{-2820.7480,-456.4541,6.7661,20.0191},
{-2816.6711,-454.4347,6.7661,20.6467},
{-2817.3955,-463.4321,6.7661,33.4693},
{-2813.7688,-460.4954,6.7661,31.8096},
{-2812.2830,-469.7811,6.8356,46.6252},
{-2808.9436,-466.4615,6.8417,42.1020}
};

new g_Object[60];
new g_Pickup[2];
new ThreeWinner[3][MAX_PLAYER_NAME];
new bool:IsRaceStart;
new PlayerRaceTimer[MAX_PLAYERS];
new PlayerCheckTime[MAX_PLAYERS];
new bool:IsInRace[MAX_PLAYERS];
new bool:RacePlaceUse[14];
new RaceVehicles[MAX_VEHICLES];

//CPs
new Float:CheckPoints[159][3] =
{
{-2819.783,-398.911,6.766},
{-2809.968,-252.147,6.758},
{-2810.080,-225.016,6.758},
{-2794.481,-211.181,6.765},
{-2644.037,-211.783,3.889},
{-2605.936,-202.407,3.906},
{-2605.816,-181.893,3.906},
{-2612.862,-72.281,3.936},
{-2762.824,-69.563,6.861},
{-2809.610,-54.324,6.758},
{-2808.544,-34.176,6.767},
{-2808.079,-13.900,6.759},
{-2809.586,21.216,6.759},
{-2791.962,39.080,6.764},
{-2514.187,40.846,24.528},
{-2501.485,25.409,25.217},
{-2495.585,-71.188,25.284},
{-2344.810,-70.143,34.891},
{-2194.779,-70.182,34.899},
{-2044.122,-70.323,34.895},
{-2010.780,-60.937,34.896},
{-2006.482,12.679,32.920},
{-2024.180,28.823,33.375},
{-2107.160,43.043,34.891},
{-2106.622,73.367,34.891},
{-2105.858,95.616,34.891},
{-2120.015,111.003,34.900},
{-2150.456,120.943,34.896},
{-2148.517,140.975,34.898},
{-2146.512,167.034,34.898},
{-2148.205,221.273,34.898},
{-2136.215,318.486,34.888},
{-1988.034,344.208,34.617},
{-1878.934,367.942,22.763},
{-1876.119,387.952,18.374},
{-1867.623,406.948,16.744},
{-1818.817,492.369,26.417},
{-1917.438,604.859,34.743},
{-1998.778,597.280,34.774},
{-2116.668,504.444,34.742},
{-2229.343,489.635,34.743},
{-2253.935,341.613,33.600},
{-2262.293,319.931,34.957},
{-2400.340,257.083,27.458},
{-2515.275,162.980,3.902},
{-1550.646,854.280,6.763},
{-1699.558,850.754,24.461},
{-1716.607,887.708,24.468},
{-1692.472,922.648,24.466},
{-1543.459,936.569,6.766},
{-1529.301,961.379,6.774},
{-1588.902,1075.087,6.766},
{-1587.704,1109.483,6.766},
{-1607.894,1204.251,6.867},
{-1714.381,1181.824,24.703},
{-1790.326,1052.496,34.903},
{-1818.023,928.836,24.621},
{-1897.709,897.294,34.742},
{-1918.052,842.910,35.584},
{-2004.154,851.398,45.025},
{-2002.552,871.965,45.023},
{-2001.536,901.342,45.026},
{-2038.909,945.553,49.893},
{-2043.492,926.222,52.245},
{-2059.052,937.818,57.985},
{-2071.125,922.622,63.013},
{-2088.739,930.117,69.099},
{-2100.732,915.239,75.637},
{-2205.752,811.135,49.734},
{-2261.793,781.881,49.023},
{-2333.936,668.207,39.265},
{-2384.494,680.117,34.742},
{-2397.705,707.966,34.740},
{-2524.940,698.340,27.547},
{-2526.614,548.289,14.195},
{-2544.608,470.934,14.191},
{-2604.399,474.915,14.180},
{-2606.405,508.682,14.188},
{-2605.525,532.551,14.188},
{-2619.037,564.501,14.187},
{-2748.431,577.849,14.189},
{-2751.263,597.592,19.938},
{-2751.317,616.896,26.486},
{-2751.038,640.239,27.517},
{-2751.864,663.837,34.409},
{-2737.593,710.333,40.852},
{-2602.196,722.245,27.939},
{-2608.375,741.220,29.922},
{-2607.763,760.697,36.951},
{-2607.269,780.863,44.238},
{-2607.237,800.320,49.566},
{-2588.440,808.987,49.555},
{-2438.742,808.788,34.758},
{-2386.951,825.893,35.839},
{-2387.134,846.578,39.591},
{-2386.840,866.889,43.250},
{-2387.543,887.601,45.035},
{-2389.180,916.507,45.024},
{-2374.370,961.342,45.025},
{-2264.093,977.634,69.981},
{-2263.649,996.398,77.735},
{-2261.835,1015.659,83.355},
{-2141.989,1051.812,79.578},
{-2142.057,1072.123,79.572},
{-2141.202,1094.344,79.573},
{-2140.512,1114.171,76.182},
{-2136.590,1135.054,66.807},
{-2141.202,1162.380,55.732},
{-2123.782,1173.561,55.305},
{-1973.678,1178.306,45.024},
{-1969.577,1158.157,45.666},
{-1921.757,1076.451,49.276},
{-1888.479,1085.558,45.023},
{-1882.654,1135.954,45.023},
{-1884.286,1193.410,44.726},
{-1883.610,1213.465,39.296},
{-1813.030,1270.991,14.826},
{-1722.636,1300.601,6.769},
{-1730.122,1320.285,6.766},
{-1831.370,1357.048,6.765},
{-1965.259,1287.976,6.766},
{-2114.736,1273.396,18.491},
{-2259.656,1248.353,43.695},
{-2262.136,1102.384,80.395},
{-2261.132,953.020,66.199},
{-2265.061,804.366,49.023},
{-2385.620,782.456,34.748},
{-2386.178,632.208,34.159},
{-2404.503,564.596,24.468},
{-2525.650,554.373,14.196},
{-2547.135,469.858,14.191},
{-2696.775,466.217,3.840},
{-2846.741,470.903,3.845},
{-2698.665,1425.354,6.828},
{-2698.613,1296.335,6.859},
{-2562.500,1360.112,6.766},
{-2411.544,1375.003,6.766},
{-2264.432,1341.189,6.881},
{-2114.355,1329.725,6.766},
{-1964.401,1310.800,6.766},
{-1821.162,1357.624,6.769},
{-1693.904,1277.917,6.765},
{-1619.589,1186.826,6.811},
{-1768.902,1184.330,24.699},
{-1882.827,1160.853,45.024},
{-1920.489,1075.402,49.047},
{-2071.738,1076.356,55.294},
{-2224.531,1078.005,55.305},
{-2374.350,1096.843,55.307},
{-2524.050,1119.506,55.305},
{-2654.446,1195.754,55.157},
{-2677.200,1277.373,55.156},
{-2673.988,1318.617,55.156},
{-2674.625,1469.327,55.378},
{-2674.946,1619.605,64.859},
{-2675.255,1770.901,67.840},
{-2675.534,1922.283,64.319},
{-2675.554,1948.037,63.091},
{-2673.385,2036.146,57.420}
};

new Player_CheckPoint[MAX_PLAYERS];
new bool:IsRaceRunning = false;
new WinnerName[MAX_PLAYER_NAME];
new stringwin[64];

#if defined FILTERSCRIPT
// Init
public OnFilterScriptInit()
{
Create3DTextLabel("Welcome To FSFR!", 0x008080FF, -2821.2642, -443.1027, 7.0391, 40.0, 0, 0);
Create3DTextLabel("The BIG SF RACE,", 0x008080FF, -2821.2642, -444.1027, 7.0391, 40.0, 0, 0);
Create3DTextLabel("By Youssefree ,", 0xFFA200FF, -2821.2642, -445.1027, 7.0391, 40.0, 0, 0);
Create3DTextLabel("Winner Will Get 200000$,", 0x0A4DA4FF, -2821.2642, -446.1027, 7.0391, 40.0, 0, 0);

g_Object[0] = CreateObject(2904, -2805.5964, -468.5556, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[1] = CreateObject(620, -2809.3510, -474.8958, 6.2093, 0.0000, 0.0000, 0.0000); //veg_palm04
g_Object[2] = CreateObject(620, -2804.1604, -467.6058, 6.2093, 0.0000, 0.0000, 0.0000); //veg_palm04
g_Object[3] = CreateObject(2904, -2806.9382, -470.4234, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[4] = CreateObject(2904, -2808.3623, -472.4049, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[5] = CreateObject(2904, -2809.4892, -473.9722, 7.4607, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[6] = CreateObject(2904, -2805.5627, -468.5021, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[7] = CreateObject(2904, -2806.9458, -470.4124, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[8] = CreateObject(2904, -2808.1887, -472.1420, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[9] = CreateObject(2904, -2809.4628, -473.9122, 9.2606, 0.0000, 0.0000, 54.2999); //warehouse_door1
g_Object[10] = CreateObject(2878, -2807.7458, -471.7142, 7.3435, 0.0000, 0.0000, 53.9999); //CJ_Victim_DOOR
g_Object[11] = CreateObject(16500, -2812.0273, -473.1810, 8.1200, 0.0000, 0.0000, 44.6999); //cn2_savgardr1_
g_Object[12] = CreateObject(16500, -2815.4487, -469.6052, 8.1200, 0.0000, 0.0000, 42.8999); //cn2_savgardr1_
g_Object[13] = CreateObject(16500, -2815.4487, -469.6052, 8.1200, 0.0000, 0.0000, 42.8999); //cn2_savgardr1_
g_Object[14] = CreateObject(16500, -2818.4733, -465.7384, 8.1200, 0.0000, 0.0000, 33.8000); //cn2_savgardr1_
g_Object[15] = CreateObject(16500, -2821.0205, -461.5421, 8.1200, 0.0000, 0.0000, 28.8000); //cn2_savgardr1_
g_Object[16] = CreateObject(16500, -2822.9963, -457.0747, 8.1200, 0.0000, 0.0000, 18.9000); //cn2_savgardr1_
g_Object[17] = CreateObject(16500, -2824.3903, -452.3598, 8.1200, 0.0000, 0.0000, 14.0000); //cn2_savgardr1_
g_Object[18] = CreateObject(16500, -2825.3864, -447.5438, 8.1200, 0.0000, 0.0000, 9.3000); //cn2_savgardr1_
g_Object[19] = CreateObject(16500, -2825.9365, -442.6497, 8.1200, 0.0000, 0.0000, 3.6000); //cn2_savgardr1_
g_Object[20] = CreateObject(16500, -2826.2458, -437.7394, 8.1200, 0.0000, 0.0000, 3.6000); //cn2_savgardr1_
g_Object[21] = CreateObject(16500, -2826.5556, -432.8391, 8.1200, 0.0000, 0.0000, 3.6000); //cn2_savgardr1_
g_Object[22] = CreateObject(16500, -2826.7548, -427.9270, 8.1200, 0.0000, 0.0000, 1.0000); //cn2_savgardr1_
g_Object[23] = CreateObject(16500, -2826.8383, -422.9877, 8.1200, 0.0000, 0.0000, 1.0000); //cn2_savgardr1_
g_Object[24] = CreateObject(16500, -2826.9233, -418.0583, 8.1200, 0.0000, 0.0000, 1.0000); //cn2_savgardr1_
g_Object[25] = CreateObject(16500, -2806.5844, -465.7168, 8.1200, 0.0000, 0.0000, 42.0999); //cn2_savgardr1_
g_Object[26] = CreateObject(16500, -2809.7097, -461.9146, 8.1200, 0.0000, 0.0000, 36.5999); //cn2_savgardr1_
g_Object[27] = CreateObject(16500, -2812.4201, -457.8130, 8.1200, 0.0000, 0.0000, 30.1999); //cn2_savgardr1_
g_Object[28] = CreateObject(16500, -2814.4536, -453.3471, 8.1200, 0.0000, 0.0000, 18.7999); //cn2_savgardr1_
g_Object[29] = CreateObject(16500, -2815.7155, -448.6064, 8.1200, 0.0000, 0.0000, 10.9999); //cn2_savgardr1_
g_Object[30] = CreateObject(16500, -2816.3852, -443.7413, 8.1200, 0.0000, 0.0000, 4.4999); //cn2_savgardr1_
g_Object[31] = CreateObject(16500, -2816.7724, -438.8165, 8.1200, 0.0000, 0.0000, 3.5999); //cn2_savgardr1_
g_Object[32] = CreateObject(16500, -2817.0820, -433.8965, 8.1200, 0.0000, 0.0000, 3.5999); //cn2_savgardr1_
g_Object[33] = CreateObject(16500, -2817.3225, -428.9743, 8.1200, 0.0000, 0.0000, 1.4999); //cn2_savgardr1_
g_Object[34] = CreateObject(16500, -2817.4011, -424.0357, 8.1200, 0.0000, 0.0000, 0.1999); //cn2_savgardr1_
g_Object[35] = CreateObject(16500, -2817.4162, -419.0958, 8.1200, 0.0000, 0.0000, 0.1999); //cn2_savgardr1_
g_Object[36] = CreateObject(16500, -2817.4196, -417.5459, 8.1200, 0.0000, 0.0000, 0.1999); //cn2_savgardr1_
g_Object[37] = CreateObject(11431, -2809.4099, -479.3891, 7.6007, 0.0000, 0.0000, -37.0999); //des_tepeoff01
g_Object[38] = CreateObject(7073, -2809.9130, -480.1479, 27.0409, 2.3000, 0.0000, 6.6999); //vegascowboy1
g_Object[39] = CreateObject(3749, -2822.1730, -414.8966, 11.9603, 0.0000, 0.0000, 0.0000); //ClubGate01_LAx
g_Object[40] = CreateObject(16500, -2815.1440, -414.2999, 8.1200, 0.0000, 0.0000, -70.4001); //cn2_savgardr1_
g_Object[41] = CreateObject(16500, -2829.0209, -414.3475, 8.1200, 0.0000, 0.0000, -121.9000); //cn2_savgardr1_
g_Object[42] = CreateObject(980, -2821.9953, -414.1422, 8.8947, 0.0000, 0.0000, 0.0000); //airportgate
g_Object[43] = CreateObject(18647, -2811.7165, -463.4261, 5.8051, 0.0000, 0.0000, -47.5999); //RedNeonTube1
g_Object[44] = CreateObject(18647, -2815.4831, -467.1696, 5.7951, 0.0000, 0.0000, -40.2999); //RedNeonTube1
g_Object[45] = CreateObject(18648, -2815.7639, -457.3795, 6.1944, 0.0000, 0.0000, -60.8999); //BlueNeonTube1
g_Object[46] = CreateObject(18648, -2819.6264, -459.5291, 6.1944, 0.0000, 0.0000, -60.8999); //BlueNeonTube1
g_Object[47] = CreateObject(18650, -2823.2763, -445.4010, 6.2068, 0.0000, 0.0000, -83.0000); //YellowNeonTube1
g_Object[48] = CreateObject(18649, -2817.9553, -450.8033, 6.2660, -0.6999, 0.0000, -73.9999); //GreenNeonTube1
g_Object[49] = CreateObject(18649, -2822.0620, -452.3346, 6.3194, -0.6999, 0.0000, -73.9999); //GreenNeonTube1
g_Object[50] = CreateObject(18650, -2818.8627, -444.4053, 6.2068, 0.0000, 0.0000, -83.0000); //YellowNeonTube1
g_Object[51] = CreateObject(18651, -2819.3071, -437.3047, 6.3310, 0.0000, 0.0000, -84.1999); //PinkNeonTube1
g_Object[52] = CreateObject(18651, -2823.9138, -437.7725, 6.3310, 0.0000, 0.0000, -84.1999); //PinkNeonTube1
g_Object[53] = CreateObject(18652, -2824.2817, -431.1313, 6.4255, 0.0000, 0.0000, 95.4000); //WhiteNeonTube1
g_Object[54] = CreateObject(18652, -2819.7119, -430.6991, 6.4255, 0.0000, 0.0000, 92.9000); //WhiteNeonTube1
g_Object[55] = CreateObject(18647, -2818.6191, -423.3435, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1
g_Object[56] = CreateObject(18647, -2820.7727, -423.5280, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1
g_Object[57] = CreateObject(18647, -2822.9631, -423.7160, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1
g_Object[58] = CreateObject(18647, -2825.2641, -423.9133, 6.2353, 0.0000, 0.0000, -85.0999); //RedNeonTube1

g_Pickup[0] = CreatePickup(1313, 1, -2807.0219, -471.4404, 7.1375, -1); //killfrenzy2plyr
g_Pickup[1] = CreatePickup(1314, 1, -2807.3757, -478.2558, 7.6394, -1); //twoplayer
}

public OnPlayerCommandText()
{
if(!strcmp(cmdtext,"/joinrace",true))
{
GivePlayerMoney(playerid, -10000);
SendClientMessage(playerid, COLOR_RED, "You paid 10,000$ due to tax and skills reasons :3");
if(!IsPlayerInRangeOfPoint(playerid,4.0,-2807.7458, -471.7142, 7.3435))return SendClientMessage(playerid,-1,"You aren't in range of the vicitim door!");
if(IsInRace[playerid] == true)return SendClientMessage(playerid,-1,"You already joined the race!");
IsInRace[playerid] = true;
new veh_index;
for(new i;i<sizeof(RaceVehicles);i++)
{
if(RaceVehicles[i] > 0)continue;
veh_index = i;
break;
}
for(new i;i<sizeof(PlaceInfo);i++)
{
if(RacePlaceUse[i] == true)continue;
RacePlaceUse[i] = true;
RaceVehicles[veh_index] = CreateVehicle(411,PlaceInfo[i][Pos_X],PlaceInfo[i][Pos_Y],PlaceInfo[i][Pos_Z],PlaceInfo[i][Pos_A],-1,-1,-1);
SetVehicleHealth(RaceVehicles[veh_index],100000);
PutPlayerInVehicle(playerid,RaceVehicles[veh_index],0);
TogglePlayerControllable(playerid,0);
break;
}
SendClientMessageToAll(-1,"Join the race! (/joinrace)");
return 1;
}
else if(!strcmp(cmdtext,"/startrace",true))
{
if(!IsPlayerAdmin(playerid))return SendClientMessage(playerid,-1,"You have to log in RCON!");
if(IsRaceStart == true)return SendClientMessage(playerid,-1,"The race is already started!");
IsRaceStart = true;
MoveObject(g_Object[42],-2821.9953, -414.1422, -10.8947,9.0);//When it's to slowly, then increase 2.0 - lower when it's the other way around
SendClientMessageToAll(-1,"The race starts!!!!!");
for(new i;i<MAX_PLAYERS;i++)
{
if(IsInRace[i] == true)
{
TogglePlayerControllable(i,1);
PlayerRaceTimer[i] = SetTimerEx("RaceTimer",1000,1,"i",i);
PlayerCheckTime[i] = gettime()+20;
}
}
return 1;
}
return 0;
}

public OnPlayerEnterRaceCheckpoint(playerid)
{
if(IsRaceRunning == true)
{
DisablePlayerRaceCheckpoint(playerid);
Player_CheckPoint[playerid] ++;
if(Player_CheckPoint[playerid] < 158)
{
PlayerCheckTime[playerid] = gettime()+20;
SetPlayerRaceCheckpoint(playerid,0,CheckPoints[Player_CheckPoint[playerid]][0],CheckPoints[Player_CheckPoint[playerid]][1],CheckPoints[Player_CheckPoint[playerid]][2],CheckPoints[Player_CheckPoint[playerid]+1][0],CheckPoints[Player_CheckPoint[playerid]+1][1],CheckPoints[Player_CheckPoint[playerid]+1][2],9.7);
}
else if(Player_CheckPoint[playerid] == 158)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsInRace[i] == true)
{
DisablePlayerRaceCheckpoint(i);
SetPlayerPos(i,-2804.5796,-472.9876,7.1875);// CoorDs Outside
IsInRace[i] = false;
}
}
for(new i;i<sizeof(RaceVehicles);i++)
{
if(RaceVehicles[i] == GetPlayerVehicleID(playerid))
{
DestroyVehicle(RaceVehicles[i]);
RaceVehicles[i] = 0;
}
}
GetPlayerName(playerid,WinnerName,sizeof(WinnerNam e));
if(!strlen(ThreeWinner[0]))format(ThreeName[0],MAX_PLAYER_NAME,WinnerName);
else if(!strlen(ThreeWinner[1]))format(ThreeName[1],MAX_PLAYER_NAME,WinnerName);
else if(!strlen(ThreeWinner[2]))format(ThreeName[2],MAX_PLAYER_NAME,WinnerName);
format(stringwin,sizeof(stringwin),"[RACE] The race is over, %s has won and achieved $%d!",ThreeWinner[0],winner_money);
SendClientMessageToAll(0xFF0000FF,stringwin);
GivePlayerMoney(GetIDofName(ThreeWinner[0]),10000);
GivePlayerMoney(GetIDofName(ThreeWinner[1]),9000);
GivePlayerMoney(GetIDofName(ThreeWinner[2]),8000);
IsRaceStart = false;
return 1;
}
}
return 1;
}
public OnPlayerConnect(playerid)
{
// Credits and Start Place
Player_CheckPoint[playerid] = 0;
SetPlayerRaceCheckpoint(playerid,0,CheckPoints[0][0],CheckPoints[0][1],CheckPoints[0][2],CheckPoints[1][0],CheckPoints[1][1],CheckPoints[1][2],9.7);
IsRaceRunning = true;
return 1;
}

forward RaceTimer(playerid);
public RaceTimer(playerid)
{
if(gettime() > PlayerCheckTime[playerid])
{
for(new i;i<sizeof(RaceVehicles);i++)
{
if(RacesVehicles[i] == GetPlayerVehicleID(playerid))
{
RacesVehicles[i] = 0;
break;
}
}
DestroyVehicle(GetPlayerVehicleID(playerid));
IsInRace[playerid] = false;
KillTimer(PlayerRaceTimer[playerid]);
SetPlayerPos(playerid,-2804.5796,-472.9876,7.1875);//CoorDs Outside
}
return 1;
}

stock GetIDofName(name_[])
{
new get_name[MAX_PLAYER_NAME];
for(new i;i<MAX_PLAYERS;i++)
{
if(!GetPlayerName(i,get_name,MAX_PLAYER_NAME))retu rn -1;
if(!strcmp(get_name,name_,false))return i;
}
return -1;
}

Mencent
09/07/2016, 02:41 PM
You have to read my posts. ^^
public OnPlayerCommandText()
to
public OnPlayerCommandText(playerid,cmdtext[])

Youssefree
09/07/2016, 02:48 PM
You have to read my posts. ^^
public OnPlayerCommandText()
to
public OnPlayerCommandText(playerid,cmdtext[])

Only 4 errors left
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : error 017: undefined symbol "ThreeName"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : warning 215: expression has no effect
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : error 001: expected token: ";", but found "]"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : error 029: invalid expression, assumed zero
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(371) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.

DavidGravelli
09/07/2016, 02:55 PM
new ThreeName[MAX_PLAYERS];

Youssefree
09/07/2016, 03:04 PM
new ThreeName[MAX_PLAYERS];

D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(403) : error 017: undefined symbol "RacesVehicles"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(403) : warning 215: expression has no effect
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(403) : error 001: expected token: ";", but found "]"
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(403) : error 029: invalid expression, assumed zero
D:\Documents and Settings\Salah.FUCKYOU\Bureau\samp037_svr_R2-1-1_win32\filterscripts\RAce.pwn(403) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.

Do i need to add new RacesVehicles[MAX_PLAYERS]; too ?

Mencent
09/07/2016, 03:57 PM
Delete new ThreeName[MAX_PLAYERS];
Search in the script "ThreeName" and change it to "ThreeWinner"

RacesVehicles must be RaceVehicle without "s" in the script. ;) It are spelling mistakes of me. ;)

Youssefree
09/07/2016, 04:21 PM
Delete new ThreeName[MAX_PLAYERS];
Search in the script "ThreeName" and change it to "ThreeWinner"

RacesVehicles must be RaceVehicle without "s" in the script. ;) It are spelling mistakes of me. ;)

new ThreeWinner[MAX_PLAYERS];
OR
new ThreeWinner[3][MAX_PLAYER_NAME];
?

Mencent
09/07/2016, 04:32 PM
You must use my code which I sent you in the other post. Otherwise I can't help you when you only do the half.
new ThreeWinner[3][MAX_PLAYER_NAME];
This.

Youssefree
09/07/2016, 04:41 PM
You must use my code which I sent you in the other post. Otherwise I can't help you when you only do the half.
new ThreeWinner[3][MAX_PLAYER_NAME];
This.

Ah , it compiles perfect :)
but, there's no textdraw of the 20second between checkpoints !
+ there's a bug with the control, if a new player joins( after /startrace he didn't unfreeze , just stops in his car )
+ no /stoprace rcon command

Mencent
09/07/2016, 07:32 PM
OK. Yes, we put in the textdraw at the end of the little "project" so when all other things are finish. ;)

+ there's a bug with the control, if a new player joins( after /startrace he didn't unfreeze , just stops in his car )
Ah, write it like this:
if(!strcmp(cmdtext,"/joinrace",true))
{
if(!IsPlayerInRangeOfPoint(playerid,4.0,-2807.7458, -471.7142, 7.3435))return SendClientMessage(playerid,-1,"You aren't in range of the vicitim door!");
if(IsInRace[playerid] == true)return SendClientMessage(playerid,-1,"You already joined the race!");
IsInRace[playerid] = true;
new veh_index;
for(new i;i<RaceVehicles;i++)
{
if(RaceVehicles[i] > 0)continue;
veh_index = i;
break;
}
for(new i;i<PlaceInfo;i++)
{
if(RacePlaceUse[i] == true)continue;
RacePlaceUse[i] = true;
RaceVehicles[veh_index] = CreateVehicle(411,PlaceInfo[i][Pos_X],PlaceInfo[i][Pos_Y],PlaceInfo[i][Pos_Z],PlaceInfo[i][Pos_A],-1,-1,-1);
SetVehicleHealth(RaceVehicles[veh_index],100000);
PutPlayerInVehicle(playerid,RaceVehicles[veh_index],0);
break;
}
if(IsRaceStart == false)TogglePlayerControllable(playerid,0);
SendClientMessageToAll(-1,"Join the race! (/joinrace)");
return 1;
}

+ no /stoprace rcon command
What should happen when the RCON type "/stoprace"?

Youssefree
09/07/2016, 09:51 PM
What should happen when the RCON type "/stoprace"?
( The fs must reload )

Youssefree
09/07/2016, 09:55 PM
C:\Documents and Settings\Youssef\Bureau\RPG Romania 1.00.40\filterscripts\RAce.pwn(299) : error 033: array must be indexed (variable "RaceVehicles")
C:\Documents and Settings\Youssef\Bureau\RPG Romania 1.00.40\filterscripts\RAce.pwn(305) : error 033: array must be indexed (variable "PlaceInfo")
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase


2 Errors.

Mencent
09/07/2016, 10:03 PM
Can you send me the both lines? ;)

Here your "/stoprace".
else if(!strcmp(cmdtext,"/stoprace",true))
{
if(!IsPlayerAdmin(playerid))return SendClientMessage(playerid,-1,"You have to log in RCON!");
if(IsRaceStart == false)return SendClientMessage(playerid,-1,"The race isn't started!");
IsRaceStart = false;
SendRconCommand("rcon reloadfs FS_NAME");
return 1;
}
Notes: FS_NAME is your Filterscript name, so you must change this!

Dayrion
09/07/2016, 10:39 PM
Can you send me the both lines? ;)

Here your "/stoprace".
else if(!strcmp(cmdtext,"/stoprace",true))
{
if(!IsPlayerAdmin(playerid))return SendClientMessage(playerid,-1,"You have to log in RCON!");
if(IsRaceStart == false)return SendClientMessage(playerid,-1,"The race isn't started!");
IsRaceStart = false;
SendRconCommand("rcon reloadfs FS_NAME");
return 1;
}
Notes: FS_NAME is your Filterscript name, so you must change this!

The server will probably crash. (I'm 99% sure)

Youssefree
09/07/2016, 10:53 PM
The server will probably crash. (I'm 99% sure)

Really??

Youssefree
09/07/2016, 10:56 PM
Can you send me the both lines? ;)

Here your "/stoprace".
else if(!strcmp(cmdtext,"/stoprace",true))
{
if(!IsPlayerAdmin(playerid))return SendClientMessage(playerid,-1,"You have to log in RCON!");
if(IsRaceStart == false)return SendClientMessage(playerid,-1,"The race isn't started!");
IsRaceStart = false;
SendRconCommand("rcon reloadfs FS_NAME");
return 1;
}
Notes: FS_NAME is your Filterscript name, so you must change this!


298 new veh_index;
299 for(new i;i<RaceVehicles;i++)
230 {
231 if(RaceVehicles[i] > 0)continue;

and

302 veh_index = i;
303 break;
304 }
305 for(new i;i<PlaceInfo;i++)
306 {
307 if(RacePlaceUse[i] == true)continue;

Dayrion
09/07/2016, 11:10 PM
Really??

Yes. But try it, maybe it will not.

Mencent
10/07/2016, 06:18 AM
for(new i;i<RaceVehicles;i++)
to
for(new i;i<sizeof(RaceVehicles);i++)




for(new i;i<PlaceInfo;i++)
to
for(new i;i<sizeof(PlaceInfo);i++)

Youssefree
10/07/2016, 01:12 PM
for(new i;i<RaceVehicles;i++)
to
for(new i;i<sizeof(RaceVehicles);i++)




for(new i;i<PlaceInfo;i++)
to
for(new i;i<sizeof(PlaceInfo);i++)

After using this anything is good except the first checkpoint is not appearing at all!
But i want the first checkpoint to appear only after /joinrace in range of the victim door :(

Youssefree
11/07/2016, 02:25 PM
Hey , mencent , brother ?

Mencent
11/07/2016, 03:14 PM
Oh, I forgot this thread. Sorry...

Can you explain me what do you mean with this?
After using this anything is good except the first checkpoint is not appearing at all!
But i want the first checkpoint to appear only after /joinrace in range of the victim door

Youssefree
11/07/2016, 10:04 PM
Oh, I forgot this thread. Sorry...

Can you explain me what do you mean with this?

The race CPs are not appearing att all
So after /startrace , there isn't any cp.

Mencent
12/07/2016, 07:12 AM
Sorry. Now I'm here. ;)

if(!strcmp(cmdtext,"/joinrace",true))
{
if(!IsPlayerInRangeOfPoint(playerid,4.0,-2807.7458, -471.7142, 7.3435))return SendClientMessage(playerid,-1,"You aren't in range of the vicitim door!");
if(IsInRace[playerid] == true)return SendClientMessage(playerid,-1,"You already joined the race!");
IsInRace[playerid] = true;
SetPlayerRaceCheckpoint(playerid,0,CheckPoints[Player_CheckPoint[playerid]][0],CheckPoints[Player_CheckPoint[playerid]][1],CheckPoints[Player_CheckPoint[playerid]][2],CheckPoints[Player_CheckPoint[playerid]+1][0],CheckPoints[Player_CheckPoint[playerid]+1][1],CheckPoints[Player_CheckPoint[playerid]+1][2],9.7);
new veh_index;
for(new i;i<RaceVehicles;i++)
{
if(RaceVehicles[i] > 0)continue;
veh_index = i;
break;
}
for(new i;i<PlaceInfo;i++)
{
if(RacePlaceUse[i] == true)continue;
RacePlaceUse[i] = true;
RaceVehicles[veh_index] = CreateVehicle(411,PlaceInfo[i][Pos_X],PlaceInfo[i][Pos_Y],PlaceInfo[i][Pos_Z],PlaceInfo[i][Pos_A],-1,-1,-1);
SetVehicleHealth(RaceVehicles[veh_index],100000);
PutPlayerInVehicle(playerid,RaceVehicles[veh_index],0);
TogglePlayerControllable(playerid,0);
break;
}
SendClientMessageToAll(-1,"Join the race! (/joinrace)");
return 1;
}
I forgot to create a checkpoint at start. Try this.