error 020: invalid symbol name "" error 010: invalid function or declaration // that is at the end of the array warning 203: symbol is never used: "" // end of gamemode
new AllComponents[MAX_COMPONENTS][ArrayComponent][MAX_COMPONENTS] = {
{1000, "Pro Spoiler", CARMODTYPE_SPOILER, CertainCars_1},
{1001, "Win Spoiler", CARMODTYPE_SPOILER, CertainCars_2}, //Line
{1002, "Drag Spoiler", CARMODTYPE_SPOILER, CertainCars_3},
{1003, "Alpha Spoiler", CARMODTYPE_SPOILER, CertainCars_4},
{1004, "Champ Scoop", CARMODTYPE_HOOD, CertainCars_5},
{1005, "Fury Scoop", CARMODTYPE_HOOD, CertainCars_5},
{1006, "Roof Scoop", CARMODTYPE_HOOD, CertainCars_6},
{1007, "Right Sideskirt", CARMODTYPE_SIDESKIRT, CertainCars_7},
{1008, "Nitro 5x", CARMODTYPE_NITRO, MostCars},
{1009, "Nitro 2x", CARMODTYPE_NITRO, MostCars},
{1010, "Nitro 10x", CARMODTYPE_NITRO, MostCars},
{1011, "Race Scoop", CARMODTYPE_HOOD, CertainCars_8},
{1012, "Worx Scoop", CARMODTYPE_HOOD, CertainCars_8},
{1013, "Round Fog", CARMODTYPE_LAMPS, CertainCars_9},
{1014, "Champ Spoiler", CARMODTYPE_SPOILER, CertainCars_10},
{1015, "Race Spoiler", CARMODTYPE_SPOILER, CertainCars_11},
{1016, "Worx Spoiler", CARMODTYPE_SPOILER, CertainCars_12},
{1017, "Left Sideskirt", CARMODTYPE_SIDESKIRT, CertainCars_13},
{1018, "Upswept", CARMODTYPE_EXHAUST, MostCars_2},
{1019, "Twin", CARMODTYPE_EXHAUST, MostCars_3},
{1020, "Large", CARMODTYPE_EXHAUST, MostCars_4},
{1021, "Medium", CARMODTYPE_EXHAUST, MostCars_4}, ....
new CertainCars_2[] = {401, 405, 410, 415, 420, 426, 436, 439, 496, 518, 527, 529, 540, 546, 549, 550, 580, 603};
You can't include an array in another array like that. And even if you could, the declaration is wrong - that's not how you make just one slot of an enum array-like.
|
enum ArrayComponent
{
cID,
cName[24],
cType
};
Move the second `MAX_COMPONENTS` in to the enum, and define the `401, 405 410` etc inline. You could also use a bit-array for that, which would give `O(1)` lookup to see if a can can use the component. Also, looking again, I doubt `MAX_COMPONENTS` is what you want for that final dimension since it needs to specify the number of vehicles to which the component can be applied, not the number of components that exist.
|
format(strcomponent, sizeof(strcomponent), "%s", AllComponents[0][cName][CARMODTYPE_SPOILER][vehiclemodel]);
error 010: invalid function or declaration error 001: expected token: ",", but found "[" error 029: invalid expression, assumed zero warning 215: expression has no effect error 001: expected token: ";", but found "]" fatal error 107: too many error messages on one line