I have a new Problem, with my Car System, since i added tuning, it doesn't save anymore
Код:
stock saveCars(playerid)
{
new Spoiler, Hood, Roof, Sideskirt, Lamps, Nitro, Exhaust, Wheels, Stereo, Hydraulics, FrontBumper, RearBumper, VentRight, VentLeft;
Spoiler = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_SPOILER);
Hood = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_HOOD);
Roof = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_ROOF);
Sideskirt = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_SIDESKIRT);
Lamps = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_LAMPS);
Nitro = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_NITRO);
Exhaust = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_EXHAUST);
Wheels = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_WHEELS);
Stereo = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_STEREO);
Hydraulics = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_HYDRAULICS);
FrontBumper = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_FRONT_BUMPER);
RearBumper = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_REAR_BUMPER);
VentRight = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_VENT_RIGHT);
VentLeft = GetVehicleComponentInSlot(cInfo[playerid][id],CARMODTYPE_VENT_LEFT);
new query[256];
new Float:x,Float:y,Float:z,Float:a;
GetVehiclePos(cInfo[playerid][id],x,y,z);
GetVehicleZAngle(cInfo[playerid][id],a);
format(query,sizeof(query),"UPDATE autos SET x='%f',y='%f',z='%f',a='%f',Spoiler='%d',Hood='%d',Roof='%d',Sideskirt='%d',Lamps='%d',Nitro='%d',Exhaust='%d',Wheels='%d',Stereo='%d',Hydraulics='%d',FrontBumper='%d',RearBumper='%d',VentRight='%d',VentLeft='%d' WHERE besitzer='%d'",
x,y,z,a,Spoiler,Hood,Roof,Sideskirt,Lamps,Nitro,Exhaust,Wheels,Stereo,Hydraulics,FrontBumper,RearBumper,VentRight,VentLeft,pInfo[playerid][db_id]);
mysql_function_query(dbhandle,query,false,"","");
return 1;
}