if(CI[free] == 1)
{
if(PI[playerid][car1] == 0)
PI[playerid][car1] = i;
else if(PI[playerid][car2] == 0)
PI[playerid][car2] = i;
else if(PI[playerid][car3] == 0)
PI[playerid][car3] = i;
else if(PI[playerid][car4] == -1)
PI[playerid][car4] = i;
xnrGM(playerid, -AHV[ii][preis]);
PlayerPlaySound(playerid, 1054, 0.0, 0.0, 0.0);
CI[i][free] = 0;
new q[128];
format(q, 128, "UPDATE cars SET free = '0' WHERE id = '%d'", i);
mysql_query(q);
ShowPlayerDialog(playerid, 301, DIALOG_STYLE_LIST, "Autohaus", "Rot\r\nGrün\r\nBlau\r\nGelb\r\nPink\r\nWeiss\r\nSchwarz\r\nGrau\r\nDunkelblau\r\nDunkelrot\r\nDunkelgrün\r\nBraun", "Ok", "Ok");
format(q, 128, "> Fahrzeug erfolgreich gekauft. (%s / -%d$)", AHV[ii][name], AHV[ii][preis]);
SendClientMessage(playerid, CL_GREEN, q);
PI[playerid][cint] = i;
PI[playerid][adm_id] = ii;
return 1;
}