20.10.2014, 03:31
I have this error:
VehicleSystem.pwn(295) : error 001: expected token: "]", but found "-identifier-"
How can I fix it?
Pleace Help me!!
Thanks advice.
VehicleSystem.pwn(295) : error 001: expected token: "]", but found "-identifier-"
How can I fix it?
pawn Код:
stock MakeVehicle(playerid, vehModel, vehColor1, vehColor2, vehFuelType[20], vehOwner) {
new Float:X, Float:Y, Float:Z, Float:angle, model[32];
if(IsNumeric(model)) vehModel = strval(model);
else vehModel = GetVehicleModelIDFromName(model);
if(vehModel < 400 || vehModel > 611) return SendClientMessage(playerid, COLOR_RED, "Invalid model ID!");
if(vehColor1 < 0 || vehColor2 < 0) return SendClientMessage(playerid, COLOR_RED, "Invalid color!");
GetPlayerPos(playerid, X, Y, Z);
GetPlayerFacingAngle(playerid, angle);
for(new i = 1; i < MAX_SVEHICLES; i++) {
VehicleInfo[i][vName] = "No name It is for sale";
VehicleInfo[i][vOwner] = GetName(vehOwner);
VehicleInfo[i][vModel] = vehModel;
VehicleInfo[i][vColor][0] = vehColor1;
VehicleInfo[i][vColor][1] = vehColor2;
VehicleInfo[i][vPos][0] = X;
VehicleInfo[i][vPos][1] = Y;
VehicleInfo[i][vPos][2] = Z;
VehicleInfo[i][vPos][3] = angle;
VehicleInfo[i][vInterior] = GetPlayerInterior(playerid);
VehicleInfo[i][vWorld] = GetPlayerVirtualWorld(playerid);
VehicleInfo[i][vPrice] = 0;
VehicleInfo[i][vFuelType] = vehFuelType;
VehicleInfo[i][vNPlate][10] = DEFAULT_NPLATE;
for(new d = 0; d < sizeof(VehicleInfo[i][vMods]); d++){VehicleInfo[i][Mods][d] = 0;} //295
VehicleInfo[i][vFuel] = 100;
VehicleInfo[i][vDamage] = 1000;
VehicleInfo[i][vPaintJob] = 255;
VehicleInfo[i][vLock] = 0;
VehicleInfo[i][vAlarm] = 0;
vCreated[i] = true;
SaveVehicle(i);
}
return 1;
}
Thanks advice.