SA-MP Forums Archive
[Ajuda] AutoTuning nгo repara - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] AutoTuning nгo repara (/showthread.php?tid=626745)



AutoTuning nгo repara - SmokiieGamer - 19.01.2017

Hello ^-^

Entгo, jб estou 1 tempo a tentar colocar o meu autotuning pra reparar, mas nгo consigo ;-;

PHP код:
if(Nitro(GetPlayerVehicleID(playerid)) && (oldkeys || oldkeys 4))
    {
        if(
Autotunning[playerid] == 1)
        {
            if(
PlayerDados[playerid][Admin] == || PlayerDados[playerid][Admin] == || PlayerDados[playerid][Admin] == || PlayerDados[playerid][Admin] == || PlayerDados[playerid][Admin] == || PlayerDados[playerid][VIP] == 1)
            {
                new 
var5 0;
                
var5 GetPlayerVehicleID(playerid);
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 562) {
                    
AddVehicleComponent(var51046);
                    
AddVehicleComponent(var51171);
                    
AddVehicleComponent(var51149);
                    
AddVehicleComponent(var51035);
                    
AddVehicleComponent(var51147);
                    
AddVehicleComponent(var51036);
                    
AddVehicleComponent(var51040);
                    
ChangeVehiclePaintjob(var52);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 560) {
                    
AddVehicleComponent(var51028);
                    
AddVehicleComponent(var51169);
                    
AddVehicleComponent(var51141);
                    
AddVehicleComponent(var51032);
                    
AddVehicleComponent(var51138);
                    
AddVehicleComponent(var51026);
                    
AddVehicleComponent(var51027);
                    
ChangeVehiclePaintjob(var52);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 565) {
                    
AddVehicleComponent(var51046);
                    
AddVehicleComponent(var51153);
                    
AddVehicleComponent(var51150);
                    
AddVehicleComponent(var51054);
                    
AddVehicleComponent(var51049);
                    
AddVehicleComponent(var51047);
                    
AddVehicleComponent(var51051);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 559) {
                    
AddVehicleComponent(var51065);
                    
AddVehicleComponent(var51160);
                    
AddVehicleComponent(var51159);
                    
AddVehicleComponent(var51067);
                    
AddVehicleComponent(var51162);
                    
AddVehicleComponent(var51069);
                    
AddVehicleComponent(var51071);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 561) {
                    
AddVehicleComponent(var51064);
                    
AddVehicleComponent(var51155);
                    
AddVehicleComponent(var51154);
                    
AddVehicleComponent(var51055);
                    
AddVehicleComponent(var51158);
                    
AddVehicleComponent(var51056);
                    
AddVehicleComponent(var51062);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 558) {
                    
AddVehicleComponent(var51089);
                    
AddVehicleComponent(var51166);
                    
AddVehicleComponent(var51168);
                    
AddVehicleComponent(var51088);
                    
AddVehicleComponent(var51164);
                    
AddVehicleComponent(var51090);
                    
AddVehicleComponent(var51094);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 575) {
                    
AddVehicleComponent(var51044);
                    
AddVehicleComponent(var51174);
                    
AddVehicleComponent(var51176);
                    
AddVehicleComponent(var51042);
                    
AddVehicleComponent(var51099);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 534) {
                    
AddVehicleComponent(var51126);
                    
AddVehicleComponent(var51179);
                    
AddVehicleComponent(var51180);
                    
AddVehicleComponent(var51122);
                    
AddVehicleComponent(var51101);
                    
AddVehicleComponent(var51125);
                    
AddVehicleComponent(var51123);
                    
AddVehicleComponent(var51100);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 536) {
                    
AddVehicleComponent(var51104);
                    
AddVehicleComponent(var51182);
                    
AddVehicleComponent(var51184);
                    
AddVehicleComponent(var51108);
                    
AddVehicleComponent(var51107);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 535) {
                    
AddVehicleComponent(var51104);
                    
AddVehicleComponent(var51182);
                    
AddVehicleComponent(var51184);
                    
AddVehicleComponent(var51108);
                    
AddVehicleComponent(var51107);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 567) {
                    
AddVehicleComponent(var51129);
                    
AddVehicleComponent(var51189);
                    
AddVehicleComponent(var51187);
                    
AddVehicleComponent(var51102);
                    
AddVehicleComponent(var51133);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
ChangeVehiclePaintjob(var52);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 420) {
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                    
AddVehicleComponent(var51139);
                    
AddVehicleComponent(var51147);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 400) {
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51018);
                    
AddVehicleComponent(var51013);
                    
AddVehicleComponent(var51079);
                    
AddVehicleComponent(var51086);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 444) {
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 556) {
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 557) {
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 401) {
                    
AddVehicleComponent(var51086);
                    
AddVehicleComponent(var51139);
                    
AddVehicleComponent(var51079);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51012);
                    
AddVehicleComponent(var51013);
                    
AddVehicleComponent(var51042);
                    
AddVehicleComponent(var51043);
                    
AddVehicleComponent(var51018);
                    
AddVehicleComponent(var51006);
                    
AddVehicleComponent(var51007);
                    
AddVehicleComponent(var51017);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 483) {
                    
AddVehicleComponent(var51028);
                    
AddVehicleComponent(var51169);
                    
AddVehicleComponent(var51141);
                    
AddVehicleComponent(var51032);
                    
AddVehicleComponent(var51138);
                    
AddVehicleComponent(var51026);
                    
AddVehicleComponent(var51027);
                    
ChangeVehiclePaintjob(var50);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                }
                if(
GetVehicleModel(GetPlayerVehicleID(playerid)) == 576) {
                    
ChangeVehiclePaintjob(var52);
                    
AddVehicleComponent(var51191);
                    
AddVehicleComponent(var51193);
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51018);
                    
AddVehicleComponent(var51079);
                    
AddVehicleComponent(var51134);
                    
AddVehicleComponent(var51137);
                }
                else{
                    
AddVehicleComponent(var51010);
                    
AddVehicleComponent(var51079);
                }
            }
        }
    } 



Re: AutoTuning nгo repara - FallweN - 19.01.2017

RepairVehicle й isto?

@Edit
Tenta usar assim
pawn Код:
if(Nitro(GetPlayerVehicleID(playerid)) && (oldkeys & 1 || oldkeys & 4))
    {
        if(Autotunning[playerid] == 1)
        {
            if(PlayerDados[playerid][Admin] == 1 || PlayerDados[playerid][Admin] == 2 || PlayerDados[playerid][Admin] == 3 || PlayerDados[playerid][Admin] == 4 || PlayerDados[playerid][Admin] == 5 || PlayerDados[playerid][VIP] == 1)
            {
                new var5 = 0;
                var5 = GetPlayerVehicleID(playerid);
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 562) {
                    AddVehicleComponent(var5, 1046);
                    AddVehicleComponent(var5, 1171);
                    AddVehicleComponent(var5, 1149);
                    AddVehicleComponent(var5, 1035);
                    AddVehicleComponent(var5, 1147);
                    AddVehicleComponent(var5, 1036);
                    AddVehicleComponent(var5, 1040);
                    ChangeVehiclePaintjob(var5, 2);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 560) {
                    AddVehicleComponent(var5, 1028);
                    AddVehicleComponent(var5, 1169);
                    AddVehicleComponent(var5, 1141);
                    AddVehicleComponent(var5, 1032);
                    AddVehicleComponent(var5, 1138);
                    AddVehicleComponent(var5, 1026);
                    AddVehicleComponent(var5, 1027);
                    ChangeVehiclePaintjob(var5, 2);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 565) {
                    AddVehicleComponent(var5, 1046);
                    AddVehicleComponent(var5, 1153);
                    AddVehicleComponent(var5, 1150);
                    AddVehicleComponent(var5, 1054);
                    AddVehicleComponent(var5, 1049);
                    AddVehicleComponent(var5, 1047);
                    AddVehicleComponent(var5, 1051);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 559) {
                    AddVehicleComponent(var5, 1065);
                    AddVehicleComponent(var5, 1160);
                    AddVehicleComponent(var5, 1159);
                    AddVehicleComponent(var5, 1067);
                    AddVehicleComponent(var5, 1162);
                    AddVehicleComponent(var5, 1069);
                    AddVehicleComponent(var5, 1071);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 561) {
                    AddVehicleComponent(var5, 1064);
                    AddVehicleComponent(var5, 1155);
                    AddVehicleComponent(var5, 1154);
                    AddVehicleComponent(var5, 1055);
                    AddVehicleComponent(var5, 1158);
                    AddVehicleComponent(var5, 1056);
                    AddVehicleComponent(var5, 1062);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 558) {
                    AddVehicleComponent(var5, 1089);
                    AddVehicleComponent(var5, 1166);
                    AddVehicleComponent(var5, 1168);
                    AddVehicleComponent(var5, 1088);
                    AddVehicleComponent(var5, 1164);
                    AddVehicleComponent(var5, 1090);
                    AddVehicleComponent(var5, 1094);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 575) {
                    AddVehicleComponent(var5, 1044);
                    AddVehicleComponent(var5, 1174);
                    AddVehicleComponent(var5, 1176);
                    AddVehicleComponent(var5, 1042);
                    AddVehicleComponent(var5, 1099);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 534) {
                    AddVehicleComponent(var5, 1126);
                    AddVehicleComponent(var5, 1179);
                    AddVehicleComponent(var5, 1180);
                    AddVehicleComponent(var5, 1122);
                    AddVehicleComponent(var5, 1101);
                    AddVehicleComponent(var5, 1125);
                    AddVehicleComponent(var5, 1123);
                    AddVehicleComponent(var5, 1100);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 536) {
                    AddVehicleComponent(var5, 1104);
                    AddVehicleComponent(var5, 1182);
                    AddVehicleComponent(var5, 1184);
                    AddVehicleComponent(var5, 1108);
                    AddVehicleComponent(var5, 1107);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 535) {
                    AddVehicleComponent(var5, 1104);
                    AddVehicleComponent(var5, 1182);
                    AddVehicleComponent(var5, 1184);
                    AddVehicleComponent(var5, 1108);
                    AddVehicleComponent(var5, 1107);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 567) {
                    AddVehicleComponent(var5, 1129);
                    AddVehicleComponent(var5, 1189);
                    AddVehicleComponent(var5, 1187);
                    AddVehicleComponent(var5, 1102);
                    AddVehicleComponent(var5, 1133);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    ChangeVehiclePaintjob(var5, 2);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 420) {
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                    AddVehicleComponent(var5, 1139);
                    AddVehicleComponent(var5, 1147);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 400) {
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1018);
                    AddVehicleComponent(var5, 1013);
                    AddVehicleComponent(var5, 1079);
                    AddVehicleComponent(var5, 1086);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 444) {
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 556) {
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 557) {
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 401) {
                    AddVehicleComponent(var5, 1086);
                    AddVehicleComponent(var5, 1139);
                    AddVehicleComponent(var5, 1079);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1012);
                    AddVehicleComponent(var5, 1013);
                    AddVehicleComponent(var5, 1042);
                    AddVehicleComponent(var5, 1043);
                    AddVehicleComponent(var5, 1018);
                    AddVehicleComponent(var5, 1006);
                    AddVehicleComponent(var5, 1007);
                    AddVehicleComponent(var5, 1017);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 483) {
                    AddVehicleComponent(var5, 1028);
                    AddVehicleComponent(var5, 1169);
                    AddVehicleComponent(var5, 1141);
                    AddVehicleComponent(var5, 1032);
                    AddVehicleComponent(var5, 1138);
                    AddVehicleComponent(var5, 1026);
                    AddVehicleComponent(var5, 1027);
                    ChangeVehiclePaintjob(var5, 0);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                }
                if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 576) {
                    ChangeVehiclePaintjob(var5, 2);
                    AddVehicleComponent(var5, 1191);
                    AddVehicleComponent(var5, 1193);
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1018);
                    AddVehicleComponent(var5, 1079);
                    AddVehicleComponent(var5, 1134);
                    AddVehicleComponent(var5, 1137);
                }
                else{
                    AddVehicleComponent(var5, 1010);
                    AddVehicleComponent(var5, 1079);
                }
                RepairVehicle(var5);
            }
        }
    }



Programando e Relaxando! - RazorGuigo - 19.01.2017

PHP код:
 Autotunning[playerid] == 
Verifique se estб recebendo seu valor variante correto!