SA-MP Forums Archive
Bug Plate PLEASE HELP ME !!! - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Bug Plate PLEASE HELP ME !!! (/showthread.php?tid=272138)



Bug Plate PLEASE HELP ME !!! - Johnny_Ionut - 27.07.2011

Hi ... recently I changed my gamemode and made the numbers go private cars ... LARP mode is only 2 letter and logs of all letters and numbers and shows some signs ... look at the picture below ...



Why is that?
it appears in game number as it appears and the console!



Re: Bug Plate PLEASE HELP ME !!! - shaikh007 - 27.07.2011

Donot Spam topic. wait for helpers to help you.


Re: Bug Plate PLEASE HELP ME !!! - Gamer_Z - 27.07.2011

you are formatting the string wrong?
show your code..
@up how is he spamming? ;o


Re: Bug Plate PLEASE HELP ME !!! - Johnny_Ionut - 27.07.2011

Quote:

public LoadCar()
{
new arrCoords[13][64];
new strFromFile2[256];
new File: file = fopen("cars.cfg", io_read);
if (file)
{
new idx = 234;
while (idx < sizeof(CarInfo))
{
fread(file, strFromFile2);
split(strFromFile2, arrCoords, ',');
CarInfo[idx][cModel] = strval(arrCoords[0]);
CarInfo[idx][cLocationx] = floatstr(arrCoords[1]);
CarInfo[idx][cLocationy] = floatstr(arrCoords[2]);
CarInfo[idx][cLocationz] = floatstr(arrCoords[3]);
CarInfo[idx][cAngle] = floatstr(arrCoords[4]);
CarInfo[idx][cColorOne] = strval(arrCoords[5]);
CarInfo[idx][cColorTwo] = strval(arrCoords[6]);
strmid(CarInfo[idx][cOwner], arrCoords[7], 0, strlen(arrCoords[7]), 255);
strmid(CarInfo[idx][cDescription], arrCoords[8], 0, strlen(arrCoords[8]), 255);
CarInfo[idx][cValue] = strval(arrCoords[9]);
strmid(CarInfo[idx][cLicense], arrCoords[10], 0, strlen(arrCoords[10]), 255);
CarInfo[idx][cOwned] = strval(arrCoords[11]);
CarInfo[idx][cLock] = strval(arrCoords[12]);
printf("CarInfo: %d Owner:%s LicensePlate %s",idx,CarInfo[idx][cOwner],CarInfo[idx][cLicense]);
idx++;
}
}
return 1;
}



for(new h = 234; h < sizeof(CarInfo); h++)
{
AddStaticVehicleEx(CarInfo[h][cModel],CarInfo[h][cLocationx],CarInfo[h][cLocationy],CarInfo[h][cLocationz]+1.0,CarInfo[h][cAngle],CarInfo[h][cColorOne],CarInfo[h][cColorTwo],60000);
SetVehicleNumberPlate(h,CarInfo[h][cLicense]);
}

Please Help Me


Re: Bug Plate PLEASE HELP ME !!! - Johnny_Ionut - 27.07.2011

Quote:

idx = 234;
while (idx < sizeof(CarInfo))
{
new coordsstring[256];
format(coordsstring, sizeof(coordsstring), "%d,%f,%f,%f,%f,%d,%d,%s,%s,%d,%s,%d,%d\n",
CarInfo[idx][cModel],//
CarInfo[idx][cLocationx],//
CarInfo[idx][cLocationy],//
CarInfo[idx][cLocationz],//
CarInfo[idx][cAngle],//
CarInfo[idx][cColorOne],//
CarInfo[idx][cColorTwo],//
CarInfo[idx][cOwner],//
CarInfo[idx][cDescription],//
CarInfo[idx][cValue],//
CarInfo[idx][cLicense],//
CarInfo[idx][cOwned],//
CarInfo[idx][cLock]);
if(idx == 234)
{
file2 = fopen("cars.cfg", io_write);
}
else
{
file2 = fopen("cars.cfg", io_append);
}
fwrite(file2, coordsstring);
idx++;
fclose(file2);
}
return 1;
}

good?


Re: Bug Plate PLEASE HELP ME !!! - Johnny_Ionut - 27.07.2011

but if you can not do that you do not know where to find a system of plates which plates to save a document. txt or. cfg?


Re: Bug Plate PLEASE HELP ME !!! - Johnny_Ionut - 27.07.2011

but do not know which values...


Re: Bug Plate PLEASE HELP ME !!! - Johnny_Ionut - 27.07.2011

help me please ?