Way to save vehicle info
#2

If you're creating vehicles into files, you need to grab the file ID and the in game ID in the file. That's how I do it at least and it works fine for saving, loading items like that. Example:

PHP код:
#define                 MAX_DYNAMIC_VEHICLES                1000
enum DynamicVehicles
{
    
vehicleID// File ID. 
    
vehicleIG // Ingame ID.
};
new 
FacVehicleData[MAX_DYNAMIC_VEHICLES][DynamicVehicles]; 
And an example of what I've done:
PHP код:
new vehicle GetPlayerVehicleID(playerid), carid IsFactionVehicle(vehicle);
if(
carid != -&& FacVehicleData[carid][vehicleFaction] > && FacVehicleData[carid][vehicleCopGuns] && PlayerData[playerid][pFaction] == FacVehicleData[carid][vehicleFaction])
        {
            
ShowPlayerDialog(playeridDIALOG_USEDIALOG_STYLE_LISTtitlestring"Ok""");
        } 
Reply


Messages In This Thread
Way to save vehicle info - by iBots - 20.05.2017, 08:38
Re: Way to save vehicle info - by Kane - 20.05.2017, 09:03

Forum Jump:


Users browsing this thread: 1 Guest(s)