MYSQL - Associate vehicle IDs
#1

Hi all. I use this function to load vehicles.

PHP код:

function LoadingVehicles()
{
    new 
rows cache_get_row_count(), string[250];
    
printf("Server: %d veicoli sono stati caricati!"rows);
    for (new 
id 1id != rows; ++id)
    {
        if (
id >= sizeof (Veicolo)) break;
        
Veicolo[id][ID] = cache_get_field_content_int(id"ID");
        
Veicolo[id][Creato] = cache_get_field_content_int(id"Creato");
        
Veicolo[id][Modello] = cache_get_field_content_int(id"Modello");
        
Veicolo[id][Costo] = cache_get_field_content_int(id"Costo");
        
Veicolo[id][Creato] = cache_get_field_content_int(id"Creato");
        
Veicolo[id][Colore_uno] = cache_get_field_content_int(id"Colore_uno");
        
Veicolo[id][Colore_due] = cache_get_field_content_int(id"Colore_due");
        
Veicolo[id][Chiuso] = cache_get_field_content_int(id"Chiuso");
        
Veicolo[id][Motore] = cache_get_field_content_int(id"Motore");
        
Veicolo[id][Fari] = cache_get_field_content_int(id"Fari");
        
Veicolo[id][Bagagliaio] = cache_get_field_content_int(id"Bagagliaio");
        
Veicolo[id][Cofano] = cache_get_field_content_int(id"Cofano");
        
Veicolo[id][Carburante] = cache_get_field_content_int(id"Carburante");
        
Veicolo[id][Acquistato] = cache_get_field_content_int(id"Acquistato");
        
Veicolo[id][Distrutto] = cache_get_field_content_int(id"Distrutto");
        
Veicolo[id][DiFazione] = cache_get_field_content_int(id"Fazione");
        
Veicolo[id][Sirena] = cache_get_field_content_int(id"Sirena");
        
Veicolo[id][LimiteCarburante] = cache_get_field_content_int(id"LimiteCarburante");
        
Veicolo[id][vX] = cache_get_field_content_float(id"Posizione_X");
        
Veicolo[id][vY] = cache_get_field_content_float(id"Posizione_Y");
        
Veicolo[id][vZ] = cache_get_field_content_float(id"Posizione_Z");
        
Veicolo[id][vA] = cache_get_field_content_float(id"Posizione_A");
        
Veicolo[id][rX] = cache_get_field_content_float(id"Respawn_X");
        
Veicolo[id][rY] = cache_get_field_content_float(id"Respawn_Y");
        
Veicolo[id][rZ] = cache_get_field_content_float(id"Respawn_Z");
        
Veicolo[id][rA] = cache_get_field_content_float(id"Respawn_A");
        
Veicolo[id][vHP] = cache_get_field_content_float(id"HP");
        
cache_get_field_content(id"Proprietario"Veicolo[id][Proprietario], mysql128);
        if(
Veicolo[id][Creato] == 1)
        {
            
Veicolo[id][vO] = CreateVehicle(Veicolo[id][Modello], Veicolo[id][vX], Veicolo[id][vY], Veicolo[id][vZ], Veicolo[id][vA], Veicolo[id][Colore_uno], Veicolo[id][Colore_due], -1Veicolo[id][Sirena]);
             
        }
    }
    return 
1;

The problem is that vehicle's ID isn't vehicle's in game. I have my custom vehicle's id.

PHP код:

new id sizeof(Veicolo) + 1;
    
    for(new 
1sizeof(Veicolo); h++)
    {
        if(
Veicolo[h][Creato] == 0)
        {
            
id h;
            break;
        }
    } 
I want that loadingvehicles use Veicolo ID.
Reply


Messages In This Thread
MYSQL - Associate vehicle IDs - by DarkLouis - 10.06.2015, 08:14
Re: MYSQL - Associate vehicle IDs - by Vince - 10.06.2015, 08:18
Re: MYSQL - Associate vehicle IDs - by DarkLouis - 10.06.2015, 08:20
Re: MYSQL - Associate vehicle IDs - by mamorunl - 10.06.2015, 08:40
Re: MYSQL - Associate vehicle IDs - by DarkLouis - 10.06.2015, 08:44
Re: MYSQL - Associate vehicle IDs - by mamorunl - 10.06.2015, 08:51
Re: MYSQL - Associate vehicle IDs - by Konstantinos - 10.06.2015, 09:01
Re: MYSQL - Associate vehicle IDs - by DarkLouis - 10.06.2015, 11:06
Re: MYSQL - Associate vehicle IDs - by DarkLouis - 10.06.2015, 11:15
Re: MYSQL - Associate vehicle IDs - by DarkLouis - 10.06.2015, 11:53

Forum Jump:


Users browsing this thread: 1 Guest(s)