Hallo Leute,
Irgendwie habe ich ein Problem.
Ich habe ein Godfather Edit. Dort waren die Cars von Los Rapidos alle getunt, aber irgendwie wird das getunte nun aber nicht mehr gespeichert...
Ich weiß leider auch nicht wo ich nachschauen muss. Hier zumindest der Tuning Code:
Function WheelTuning(vehicleid)
{
if(vehicleid == WheelVehs[0]) // Huntley 579 x
{
AddVehicleComponent(vehicleid, 1025);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[1]) // Huntley 579 x
{
AddVehicleComponent(vehicleid, 1025);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[2]) // Buffalo 402 x
{
AddVehicleComponent(vehicleid, 1082);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[3]) // Buffalo 402 x
{
AddVehicleComponent(vehicleid, 1082);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[4]) // Uranus 558 x
{
AddVehicleComponent(vehicleid, 1163);
AddVehicleComponent(vehicleid, 1091);
AddVehicleComponent(vehicleid, 1093);
AddVehicleComponent(vehicleid, 1089);
AddVehicleComponent(vehicleid, 1085);
AddVehicleComponent(vehicleid, 1165);
AddVehicleComponent(vehicleid, 1167);
AddVehicleComponent(vehicleid, 1010);
ChangeVehiclePaintjob(vehicleid, 0);
}
if(vehicleid == WheelVehs[5]) // Uranus 558 x
{
AddVehicleComponent(vehicleid, 1164);
AddVehicleComponent(vehicleid, 1088);
AddVehicleComponent(vehicleid, 1090);
AddVehicleComponent(vehicleid, 1092);
AddVehicleComponent(vehicleid, 1085);
AddVehicleComponent(vehicleid, 1166);
AddVehicleComponent(vehicleid, 1168);
AddVehicleComponent(vehicleid, 1010);
ChangeVehiclePaintjob(vehicleid, 0);
}
if(vehicleid == WheelVehs[6]) // Elegy 562 x
{
AddVehicleComponent(vehicleid, 1146);
AddVehicleComponent(vehicleid, 1035);
AddVehicleComponent(vehicleid, 1039);
AddVehicleComponent(vehicleid, 1037);
AddVehicleComponent(vehicleid, 1082);
AddVehicleComponent(vehicleid, 1172);
AddVehicleComponent(vehicleid, 1148);
AddVehicleComponent(vehicleid, 1010);
ChangeVehiclePaintjob(vehicleid, 1);
}
if(vehicleid == WheelVehs[7]) // Elegy 562 x
{
AddVehicleComponent(vehicleid, 1147);
AddVehicleComponent(vehicleid, 1038);
AddVehicleComponent(vehicleid, 1036);
AddVehicleComponent(vehicleid, 1034);
AddVehicleComponent(vehicleid, 1082);
AddVehicleComponent(vehicleid, 1171);
AddVehicleComponent(vehicleid, 1149);
AddVehicleComponent(vehicleid, 1010);
ChangeVehiclePaintjob(vehicleid, 1);
}
if(vehicleid == WheelVehs[8]) // Jester 559 x
{
AddVehicleComponent(vehicleid, 1162);
AddVehicleComponent(vehicleid, 1069);
AddVehicleComponent(vehicleid, 1065);
AddVehicleComponent(vehicleid, 1073);
AddVehicleComponent(vehicleid, 1160);
AddVehicleComponent(vehicleid, 1159);
AddVehicleComponent(vehicleid, 1010);
ChangeVehiclePaintjob(vehicleid, 1);
}
if(vehicleid == WheelVehs[9]) // Jester 559 x
{
AddVehicleComponent(vehicleid, 1162);
AddVehicleComponent(vehicleid, 1069);
AddVehicleComponent(vehicleid, 1065);
AddVehicleComponent(vehicleid, 1073);
AddVehicleComponent(vehicleid, 1160);
AddVehicleComponent(vehicleid, 1159);
AddVehicleComponent(vehicleid, 1010);
ChangeVehiclePaintjob(vehicleid, 1);
}
if(vehicleid == WheelVehs[10]) // Sultan 560 x
{
AddVehicleComponent(vehicleid, 1139);
AddVehicleComponent(vehicleid, 1033);
AddVehicleComponent(vehicleid, 1031);
AddVehicleComponent(vehicleid, 1029);
AddVehicleComponent(vehicleid, 1073);
AddVehicleComponent(vehicleid, 1170);
AddVehicleComponent(vehicleid, 1140);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[11]) // Sultan 560 x
{
AddVehicleComponent(vehicleid, 1139);
AddVehicleComponent(vehicleid, 1033);
AddVehicleComponent(vehicleid, 1031);
AddVehicleComponent(vehicleid, 1029);
AddVehicleComponent(vehicleid, 1073);
AddVehicleComponent(vehicleid, 1170);
AddVehicleComponent(vehicleid, 1140);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[12]) // Stafford 580 x
{
AddVehicleComponent(vehicleid, 1006);
AddVehicleComponent(vehicleid, 1007);
AddVehicleComponent(vehicleid, 1018);
AddVehicleComponent(vehicleid, 1082);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[13]) // Infernus 411 x
{
AddVehicleComponent(vehicleid, 1082);
AddVehicleComponent(vehicleid, 1010);
}
if(vehicleid == WheelVehs[14]) // Cheetah 415 x
{
AddVehicleComponent(vehicleid, 1023);
AddVehicleComponent(vehicleid, 1007);
AddVehicleComponent(vehicleid, 1018);
AddVehicleComponent(vehicleid, 1082);
AddVehicleComponent(vehicleid, 1010);
}
}
Function CarTuning(playerid,slot)
{
ChangeVehicleColor(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarC1],PlayerCar[playerid][slot][CarC2]);
if(PlayerCar[playerid][slot][CarPJ] >= 0) {ChangeVehiclePaintjob(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarPJ]);}
if(PlayerCar[playerid][slot][CarNitro] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarNitro]);}
if(PlayerCar[playerid][slot][CarHyd] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarHyd]);}
if(PlayerCar[playerid][slot][CarWheel] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarWheel]);}
if(PlayerCar[playerid][slot][CarAusp] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarAusp]);}
if(PlayerCar[playerid][slot][CarSideL] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarSideL]);}
if(PlayerCar[playerid][slot][CarSideR] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarSideR]);}
if(PlayerCar[playerid][slot][CarFB] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarFB]);}
if(PlayerCar[playerid][slot][CarRB] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarRB]);}
if(PlayerCar[playerid][slot][CarSpoiler] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarSpoiler]);}
if(PlayerCar[playerid][slot][CarRoof] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarRoof]);}
if(PlayerCar[playerid][slot][CarHood] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarHood]);}
if(PlayerCar[playerid][slot][CarVents] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarVents]);}
if(PlayerCar[playerid][slot][CarLamps] != 0) {AddVehicleComponent(PlayerCar[playerid][slot][CarId],PlayerCar[playerid][slot][CarLamps]);}
if(Dtc_LockOnSpawn)
{
Dtc_Carlock[PlayerCar[playerid][slot][CarId]] = 1;
Dtc_LockCar(PlayerCar[playerid][slot][CarId]);
}
}
Function OnVehiclePaintjob(playerid,vehicleid,paintjobid)
{
for(new x = 0; x < MaxVeh; x++)
{
if (vehicleid == PlayerCar[playerid][x][CarId] && Dtc_PlayerHaveCar[playerid][x])
{
PlayerCar[playerid][x][CarPJ] = paintjobid;
PlayerCar[playerid][x][CarC1] = 1;
PlayerCar[playerid][x][CarC2] = 1;
}
}
return 1;
}
Function OnVehicleSpawn(vehicleid)
{
Gas[vehicleid] = GetGasMax(vehicleid);
for(new playerid = 0; playerid < MAX_PLAYERS; playerid++)
{
for(new x = 0; x < MaxVeh; x++)
{
if(IsPlayerConnected(playerid) && Dtc_PlayerHaveCar[playerid][x])
{
if (vehicleid == PlayerCar[playerid][x][CarId])
{
SetTimerEx("CarTuning",700,0,"ii",playerid,x);
}
}
}
}
if(sfl1[vehicleid] != 0)
{
DestroyObject(sfl1[vehicleid]);
DestroyObject(sfl2[vehicleid]);
DestroyObject(sfl3[vehicleid]);
DestroyObject(sfl4[vehicleid]);
DestroyObject(sfl5[vehicleid]);
sfl1[vehicleid] = 0;
sfl2[vehicleid] = 0;
sfl3[vehicleid] = 0;
sfl4[vehicleid] = 0;
sfl5[vehicleid] = 0;
}
if(IsAGangCar(vehicleid))
{
new vehmod = GetVehicleModel(vehicleid);
if(vehmod != 487 && vehmod != 522 && vehmod != 463 && vehmod != 468 && vehmod != 471 && vehmod != 482)
{
AddVehicleComponent(vehicleid, 1010);
}
}
for(new pv = 0; pv < sizeof(WheelVehs); pv++)
{
if(vehicleid == WheelVehs[pv])
{
SetTimerEx("WheelTuning", 700, 0, "i",vehicleid);
}
}
return 1;
}
Hoffentlich waren es die richtigen Zeilen.
Ich hoffe ihr könnt mir helfen.
MFG Eric.Wright