sau poate e de la asta uitati stock ShowPlayerVehicle(playerid) {
new szTitle[180], szDialog[1300], szDialog2[1300], vstatus[1024];
if(GetVehicles(playerid) == 0) return SCM(playerid, COLOR_LGREEN, "Eroare: Nu ai un vehicul personal!");
format(szTitle, sizeof(szTitle), "Vehicles (%d/%d)", GetVehicles(playerid), TotalSlots(playerid));
for(new i = 0; i < 10; i++) {
if(i < 5) {
if(i < 3) {
if(PlayerInfo[playerid][pCarKey] != 0) {
new car = PlayerInfo[playerid][pCarKey];
if(IsVehicleOccupied(CarInfo[car][Spawned])) format(vstatus, sizeof(vstatus), "{FFFF00}(Occupied){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
else if(CarInfo[car][Spawned] > 0) format(vstatus, sizeof(vstatus), "{26B309}(Spawned){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
else format(vstatus, sizeof(vstatus), "{FF0000}(Despawnat){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
format(szDialog, sizeof(szDialog), "%s\n", vstatus);
strcat(szDialog2, szDialog);
}
else strcat(szDialog2, "{FFD857}<slot liber>\n"), sVehicle[playerid] = 0;
}
else {
if(PlayerInfo[playerid][pCarKey] != 0) {
new car = PlayerInfo[playerid][pCarKey];
if(IsVehicleOccupied(CarInfo[car][Spawned])) format(vstatus, sizeof(vstatus), "{FFFF00}(Occupied){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
else if(CarInfo[car][Spawned] > 0) format(vstatus, sizeof(vstatus), "{26B309}(Spawned){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
else format(vstatus, sizeof(vstatus), "{FF0000}(Despawnat){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
format(szDialog, sizeof(szDialog), "%s\n", vstatus);
strcat(szDialog2, szDialog);
}
else if(PlayerInfo[playerid][pPremiumAccount] == 1) strcat(szDialog2, "{FFD857}<slot liber>\n"), sVehicle[playerid] = 0;
}
}
else {
if(PlayerInfo[playerid][pCarKey] != 0) {
new car = PlayerInfo[playerid][pCarKey];
if(IsVehicleOccupied(CarInfo[car][Spawned])) format(vstatus, sizeof(vstatus), "{FFFF00}(Occupied){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
else if(CarInfo[car][Spawned] > 0) format(vstatus, sizeof(vstatus), "{26B309}(Spawned){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
else format(vstatus, sizeof(vstatus), "{FF0000}(Despawnat){FFFFFF} %s", aVehicleNames[CarInfo[car][cModel]-400]);
format(szDialog, sizeof(szDialog), "%s\n", vstatus);
strcat(szDialog2, szDialog);
}
else if(PlayerInfo[playerid][pSlot][i-5] == 1) strcat(szDialog2, "{FFD857}<slot liber>\n"), sVehicle[playerid] = 0;
}
}
ShowPlayerDialog(playerid, DIALOG_GARAGE, DIALOG_STYLE_LIST, szTitle, szDialog2, "Ok", "Exit");
return 1;
}