Ja habe, beim Laden aller Fahrzeuge wird ma p_owner auch richtig beim DEBUG ausgegben.
Es ist an dein jTUT tutorial gehalten.
forward LoadPrivateVehicles_Data();
public LoadPrivateVehicles_Data()
{
new rows;
rows = cache_num_rows();
for(new i=0;i<rows;i++)
{
PrivateVehicle[i][p_modelID] = cache_get_field_content_int(i, "Modelid");
PrivateVehicle[i][p_x] = cache_get_field_content_float(i, "PosX");
PrivateVehicle[i][p_y] = cache_get_field_content_float(i, "PosY");
PrivateVehicle[i][p_z] = cache_get_field_content_float(i, "PosZ");
PrivateVehicle[i][p_a] = cache_get_field_content_float(i, "PosA");
PrivateVehicle[i][p_color1] = cache_get_field_content_int(i, "Color1");
PrivateVehicle[i][p_color2] = cache_get_field_content_int(i,"Color2");
cache_get_field_content(i,"Owner",PrivateVehicle[i][p_owner],Handle,24);
if(PrivateVehicle[i][p_modelID] >= 400 && PrivateVehicle[i][p_modelID] <= 611)
{
printf("Owner: %s (ID: %i)",PrivateVehicle[i][p_owner],i);
PrivateVehicle[i][p_vID] = CreateVehicle(PrivateVehicle[i][p_modelID],PrivateVehicle[i][p_x],PrivateVehicle[i][p_y],PrivateVehicle[i][p_z],PrivateVehicle[i][p_a],PrivateVehicle[i][p_color1],PrivateVehicle[i][p_color2],-1);
}
else
{
printf("[Error] PrivateVehicle Model-ID %d doesn't exist (ID: %d).",PrivateVehicle[i][p_modelID],i);
}
if(GetVehicleModel(MAX_VEHICLES-1) != 0)return print("The Limit of Max Vehicles is reached.");
if(i == MAX_PRIVATE_VEHICLES-1)return print("The Limit of Max Private Vehicles is reached.");
}
return 1;
}