Heyho...
mein Tuining der gekauften Cars werden nicht geladen..
sie werden aber gespeichert...
da ich mich mit Car system undso nicht so gut auskenne frage ich euch...
ich schreib einmal das hin, was ich beim Laden habe..
stock LoadVehicels(playerid)
{
new arrCoords[30][64];
new strFromFile2[256];
new string[256], name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string),"/Autohaus/%s.ini",name);
if(!fexist(string)) return 1;
new File: file = fopen(string, io_read);
if (file)
{
fread(file, strFromFile2);
split(strFromFile2, arrCoords, ',');
CarInfo[playerid][pX] = floatstr(arrCoords[0]);
CarInfo[playerid][pY] = floatstr(arrCoords[1]);
CarInfo[playerid][pZ] = floatstr(arrCoords[2]);
CarInfo[playerid][pA] = floatstr(arrCoords[3]);
CarInfo[playerid][pFarbe1] = strval(arrCoords[4]);
CarInfo[playerid][pFarbe2] = strval(arrCoords[5]);
CarInfo[playerid][pModel] = strval(arrCoords[6]);
CarInfo[playerid][pPreis] = strval(arrCoords[7]);
strmid(CarInfo[playerid][pOwner], name, 0, strlen(name), 255);
new str[128];
format(str, sizeof(str),"%s",name);
CarInfo[playerid][pKey] = CreateVehicle(CarInfo[playerid][pModel],CarInfo[playerid][pX],CarInfo[playerid][pY],CarInfo[playerid][pZ],CarInfo[playerid][pA],CarInfo[playerid][pFarbe1],CarInfo[playerid][pFarbe2],-1);
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[8]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[9]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[10]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[11]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[12]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[13]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[14]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[15]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[16]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[17]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[18]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[19]));
AddVehicleComponent(CarInfo[playerid][pKey], strval(arrCoords[20]));
SetVehicleNumberPlate(CarInfo[playerid][pKey],str);
SetVehicleToRespawn(CarInfo[playerid][pKey]);
fclose(file);
}
return 1;
}