20.11.2016, 15:39
Hello dea people!!
I was working on my script and got errors. So, i would like to show them
Errors:
The line 21033:
I will be thanksful if you could help me a little bit!
I was working on my script and got errors. So, i would like to show them
Код:
stock SetupVehiclesFile() { new File: file; file = fopen(V_FILE_SAVE, io_write); new SplitDiv[99][MAX_VEHICLES]; new filestring[256]; file = fopen(V_FILE_LOAD, io_read); new carcost[MAX_VEHICLES]; for(new vehicleid=1;vehicleid<=vehcount;vehicleid++) { if (file) { fread(file, filestring); split(filestring, SplitDiv, ','); VehicleInfo[vehicleid][model] = strval(SplitDiv[0]); VehicleInfo[vehicleid][x_spawn] = floatstr(SplitDiv[1]); VehicleInfo[vehicleid][y_spawn] = floatstr(SplitDiv[2]); VehicleInfo[vehicleid][z_spawn] = floatstr(SplitDiv[3]); VehicleInfo[vehicleid][za_spawn] = floatstr(SplitDiv[4]); VehicleInfo[vehicleid][ox_spawn] = floatstr(SplitDiv[1]); VehicleInfo[vehicleid][oy_spawn] = floatstr(SplitDiv[2]); VehicleInfo[vehicleid][oz_spawn] = floatstr(SplitDiv[3]); VehicleInfo[vehicleid][oza_spawn] = floatstr(SplitDiv[4]); VehicleInfo[vehicleid][color_1] = strval(SplitDiv[5]); VehicleInfo[vehicleid][color_2] = strval(SplitDiv[6]); CreateVehicle(VehicleInfo[vehicleid][model], VehicleInfo[vehicleid][x_spawn], VehicleInfo[vehicleid][y_spawn], VehicleInfo[vehicleid][z_spawn], VehicleInfo[vehicleid][za_spawn], VehicleInfo[vehicleid][color_1], VehicleInfo[vehicleid][color_2],20000); onsys[vehicleid] = 1; carcost[vehicleid] = 50000; for(new s=0; s<24; s++) { if(VehicleInfo[vehicleid][model] == heavycar[s][0]) { carcost[vehicleid] = 100000; } } for(new a=0; a<11; a++) { if(VehicleInfo[vehicleid][model] == boat[a][0]) { carcost[vehicleid] = 50000; } } for(new mb=0; mb<11; mb++) { if(VehicleInfo[vehicleid][model] == mbike[mb][0]) { carcost[vehicleid] = 40000; } } for(new d=0; d<3; d++) { if(VehicleInfo[vehicleid][model] == pbike[d][0]) { carcost[vehicleid] = 3000; } } for(new e=0; e<6; e++) { if(VehicleInfo[vehicleid][model] == splane[e][0]) { carcost[vehicleid] = 500000; } } for(new f=0; f<2; f++) { if(VehicleInfo[vehicleid][model] == mplane[f][0]) { carcost[vehicleid] = 1500000; } } for(new v=0; v<2; v++) { if(VehicleInfo[vehicleid][model] == lplane[v][0]) { carcost[vehicleid] = 2000000; } } for(new n=0; n<4; n++) { if(VehicleInfo[vehicleid][model] == milair[n][0]) { carcost[vehicleid] = 4000000; } } for(new j=0; j<4; j++) { if(VehicleInfo[vehicleid][model] == sheli[j][0]) { carcost[vehicleid] = 750000; } } for(new k=0; k<3; k++) { if(VehicleInfo[vehicleid][model] == lheli[k][0]) { carcost[vehicleid] = 1250000; } } VehicleInfo[vehicleid][vehiclecost] = carcost[vehicleid]; VehicleInfo[vehicleid][vused] = 0; VehicleInfo[vehicleid][bought] = 0; VehicleInfo[vehicleid][secure] = 0; VehicleInfo[vehicleid][asecure] = 0; VehicleInfo[vehicleid][buybar] = 0; VehicleInfo[vehicleid][mod1] = 0; VehicleInfo[vehicleid][mod2] = 0; VehicleInfo[vehicleid][mod3] = 0; VehicleInfo[vehicleid][mod4] = 0; VehicleInfo[vehicleid][mod5] = 0; VehicleInfo[vehicleid][mod6] = 0; VehicleInfo[vehicleid][mod7] = 0; VehicleInfo[vehicleid][mod8] = 0; VehicleInfo[vehicleid][mod9] = 0; VehicleInfo[vehicleid][mod10] = 0; VehicleInfo[vehicleid][mod11] = 0; VehicleInfo[vehicleid][mod12] = 0; VehicleInfo[vehicleid][mod13] = 0; VehicleInfo[vehicleid][mod14] = 0; VehicleInfo[vehicleid][mod15] = 0; VehicleInfo[vehicleid][mod16] = 0; VehicleInfo[vehicleid][mod17] = 0; VehicleInfo[vehicleid][paintjob] = -1; strmid(VehicleInfo[vehicleid][owner], DEFAULT_OWNER, 0, strlen(DEFAULT_OWNER), 255); strmid(VehicleInfo[vehicleid][name], VehicleName[GetVehicleModel(vehicleid)-400][0], 0, strlen(VehicleName[GetVehicleModel(vehicleid)-400][0]), 255); new addmess[256]; format(addmess,sizeof(addmess),"--:: Vehicle %d (%s) successfully spawned ::--",vehicleid,VehicleInfo[vehicleid][name]); //print(addmess); } } fclose(file); // print(">------------------------------------------------"); // print(" "); // print(">------------------------------------------------"); // print("Initialising Vehicle File System - Please Wait For Confirmation..."); // print(" "); SaveVehicles(); // print(" "); // print("Vehicle File System 100% Initialised..."); // print(">------------------------------------------------"); // printf(" "); }
Код:
C:\Users\ўггелпт\Desktop\NFTDM\gamemodes\NFTDM[3z].pwn(21033) : error 001: expected token: ")", but found "[" C:\Users\ўггелпт\Desktop\NFTDM\gamemodes\NFTDM[3z].pwn(21033) : error 029: invalid expression, assumed zero C:\Users\ўггелпт\Desktop\NFTDM\gamemodes\NFTDM[3z].pwn(21033) : warning 215: expression has no effect C:\Users\ўггелпт\Desktop\NFTDM\gamemodes\NFTDM[3z].pwn(21033) : error 001: expected token: ";", but found "]" C:\Users\ўггелпт\Desktop\NFTDM\gamemodes\NFTDM[3z].pwn(21033) : fatal error 107: too many error messages on one line Compilation aborted.Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors.
The line 21033:
Код:
if(VehicleInfo[vehicleid][model] == heavycar[s][0]) {