Jump to content

[IV] Adding new cars to GTA IV: The Thunder Way


Recommended Posts

Thundersmacker

ADDING NEW VEHICLES TO GRAND THEFT AUTO IV:

The Thunder Way

 

 

Well, hello there. I'm Thundersmacker, I'm sure you've seen all of my GTA V conversions and original lore vehicles for Grand Theft Auto IV over on Thundersmacker's Workshop. If your one of the brave souls that has decided to start modding your PC copy of GTA IV you might be wondering, "How do I get all of those great vehicles into my game?" Well fear not! For I have the guide you'll need to add entirely new vehicles to GTA IV. And hopefully this guide will be simple and easy to understand, but forgive me if there are parts I miss or things that might get confusing. I'll do my best, anyway here we go.

 

PART 1: What you'll need.

 

For this tutorial we are going to be using my port of XanaBax's Flash Mk1 that can be downloaded here. Note that the data lines I refer to will usually be in the Readme files included with most mods. They are easy to find once you know what they look like.

 

Alright now before we get started there are a few things we need to do first to start modding GTA IV.

 

Things you'll need:

Notepad (duh)

7zip or WinRAR to open downloaded files

OpenIV

 

This method should work with any version of the game. But be warned that there is a hardcoded limit in the game that will make the game crash after you have added ~30-40 cars. To break this limit you will need a limit adjuster to extend these limits.

 

-For Patch 7 and 8 (1.0.7.0 and 1.0.8.0) there is fastman92's limit adjuster.

-For Complete Edition there is FusionFix (which also works on older versions) that includes a built-in limit adjuster. In FusionFix's ini file, just add "ExtendedLimits = 1" just below the ped budget parameter and it should work. (Thanks to @RecklessGlue540 for informing me of this)

 

Personally, I am using the original base retail version of GTA IV for my guide since that's what I have, I have no experience with the Complete Edition sold on Steam or the Rockstar Store so there may be some differences.

 

Also also, always remember to back up your files before modding them just in case something doesn't work so you can go back to a working game!

 

PART 2: Creating new files for the new vehicles.

 

Open the Flash Mk1 Mod zip file with the program you chose, then go to the "BS4 Sedan" folder and open up the "Data Lines" text file. Leave that open for now.

 

Go to your GTA IV installation folder and go to common > data. Right click and go to New > Text Document. Go back to the "Data Lines" text file that you left open and copy the "handling.dat" line to your new document.

 

handling-dat-mod.jpg

 

Save that new text file as "added_vehicles_handling.dat" Be sure it saves as a .dat file since that's the format the game needs it to be.

 

Now, download this file. It's a new blank vehicles.ide file with all the default lines that it needs to function in game.

 

Once downloaded, open it. Then go back to the open "Data Lines" text file for the Flash and copy the "vehicles.ide" line to the blank vehicles.ide file you downloaded just below the "# planes have one extra field model id of low level of detail" line.

 

vehicles-ide-mod.jpg

 

Save this file to the common > data folder in your GTA IV directory as "added_vehicles.ide" Again, be sure it saves as an .ide file so the game can load it.

 

Now we'll open up OpenIV (no pun intended). Get your GTA IV all set up in the program and once it's ready head over to pc > models > cdimages. Now turn on "Edit Mode" over in the right corner of the program by clicking it, it should now stay highlighted.

 

Go over to New > GTA IMG Archive (.img, Version: 3)

OPENIV-mod.jpg

 

A window should popup asking for the name of the new image file. Enter "added_vehicles", and it should appear with the other files now. Double left click on your newly created .img file to open it.

 

Now go back to the .zip file for the Flash and go back to the "BS4 Sedan" folder and extract the "flash4" .wtd and .wft files to a folder of your choosing.

 

Head back to OpenIV and go to "New" again and click "Add". Now find the folder you extracted those files into and select both of them then click "Open". The files should now be in your new .img file.

 

OPENIV-mod2.jpg

 

That should be it for that, now onto the next part.

 

PART 3: Making the game load these new data and model files.

Go to your GTA IV installation folder and go to common > data. Find the default.dat file and open it.

 

default-dat-og.jpg

 

Now at the bottom before the "HTML http:" line we'll add "HANDLING common:/data/added_vehicles_handling.dat" then save the file.

 

default-dat-mod.jpg

 

Now, open "gta.dat" in the same folder and scroll all the way to the bottom. Add "IDE common:/DATA/added_vehicles.ide" then save the file. Be sure that line is at the very bottom.

 

gta-dat-mod.jpg

 

After that, we'll open the images.txt file and again scroll all the way down. Add "platformimg:/models/cdimages/added_vehicles    1" to the bottom of the long list of files there.  Be sure that "1" is at the end of the line otherwise the game will not load the model!

 

 

images-dat-mod.jpg

 

When your done, save that file. We have a few more things left to edit in the next part.

 

PART 4: Editing existing game files for paint colors and camera views.

 

Now that we have the new data files created and the game will load them, we need to edit some existing game files for other features to work.

 

Paint Colors

 

In the common/data folder. Open carcols.dat. Scroll down to where you start seeing familiar car names.

There are two sections in the carcols file. The car3 section is for vehicles that use 3 colors (primary,secondary,pearlescent). And the Car4 section at the bottom is for vehicles that use 4 colors (primary,secondary,pearlescent,fourth)

 

Since the Flash we're installing uses only 3 colors we'll put it in that section. Go back to the open "Data Lines" text file for the Flash and copy the "carcols.dat" line to the carcols.dat file.

 

carcols-dat-mod.jpg

 

I like to keep them in alphabetical order but as long as you have it in the respective section it shouldn't give you any issues.

 

Camera Positions

In the common/data folder. Open vehOff.csv. This file is an odd format and Windows likes to open it with Excel. Notepad is the better program to view and edit it, so use that instead.

 

Now you'll see many lines with each vehicle having multiple lines (20). These are for the cinematic and "first person" views that the game has.

 

For this, you can put your new group of lines anywhere as long as you don't break the groups for the other vehicles. I would recommend just putting them at the end to find them easier, but you can do them alphabetically too.

 

Go back to the open "Data Lines" text file for the Flash and copy the "vehOff.csv" line to the vehOff.csv file.

 

vehoff-csv-mod.jpg

 

Sometimes mods will not have these lines in the Readme file, especially older ones. For that, you can copy lines from another existing vehicle and change the model name referenced to the one of your added mod car.

 

Alright, that's it for the data files for now. Now onto the next part.

 

PART 5: Getting the car in game.

 

Now you've got all your data lines and your model set up, but now we have to be able to get the car in game so we can drive it. There are a few ways of doing that.

 

Option 1: Trainer

 

The easiest way to obtain your newly added car is to just use an available trainer to spawn the vehicle.

 

There are quite a few to choose from but these are the ones I know of:

Simple Native Trainer by sjaak327

Zolika1351's Trainer by Zolika1351

 

I personally use SNT, so I don't know much about Zolika's. But that's up to you which one you want to use.

 

Option 2: Editing cargrp.dat

 

The other option is to have the new car spawn in traffic naturally in the game world. While it takes time to actually find the car, it is a much more immersive option.

 

The cargrp.dat file is much like the one in San Andreas, it has different zones for different people and cars to appear in different parts of the city.

 

cargrp-dat.jpg

 

I don't know the exact details of these spawn zones but here's what I know:

 

HARLEM=North Holland (where Dwayne and Playboy X live)

BRONX=Bohan (where Manny and Elizabeta live)

JERSEY=Alderney (northern mostly)

UPTOWN=Airport and by Middle Park

QUEENS=Dukes

BROOKLYN=Broker

MIDTOWN=Downtown Algonquin (by Star Junction)

BLACK_POOR=Mostly Holland and Firefly Projects

FASHION=Unused

BOHEMIAN=Varsity Heights, Middle Park West

TRENDY=Suffolk, The Triangle (Where Tony Prince lives)

RUSSIAN=Labeled as GENERIC in the popcycle file. This group spawns in The Exchange and oddly, Happiness Island. (where there are no cars) 🤷‍♂️

ITALIAN=Little Italy (Where Ray Boccino's restaurant is)

EASTERN_EUROPEAN=Hove Beach again

SHOPPING_AVERAGE=Mostly the areas that aren't listed, kind of the default spawning cars

SHOPPING_RICH=Unused

SOUTH_AMERICAN=Cerveza Heights

CHINESE_JAPANESE=Alderney City and Chinatown

DOCKS and FACTORY=Acter Industrial, Boabo and East Hook

BUSINESS HIGH and LOW=The Exchange and parts of Alderney City

PARK=Middle Park and Meadows Park

 

Again these are guesstimates, so I'm probably wrong on some of these.

 

The other sections are mostly self explanatory. The gang cars will only spawn driven by gangs and will spawn in the first color listed on the carcols.dat line and will spawn with gang parts if they are set up, they also will always spawn first when entering a new zone. The BORING_SALOONS group should be actually be used for rare cars as it that group makes those vehicles MORE rare rather than common. The ONLY_IN_NATIVE_ZONE group is useful for cars that you want to not spawn in traffic like race cars or special cars, which we'll get into that in another guide.

 

To add your car to this file, simply add the model name of the car to the group of your choosing. Be sure to have the model name and a comma at the end so the game will recognize it.

 

cargrp-mod.jpg

 

Once saved, go back into the game and explore around until you've spotted your added car in the traffic. Tip: If you want the car to appear quicker add the car to the righter side of the group. And if you want the car more rare, add the car to the left side.

 

Option 3: Adding Spawn Points to the game world

 

There is one more way to get your added cars to spawn, and that's by actually adding (or replacing) parked car spawn points on the map. Check out this separate tutorial I made on how to do it.

 

 

PART 6 (Optional): Adding more immersion through new sounds and new HUD names.

 

Okay, so you've got your car in game and it's working fine and everything is hunkey dorey. But there's something off, the car sounds just like another vanilla car and it doesn't have the correct name on the HUD.

 

Luckily with fastman92's limit adjuster, there is a way to fix that.

 

NOTICE: Unfortunately, fastman92's limit adjuster only works on games up to patch 1.0.8.0. So if you have any later version you will need to downgrade to use the custom audio.

 

Install fastman92's limit adjuster be sure your game still works with it installed, then open "fastman92limitAdjuster_GTAIV.ini" in the GTA IV directory.

 

Scroll down to the [ADDONS] section in the ini. You'll see "#Enable vehicle audio loader = 0" and "#Enable FXT loader = 0"

 

Remove the "#" from the lines and change the 0 to a 1 on both lines.

 

fmla-mod.jpg

 

Now with that file saved, go to the "FXT" folder that you added when installing the limit adjuster and open the "vehicles.fxt" file.

 

In this file below the text add "FLASH Flash"

 

fmla-mod2.jpg

 

Save that file. Now go back to the "added_vehicles.ide" file in the common/data folder. Change the "BLISTA" name in the data line to "FLASH" then save the file.

 

fmla-mod3.jpg

 

Now go back in game and get the car again. When you enter it you should now see that the HUD says "FLASH" instead of "BLISTA" now. Great it worked! But wait there's a problem, your car doesn't have sound now. Uh oh. But don't worry the limit adjuster has one more trick!

 

In the GTA IV directory go to pc > audio > Config and open the "addedVehicleAudioSettings.ini" file that was also added when installing the limit adjuster.

 

One last time go back to that "Data Lines " text file for the BS4 Sedan Flash and scroll down to the bottom. There should be one last group of data lines called "addedVehicleAudioSettings.ini" ( fastman92 limit adjuster audio loader sounds )

 

Select all the text in that group and copy it to the addedVehicleAudioSettings.ini file. Be sure that line has the model name of the car you've added or it will not work.

 

fmla-mod4.jpg

 

After saving that file go back in game and get the car again. If everything is done right your car should now have sound again! Hooray! And you notice it has a different tone to the original Blista sound it was using. That's something for another time.

 

Much like the vehOff lines these are not included in every mod. So you can go to "gtaiv_vehicleAudioSettings.ini" to find a suitable sound from an original GTA IV car to use. All you need to do is change the model name at the top and it should work. Note that when using FLA audio, every new car MUST have an entry for the audio to work as FLA uses the new ini files included to load the audio rather than using the vehicles.ide line.

 

But there you go, that should be all you need to properly add a new car to GTA IV! This also means that the old days of car wash glitches and SMPA60 errors should be gone. There are more things that I will add to this tutorial later on mostly involving using the limit adjuster to get past the hard coded limit of vehicles that you can have in the game.

 

Until then, enjoy your newly added content to what is an already excellent game, even if it is a bit tricky to get going on PC. Big thanks to JulioNIB for writing up the original tutorial on how to add new vehicles to the game with out save issues, as I would probably still be creating a new game every time I added a new group of vehicles.

 

Feel free to leave feedback on this tutorial if you want or if you've found a shortcut or trick that can ease the process. I know of the Modloader that Zolika made but I have never personally used it, and I know that newer versions of the limit adjuster can give the ability to add all new carcols.dat and Vehoff.csv files to better organize your added vehicles. But I'm a bit old school and this was the best method for me and the one I know best, so forgive me if I missed something that makes the process easier.

 

But thanks for reading my guide and keep an eye out for newly added tricks I'll add in the future. And be sure to check out my workshop for more quality converts and original content for GTA IV! ;)

 

 

Edited by Thundersmacker
Link to comment
https://gtaforums.com/topic/990265-iv-adding-new-cars-to-gta-iv-the-thunder-way/
Share on other sites

Spoiler

Tfw there is no "Lightning Way" because Lightning McQueen goes kerchoo.

Jokes aside, I'm glad that there is a more updated and comprehensible guide for adding cars in GTA IV.

 

Additionally, I think RIL.Budgeted could be added as an optional mod to add better vehicle spawning pool and better spawning cycle. I know the mod is quite finicky and may cause some bugs, but when you add 100+ cars, it would be harder to cycle each cars from the cargrp.

  • Like 1
LamboFreak

Just wanted to give a huge thank you for posting this. I've used this method for a very long time to add cars, but the ending with adding sounds and GXT entries gave me the push I needed to finally get FLA working. Adding cars and all is nice, but seeing the name in the corner and having a custom sound is the icing on the cake.

 

I've been messing with it a little for my Sigma-Three and I'm considering updating it with an optional FLA custom sound. This whole thing is making me want to do more IV stuff.

  • Like 2

Something I wish we could address in IV is the limit of vehicle soundbanks that can be played simultaneously at any given moment. This is made evident if you use RIL.Budgeted as unbid suggested, eventually cars will start spawning completely dead silent because of this, and it won't be until some vehicles are despawned that silent vehicles regain their sound. I doubt any of the current limit adjusters can work around this.

  • Like 4

I think the issues only happen if you attempt to add to the original vehicles.ide file, especially if you mess up with the original order of vehicles there. Everything in IV has an internal, non-fixed ID (unlike in previous games where each object had a fixed one visible on the ide files) and if you add something in between two original objects you are pushing anything after that object in the sequence of IDs one slot forward, and messing plenty of things up. I remember seeing things like a ship in the middle of Algonquin, but only visible up close and with no collision.

  • Like 2
6 minutes ago, xiraco said:

Is there a limit to the vehicles that can be placed in the added_vehicles.img (or in general)? I've been having a problem (for months now) with my game crashing after 5- 10 minutes of play because of added cars.

Not sure if this is your issue but I recently discovered there is one variable of FLA regarding vehicles that you must never edit, otherwise it will lead to crashes.

 

In the Dynamic Limits section of the FLA ini file, there's this value which should never be edited:

; Vehicles (140)
#Vehicles = 140

Instead, you must edit this variable in the IDE Limits section:

; Vehicle Models (205)
Vehicle Models = 205
On 5/19/2023 at 9:18 PM, Fred53-ITA said:

What about emergency vehicles? Can i add another police car or ambulance in the game?

You can but they will not work as such as far as I know (for example, police will not use them).

 

 

On 5/19/2023 at 7:00 PM, Nico said:

Not sure if this is your issue but I recently discovered there is one variable of FLA regarding vehicles that you must never edit, otherwise it will lead to crashes.

Thank you so much, it did help a lot actually, the game stopped crashing (finally!), but I still have problems with the world textures loading. As I'm driving around, the world just gets lower quality until it dissapears completely and takes a long time to reappear. Any advice?

3 minutes ago, xiraco said:

You can but they will not work as such as far as I know (for example, police will not use them).

 

 

Thank you so much, it did help a lot actually, the game stopped crashing (finally!), but I still have problems with the world textures loading. As I'm driving around, the world just gets lower quality until it dissapears completely and takes a long time to reappear. Any advice?

Do you have a commandline.txt file set in your game folder?

  • Like 2
50 minutes ago, Nico said:

Do you have a commandline.txt file set in your game folder?

I do, but I'm not too confident in what's in it...

 

Here's a transcript:

Quote

-width 1920
-height 1080
-nomrestrict
-norestrictions
-noprecache
-novblank
-percentvidmem 100
-availablevidmem 16000
-nomemrestrict
-norestrictions

2 minutes ago, xiraco said:

I do, but I'm not too confident in what's in it...

 

Here's a transcript:

When it comes to restrictions, you should either have commands that remove them (-nomemrestrict, -norestrictions) or define them (-percentvidmem, -availablevidmem). Not both types at the same time. It also goes without saying you shouldn't have duplicated commands, or typos.

 

If you want to use the "-availablevidmem" command, you should put the amount of memory of your GPU in megabytes. For instance, "-availablevidmem 4096" if you have 4 GB of VRAM.

  • Like 2
On 5/21/2023 at 2:19 AM, Nico said:

When it comes to restrictions, you should either have commands that remove them (-nomemrestrict, -norestrictions) or define them (-percentvidmem, -availablevidmem). Not both types at the same time. It also goes without saying you shouldn't have duplicated commands, or typos.

 

If you want to use the "-availablevidmem" command, you should put the amount of memory of your GPU in megabytes. For instance, "-availablevidmem 4096" if you have 4 GB of VRAM.

I really have to thank you for the help (especially with such noob stuff). The texture problem improved significantly when only leaving the -nomemrestrict and -norestrictions command. Really, I have been stuck on this for so long I considered not modding one of my favorite games of all time, so I can't stress enough how grateful and relieved I am to see it working mostly as intended!

  • 2 weeks later...

I love the guide, thank you so much for all your time and work!

Just one thing: I noticed, that when I set "Enable vehicle audio loader" to = 1, the beater cars' exhaust backfire doesn't occur anymore, which is quite sad. Do you know of any workaround?

9 hours ago, MiesThies said:

I love the guide, thank you so much for all your time and work!

Just one thing: I noticed, that when I set "Enable vehicle audio loader" to = 1, the beater cars' exhaust backfire doesn't occur anymore, which is quite sad. Do you know of any workaround?

Use an older version of Fastman Limit Adjuster. Newer releases cause that bug. I use 4.2 and Thunder uses 4.3, if you can find either of them or similar you should be able to have the beater effects working.

  • Like 2
17 hours ago, Nico said:

Use an older version of Fastman Limit Adjuster. Newer releases cause that bug. I use 4.2 and Thunder uses 4.3, if you can find either of them or similar you should be able to have the beater effects working.

Thanks for replying! I didn't know that. Do you, by any chance, have a link to an older version? I couldn't find any. Or maybe upload your version somewhere? That'd be cool!

6 hours ago, MiesThies said:

Thanks for replying! I didn't know that. Do you, by any chance, have a link to an older version? I couldn't find any. Or maybe upload your version somewhere? That'd be cool!

https://www.gtainside.com/en/sanandreas/tools/103533-fastman92-limit-adjuster-4-2/

 

It's posted as a San Andreas mod but it contains files to make it work with all other GTA games available on PC as well.

  • Like 2
  • 2 weeks later...
MitchMaljers


I've got everything working and did everything as instructed in the guide, however I still can't get the custom audio for vehicles to work. Perhaps I did something wrong with the install of the Fastman92's adjuster? I must say the installation guide for it is somewhat unclear. Perhaps you have a idea what went wrong?


The HUD name also isn't showing up when I enter a added vehicle. (in this case the Annis Space)

added_vehicles.ide, added_vehicles_handling.dat AddedvehicleAudiosettings.ini, vehicles.fxt, default.dat are filled in correctly and the other data in the provided Readme is added where it is required.

The fastmanadjuster.ini is configured correctly.

What could be wrong?

Edited by MitchMaljers
wording

Did you install all the contents of the Fastman Limit Adjuster? Including the files at "fastman92 limit adjuster (any version)/files/WIN_X86/plugin" inside the .rar file you downloaded?

Edited by Nico
  • Like 1
MitchMaljers
3 hours ago, Nico said:

Did you install all the contents of the Fastman Limit Adjuster? Including the files at "fastman92 limit adjuster (any version)/files/WIN_X86/plugin" inside the .rar file you downloaded?

Yes

Oh I see, I did forget the plugin files.  :prismkek:

Edit:

Nico you're a saint! If I were in the same room with you I could kiss you right now. Got most of it working so far. The rest should be easy to figure out. Thanks!

Edit2: I added the Phoenix from Thundersmacker which doesn't come with it's own FLA sounds. In the Readme it says the car uses the audio from the Ruiner. Now when I enter it ingame it displays the name Ruiner as it should, however the car doesn't have sound.  

 

Do I need to add "phoenix,         phoenix,        car,        PHOENIX,    RUINER,        VEH@LOW,    VEH@LOW_LE1_RI1,    50,    10,        0.2240,    0.2240,        0.5    4,    1.0    ,1,    ext_strong" to vehicles.ide or added_vehicles.ide?

Edited by MitchMaljers
Thundersmacker

Dang, Nico in here being a good help. Thanks for helping everyone out Nico!

 

10 hours ago, MitchMaljers said:

Edit2: I added the Phoenix from Thundersmacker which doesn't come with it's own FLA sounds. In the Readme it says the car uses the audio from the Ruiner. Now when I enter it ingame it displays the name Ruiner as it should, however the car doesn't have sound.  

 

Do I need to add "phoenix,         phoenix,        car,        PHOENIX,    RUINER,        VEH@LOW,    VEH@LOW_LE1_RI1,    50,    10,        0.2240,    0.2240,        0.5    4,    1.0    ,1,    ext_strong" to vehicles.ide or added_vehicles.ide?

 

When you use FLA audio, every car has to have an entry in the addedVehicleAudioSettingsAudio.ini. You can't re-use sounds from other cars. You can copy the audio data from another car, but be sure to change the model name at the top of the data to the new car. So instead of [ruiner] change it to [phoenix].

Edited by Thundersmacker
Chunk Norris

Also I think it's important to note that if there are too many different vehicles sounds in the game then some vehicle simply won't have any sound (some kind of memory limitation) for several minutes.

I never found a solution to this problem, a workaround I use is to change the sound of added vehicles to that of a vanilla vehicle.  Obviously not the best solution but better than cars with no sound ruining the immersion.

 

 

15 hours ago, MitchMaljers said:

 

Do I need to add "phoenix,         phoenix,        car,        PHOENIX,    RUINER,        VEH@LOW,    VEH@LOW_LE1_RI1,    50,    10,        0.2240,    0.2240,        0.5    4,    1.0    ,1,    ext_strong" to vehicles.ide or added_vehicles.ide?

I would strongly advise you to add every new vehicle to added_Vehicles.ide (or whatever name you use for the file). If you mess with the vehicles.ide file I guarantee you will get save game corruption and have to start a new game

Edited by Chunk Norris

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • 0 User Currently Viewing
    0 members, 0 Anonymous, 0 Guests

×
×
  • Create New...

Important Information

By using GTAForums.com, you agree to our Terms of Use and Privacy Policy.