Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- stock NapraviVoziloEno(X_THREAD,Model,Float:x,Float:y,Float:z,Float:a,col1,col2,name[],cena)
- {
- for(new i = 0; i < sizeof(MyVehicle); i++ )
- {
- if(MyVehicle[i][MyVehSlot] == 0)
- {
- MyVehicle[i][MyVehModel] = Model;
- MyVehicle[i][MyVehPos][0]= x;
- MyVehicle[i][MyVehPos][1] = y;
- MyVehicle[i][MyVehPos][2] = z;
- MyVehicle[i][MyVehPos][3] = a;
- MyVehicle[i][MyVehCol][0] = col1;
- MyVehicle[i][MyVehCol][1] = col2;
- MyVehicle[i][MyVehCena] = cena;
- MyVehicle[i][MyVehAlarm] = 0;
- MyVehicle[i][MyVehLock] = 0;
- MyVehicle[i][MyVehCar] = -1;
- strmid(MyVehicle[i][MyVehOwner], name, 0, strlen(name), 32);
- MyVehicle[i][MyVehID] = CreateVehicle(MyVehicle[i][MyVehModel],MyVehicle[i][MyVehPos][0],MyVehicle[i][MyVehPos][1],MyVehicle[i][MyVehPos][2],MyVehicle[i][MyVehPos][3],MyVehicle[i][MyVehCol][0],MyVehicle[i][MyVehCol][1],30000);
- switch(X_THREAD)
- {
- case 0:
- {
- MyVehicle[i][MyVehCar] = 1;
- MyVehicle[i][MyVehSlot] = 1;
- }
- }
- ZacuvajCarOwnerShip(i);
- return i;
- }
- }
- return 1;
- }
- //-------------------------------------------------------------------------------------------------------------------------------------
- //===============================[Avto Salon]===================================
- if(dialogid == DIALOG_AVTOSALON)
- {
- if(response)
- {
- switch(listitem)
- {
- case 0:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(4000000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 560, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -4000000);// SULTAN
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 1:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(3000000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 579, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -3000000);// HUNTLEY
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 2:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(4500000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 451, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -4500000);//TURIZMO
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 3:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(2500000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 411, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -2500000);//INFERNUS
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 4:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(2000000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 429, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -2000000);//BANSHEE
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 5:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(2200000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 506, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -2200000);//SUPER GT
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 6:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(2000000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 477, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -2000000);//ZR-350
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 7:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(1500000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 565, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -1500000);//FLASH
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 8:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(1000000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 426, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -1000000);//PREMIER
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 9:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(900000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 507, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -900000);//ELEGANT
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 10:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(800000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 436, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -800000);//PREVION
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 11:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(700000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 439, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -700000);//STALLION
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- case 12:
- {
- if(MyVehicle[playerid][MyVehCar] == 1 && AllMyCars(playerid) >= PlayerInfo[playerid][pMaxKoli])
- {
- SendClientMessage(playerid, COLOR_WHITE, "{ff0000}| Error | {FFFFFF} Dostignat vi e limitot na avtomobili.");
- TogglePlayerControllable(playerid, 1);
- return 1;
- }
- if(1000000 >= GetPlayerMoney(playerid))
- {
- SendClientMessage(playerid,-1,"{ff0000}| Error | {FFFFFF}Nemate dovolno pari za ovaj avtomobil");
- return 1;
- }
- new s, poz = random(sizeof(randomswp));
- s = NapraviVoziloEno(0, 445, randomswp[ poz ][ 0 ], randomswp[ poz ][ 1 ], randomswp[ poz ][ 2 ], randomswp[ poz ][ 3 ], 1,1, GetName(playerid), 170000);
- GivePlayerMoney(playerid, -1000000);//ADMIRAL
- strmid(MyVehicle[s][MyVehOwner], GetName(playerid), 0, strlen(GetName(playerid)), 24);
- Gorivo[s] = 100;
- ZacuvajCarOwnerShip(s);
- Avtosalon[playerid] = 1;
- SendClientMessage(playerid, COLOR_WHITE,"{ff0000}[AvtoSalon]:{FFFFFF}Uspesno kupivte vozilo.Toa vi e parkirano na parkingot od salonot.");
- }
- }
- }
- else
- {
- SCM(playerid, COLOR_WHITE, "{1e90ff}| INFO |{FFFFFF}Povekje ne razgleduvate vozila.");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement