Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if(dialogid == DIALOG_CARBUY)
- {
- if(response)
- {
- if(listitem == 0)
- {
- new stringzz[10000],stringy[10000];
- for(new xf = 0; xf < MAX_PERSONAL_CARS; xf++)
- {
- if(Stock[xf][vType] == 1)
- {
- format(stringy, sizeof(stringy), "{ffffff}%s ( %d{33cc33}${ffffff} ) ( {00FFFF}%d {ffffff}cars in stock)\n", Stock[xf][vName], Stock[xf][vPrice], Stock[xf][vStock]);
- strcat(stringzz,stringy);
- }
- }
- ShowPlayerDialog(playerid, DIALOG_CARBUY2, DIALOG_STYLE_LIST, "Buy a car", stringzz, "Select", "Close");
- }
- if(listitem == 1)
- {
- new stringzz[5556],stringy[5556];
- for(new xf = 0; xf < MAX_PERSONAL_CARS; xf++)
- {
- if(Stock[xf][vType] == 2)
- {
- format(stringy, sizeof(stringy), "{ffffff}%s ( %d{33cc33}${ffffff} ) ( {00FFFF}%d {ffffff}cars in stock)\n", Stock[xf][vName], Stock[xf][vPrice], Stock[xf][vStock]);
- strcat(stringzz,stringy);
- }
- }
- ShowPlayerDialog(playerid, DIALOG_CARBUY3, DIALOG_STYLE_LIST, "Buy a car", stringzz, "Select", "Close");
- }
- if(listitem == 2)
- {
- new stringzz[5556],stringy[5556];
- for(new xf = 0; xf < MAX_PERSONAL_CARS; xf++)
- {
- if(Stock[xf][vType] == 3)
- {
- format(stringy, sizeof(stringy), "{ffffff}%s ( %d{33cc33}${ffffff} ) ( {00FFFF}%d {ffffff}cars in stock)\n", Stock[xf][vName], Stock[xf][vPrice], Stock[xf][vStock]);
- strcat(stringzz,stringy);
- }
- }
- ShowPlayerDialog(playerid, DIALOG_CARBUY4, DIALOG_STYLE_LIST, "Buy a car", stringzz, "Select", "Close");
- }
- /*if(listitem == 3)
- {
- new string2[MAX_STRING];
- format(string2,sizeof(string2),"Sparrow - 230 premium points\nHotring Racer - 250 premium points\nVortex - 250 premium points\nHotring Racer A - 250 premium points\nHotring Racer B - 250 premium points\nMaverick - 300 premium points");
- ShowPlayerDialog(playerid, DIALOG_CARBUY8, DIALOG_STYLE_LIST, "Buy a car", string2, "Select", "Close");
- }*/
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement