OpenWorldGames Server ONE

Video games => Grand Theft Auto => GTA-IV => Topic started by: Art Blade on November 12, 2011, 04:14:16 AM

Title: Modding GTA IV
Post by: Art Blade on November 12, 2011, 04:14:16 AM
Almost unavoidably here at OWG we start to mod games when we're allowed to, when there are tools, that is. I'm new to GTA (only just started with IV) so I'm late to modding. When I saw a vid at Rockstar's social club (their website where they host films users made with the in-game video editor) with someone driving a proper ricer (souped-up Japanese car) and drifting the sweet bejeebus out of it.. then I knew it was time to find myself a proper car and start to drift around in Liberty City my very self.  :-D

Using a well-known search engine, I found countless websites that had "GTA4" and "drifting" in common. Looking for a particular car, it wasn't too difficult to find. So I got my file with that 3D car model and then..

the problems.. yes. You can't just drop that file into the game folder and be done, noooooo... far from it.

You need a program to open archives that have the extension "img" as in image and because it is a common graphics file extension my picture viewer software felt compelled to pipe up. Nice. But useless.

Just right here a warning: Before you twiddle around with your games, BLOODY MAKE BACKUPS  >:D

OK.. Now.

By the way: www.7-zip.org (http://www.7-zip.org) to download 7zip, a program that can open all kinds of archives including .zip and .rar archives.

edit
I read you need this here (not sure, was one of the first files I found, I use it anyway)
http://alexander.sannybuilder.com/Files/IVAsiLoader.rar (http://alexander.sannybuilder.com/Files/IVAsiLoader.rar)
/edit

The good thing: You don't need to download any 3D models and that tool. You can just edit the handling file to mod existing cars in a way that you can for example drift with them. But if you want to actually change your car's appearance (3D model) you need this..

http://gtaivtools.googlecode.com/files/SparkIV%200.6.9.zip (http://gtaivtools.googlecode.com/files/SparkIV%200.6.9.zip)

.. to open the car file which is here:

HD:\Steam\SteamApps\common\grand theft auto iv\GTAIV\pc\models\cdimages\vehicles.img

There, in that file, you replace the original car with the model you downloaded and save the file.

You think that's it? Heheheeee.. no. Sorry, but no. If you want to drift (let's say, when you want different car physics) you need to edit the handling configuration file which is located here:

HD:\Steam\SteamApps\common\grand theft auto iv\GTAIV\common\data\handling.dat

That file can be opened with any text editor such as wordpad. Now you need to find the name of the car you just replaced so your new car doesn't just look different but behaves differently, too. At least it will behave differently if you edit the stuff there. Make backups!

So if you want to find out what it means, I'll paste an example code in a moment. Before I do I need to warn you: my code doesn't suit every car there is. I used that code for an Oracle and a Sentinel and both cars flipped when doing quick turns. They really shouldn't do that :) Now, the code is intended to be used with the SultanRS which I replaced with a Nissan GTR model, you can find it here:

http://files.gtainside.com/downloads/ftpf/1295780183_Nissan%20R35%20GTR%20by%20BitMix.rar (http://files.gtainside.com/downloads/ftpf/1295780183_Nissan%20R35%20GTR%20by%20BitMix.rar)

The code for the handling.dat that comes with that file is erm, misleading. At least I didn't know what to do with it because it was more code than could be fit into the file for the car and I needed something that works. I ended up downloading loads of codes and tweaked that car's codes (handling) myself for days until I got quite satisfied with what I got, and here you go (replace the SultanRS handling code with it)

Spoiler
SULTANRS     1400.0  4.0   85 0.0 0.0 0.0 0.1  5  0.50  1.0  180.0 0.34 0.66 1.0 50.0 0.40 1.10 14.5 0.15 0.50 1.2  0.9  0.9  0.15 -0.21 0.0  0.5 0.2 0.2 0.2 0.2 1.2  60000 40442010 078B8041 1

Edit: newest settings
Spoiler

Quote from: Art Blade on November 15, 2011, 12:21:14 PM
My favourite handling setup for the SultanRS/Nissan. Very nice speed and great drifting -- basically I can't drive without actually drifting and burning out my rear tyres  :-D I made the car damage-resistant as far as possible (it is not indestructible). Enjoy :)

Spoiler
SULTANRS     1300.0  8.0   85 0.0 0.0 0.0 0.0  6  0.95  1.0  260.0 0.24 0.76 1.0 50.0 0.30 1.20 14.5 0.15 0.50 1.2  0.9  0.9  0.15 -0.21 0.0  0.5 0.0 0.0 0.0 0.0 1.2  60000 40442010 078B8041 1
/Edit

By the way, the original SultanRS is the Sultan with carbon hood and turbo engine (makes that peculiar noise when releasing the gas pedal) and your new Nissan can be found where the SultanRS was: Top left of the map, leftmost and at the very top there are three roads that lead to nowhere (there is a mansion). Behind the mansion in the bushes is always a new car waiting for you. :)

Done :)
Title: Re: Modding GTA IV
Post by: Art Blade on November 12, 2011, 01:03:10 PM
Just to get an idea, here's a pic. :)

And the matching handling data:

Spoiler
SULTANRS     2500.0  8.0   85 0.0 0.0 0.0 0.0  5  0.90  1.0  260.0 0.24 0.76 1.0 50.0 0.20 1.30 14.5 0.15 0.50 1.2  0.9  0.9  0.15 -0.21 0.0  0.5 0.2 0.2 0.2 0.2 1.2  60000 40442010 078B8041 1

[smg id=3811 type=link align=center width=500 caption="GTA IV 029"]
Title: Re: Modding GTA IV
Post by: Art Blade on November 12, 2011, 02:11:10 PM
I think I finally found a nearly perfect setup for that Nissan/SultanRS:

Latest handling data (  :-() )

Spoiler
SULTANRS     1500.0  8.0   85 0.0 0.0 0.0 0.0  6  0.95  1.0  260.0 0.24 0.76 1.0 50.0 0.30 1.20 14.5 0.15 0.50 1.2  0.9  0.9  0.15 -0.21 0.0  0.5 0.2 0.2 0.2 0.2 1.2  60000 40442010 078B8041 1
Title: Re: Modding GTA IV
Post by: Binnatics on November 12, 2011, 02:59:47 PM
Sounds cool! You really got kneedeep into it.  :-X

Most modders I met (15 year old boys who fool around a bit too easy and too much imho) just pick an application through e.g. gta4mods.com and run whatever they find. They always wanna convince me of the 'beauty' of their mods, which doesn't really interest me. =Yawn=
But this drifting thing interests me. Including the technical steps how to get there.  :-X :)
Title: Re: Modding GTA IV
Post by: Art Blade on November 12, 2011, 03:19:51 PM
Drifting with white-smoking wheels is just fantastic :)
Title: Re: Modding GTA IV
Post by: PZ on November 12, 2011, 05:14:37 PM
Nicely done, AB, and you're right - there are several of us that are interested in modding!  ;)
Title: Re: Modding GTA IV
Post by: Art Blade on November 12, 2011, 06:39:48 PM
Cheers :)

I think something else is worth explaining and apparently it is nowhere to be found (I didn't happen upon it during all my research). The code I pasted. The handling data. What on earth do all those numbers mean? This is what I found out by guessing and testing.

name          A           the vehicle's name
mass          B           how heavy it is
drag          C           atmospheric drag thanks, fragger this seems to play a role in acceleration -> higher=faster
boy          D           irrelevant for cars (how much it submerges in water)
centreofmass          E   F  G           x,y,z weight centre
transmission          Tt   Tg Tf     Ti  Tv           this is interesting: Tt: 1.0 front, 0.0 rear wheel drive, 0.5 =4x4. Tg: how many gears. Tf: the higher, the more acceleration force, apparently 0.0>x>1.0 Ti: no idea, leave it. Tv: How much the steering wheel can be turned in degrees.
brakes          Tb   Tbb  Thb           no idea, looks as if it influences the balance front/rear
steer          Ts           no idea what "steering lock" does
wheel-traction          Wc+  Wc-  Wc-  Ws+  Wbias           looks as if the first two (Wc+,Wc-) influence the front/rear balance. I find a low Wc+ and a high Wc- useful for rear drive drifting.
suspension             Sf   Scd  Srd  Su    Sl   Sr   Sb           no idea
damage          Dc  Dw  Dd  De           damage multiplier, the lower, the less damage, the more resistant.
seat          Ms           no idea, the Japanese car with right driver seat uses 1.2, other cars 0.0
val          Mv           the money value (some say it's for the accumulated amount of damage you caused)
mflags          Mmf           model flags. Reference in the file
hflags          Mhf           handling flags. Reference in the file.
anim          Ma           what kind of animation is used, leave alone.

I think particularly those Mmf and Mhf are sometimes wrong when modders change it. The file states that the digits are hexadecimal for better readability. To me it means you pick one (there are only 1, 2, 4, 8 ) per digit (1st to 8th) and not that you may add them as you do with binary flags (00, 01, 10, 11 and so on). To me, there can't be a "B" (decimal = 11, as in adding hexa 8+2+1=B) but only either 8 or 2 or 1.

However, what I did mostly was change the mass (weight) of the bugger, the lower (1300) the faster it accelerates but it also tends to flip or go over a bridge. High values like trains or buses obviously make it accelerate and braking slower.

Then I changed the drag value (8.0 seems to be the highest).

And the transmission, Tt 0.0 for rear wheel and a high Tg to make it accelerate fast (high is 0.80 for example, low is like 0.22).

And I experimented with brakes and wheel-traction to be able to do sharp turns.

Alright, here you go :)
Title: Re: Modding GTA IV
Post by: fragger on November 13, 2011, 12:04:05 AM
You've been a busy modder, nice w@&k :-X

Something caught my eye there, your comment following the third parameter, "drag". I could be totally wrong but the comment seems to indicate that you're not sure what's meant by "drag", as though it may be a linguistic misunderstanding. It suggests to me "atmospheric drag", i.e. air resistance, so that increasing or decreasing the value would give you lesser or greater acceleration. Guessing.

If I am wrong and you do know what's meant by "drag", then just forget I said anything 8-X :-D
Title: Re: Modding GTA IV
Post by: Art Blade on November 13, 2011, 02:36:20 AM
ah cool.. I think you're right with that atmospheric drag there, fragger :) To me drag meant to drag something behind or around, perhaps its own weight, whatever, didn't make sense.

Now it does, edited, cheers  :-() :-X
Title: Re: Modding GTA IV
Post by: fragger on November 13, 2011, 02:57:01 AM
No worries :)
Title: Re: Modding GTA IV
Post by: Art Blade on November 14, 2011, 06:20:34 PM
Just found out the cars w@&k in MP, too. Police cars modded in a way that they can't get up hills and touching them is almost enough to set them alight. Hehe :) The modded SultanRS as well as the regular Sultan are both available in MP. Very nice (both modded to be used for drifting)  :)
Title: Re: Modding GTA IV
Post by: PZ on November 14, 2011, 07:46:55 PM
Quote from: fragger on November 13, 2011, 12:04:05 AM
You've been a busy modder, nice w@&k :-X

When I think of the phrase "total immersion", I think of our friend, Mr. Blade.  :-()
Title: Re: Modding GTA IV
Post by: fragger on November 14, 2011, 10:09:42 PM
 :-D
Title: Re: Modding GTA IV
Post by: Art Blade on November 15, 2011, 12:33:17 AM
 :-()

[smg id=3813 type=link align=center width=500 caption="GTA IV MP 008"]
Title: Re: Modding GTA IV
Post by: Art Blade on November 15, 2011, 10:33:40 AM
Quote from: PZ on November 14, 2011, 07:46:55 PMWhen I think of the phrase "total immersion", I think of our friend, Mr. Blade.  :-()

By the way, now at 500+ hours in the vanilla GTA IV game, roughly 100 hours for TBoGT and perhaps 60 hours in TLaTD.

Immersive? "Well, kinda."  :-()
Title: Re: Modding GTA IV
Post by: Art Blade on November 15, 2011, 12:21:14 PM
My favourite handling setup for the SultanRS/Nissan. Very nice speed and great drifting -- basically I can't drive without actually drifting and burning out my rear tyres  :-D I made the car damage-resistant as far as possible (it is not indestructible). Enjoy :)

Spoiler
SULTANRS     1300.0  8.0   85 0.0 0.0 0.0 0.0  6  0.95  1.0  260.0 0.24 0.76 1.0 50.0 0.30 1.20 14.5 0.15 0.50 1.2  0.9  0.9  0.15 -0.21 0.0  0.5 0.0 0.0 0.0 0.0 1.2  60000 40442010 078B8041 1
Title: Re: Modding GTA IV
Post by: PZ on November 15, 2011, 02:57:01 PM
Quote from: Art Blade on November 15, 2011, 10:33:40 AM
By the way, now at 500+ hours in the vanilla GTA IV game...

My goodness, that's as bad as I am in FC2  :-()
Title: Re: Modding GTA IV
Post by: Art Blade on November 15, 2011, 03:10:54 PM
I have no idea how many hours I spent in FC2 but I reckon it was at least as many. :) Like 10+ playthroughs and countless hours spent during random free roaming I didn't even save.. I tend to spend like 30 to 50 hours per playthrough.. yes, I am quite certain that I must have spent at least 500 hours with FC2  ^-^ Only with GTAIV it is different because I amassed those 500+ hours during only a couple of weeks.  :-D
Title: Re: Modding GTA IV
Post by: Art Blade on November 15, 2011, 03:30:03 PM
FYI

I edited and updated the initial post in this topic: I realised that I had left out a file when posting but have made up my mind and added it now. Then I added the latest handling setup right below the first one given so you can compare and test.

Enjoy :)
Title: Re: Modding GTA IV
Post by: PZ on November 15, 2011, 04:47:58 PM
Quote from: Art Blade on November 15, 2011, 03:10:54 PM
... I amassed those 500+ hours during only a couple of weeks.  :-D

:o
Title: Re: Modding GTA IV
Post by: Art Blade on November 15, 2011, 11:18:13 PM
let's rephrase that to "a couple of months," then  :-D
Title: Re: Modding GTA IV
Post by: PZ on November 15, 2011, 11:35:15 PM
 :laugh: :-X
Title: Re: Modding GTA IV
Post by: fragger on November 16, 2011, 06:03:05 AM
 :laugh:

I was gonna say... there is only 336 hours in a couple of weeks, and that's if you're playing 24/7. You must be a Time Lord :-D

A couple of months seems more like it :-()
Title: Re: Modding GTA IV
Post by: Art Blade on November 16, 2011, 10:37:45 AM
"A couple" doesn't necessarily describe "a pair" or "a set of two" but may be used in a different context as in "some" or "a few." For instance, if you hear that your favourite female por.. errr, film star, got tight on a couple of stiff.. drinks (perverts!) you wouldn't think "wow, just two of 'em and she falls over." You'd think of all kinds of things but not that she can't even stand two drinks.  :-D So, in a manner of speaking, I was playing a couple of weeks even if those couple of weeks were more like a couple of months which actually weren't two but more likely nearly four.  :-D
Title: Re: Modding GTA IV
Post by: Binnatics on November 17, 2011, 02:00:00 PM
four months and four days to be precise :angel:
first post where I mentioned your start in the game (http://openworldgames.org/owg/forums/index.php?topic=412.msg42152#msg42152)

I checked back and by the way found out that my prediction came true, sort of :-() :-()
QuoteI predict that this topic is going to grow fast

>:D
Title: Re: Modding GTA IV
Post by: PZ on November 17, 2011, 02:08:43 PM
 :-X :laugh:
Title: Re: Modding GTA IV
Post by: Art Blade on November 17, 2011, 02:17:23 PM
 :-D :-X
Title: Re: Modding GTA IV
Post by: Binnatics on August 13, 2012, 11:46:28 AM
Coming back to modding I have to describe the experience with the mod Art made adjusting the car-handling (the handling.dat file). First I was not quite interested in modding but I gave it a chance and the simultaneous changes to both Sultans, Cabs and police cars is a brilliant find, and customized into perfection!!!! :-X

We've had loads of fun already running around in brilliantly drifting sultans and taxis who are fast as hell, and we've had countless laughs about the stupid police cars who get destroyed minutes after appearing, while they can hardly get off their places >:D

Imagine: I haven't even found time yet to experience a modded cab-ride, which promises to be even more spectacular :o

Now Art made a new version of the handling.dat file, with extra changes which I suspect to be even more fun and cool to play around in.

I think this modded file gives just the discreet change to the game to be fun, without endangering the original power of the game. Great w@&k Art, can't wait to try the next level modifications!! A thick fat kudo for your efforts to make this game yet again exciting ;) :-X
Title: Re: Modding GTA IV
Post by: Art Blade on August 14, 2012, 08:07:43 AM
Thanks, Binnatics  :)

Please Check the description of the the first modded handling.dat  (http://www.openworldgames.org/owg/forums/index.php?action=downloads;sa=view;down=169) where you will also find this link (v.1b) to the update (http://www.openworldgames.org/owg/forums/index.php?action=downloads;sa=view;down=170).

Here you can see the white smoke trail caused by a modded cab (as would any sultan) that keeps burning rubber accelerating all the time after you told it to hurry up  ^-^
[smg id=4638 type=type=link align=center width=500 caption="GTA IV modded handling 01"]

This is the slow taxi type and one of the reasons I made the update. The game has three types of taxis but only two data sets for all of them. In order to make the other two taxis "race" and prevent this one from flipping all the time, it doesn't quite drive like the others -- no white smoke trails -- but at least it won't flip any more.
[smg id=4639 type=type=link align=center width=500 caption="GTA IV modded handling 02"]
Title: Re: Modding GTA IV
Post by: Art Blade on October 03, 2013, 12:45:44 PM
The latest version 1.e (already a year old, lol) is now in the downloads.

http://www.openworldgames.org/owg/forums/index.php?action=downloads;sa=view;down=185 (http://www.openworldgames.org/owg/forums/index.php?action=downloads;sa=view;down=185)
Title: Re: Modding GTA IV
Post by: PZ on October 03, 2013, 09:00:24 PM
Wow, I forgot all about modding.  That would make a PC version even more attractive.  :-X
Title: Re: Modding GTA IV
Post by: Art Blade on October 03, 2013, 10:41:36 PM
most certainly. Can't play GTAIV without it any more :)
Title: Re: Modding GTA IV
Post by: Art Blade on September 11, 2014, 11:49:10 AM
I installed Episodes from Liberty City again and added the modded "Peds" file from the vanilla game to the DLC. The "Peds" is a file that contain behavioural data for the Police (cops) which I had modded (see downloads, the version 1e) so that they behave like any random civilian.

If you use that file in your game, cops will no longer chase you, instead they tend to panic.. and you can beat them up like any grandma walking around next to you  :-D
Title: Re: Modding GTA IV
Post by: PZ on September 11, 2014, 09:38:11 PM
Nice!  :-X
Title: Re: Modding GTA IV
Post by: Art Blade on September 12, 2014, 12:45:37 AM
cheers :)

Funny side effect: if you drive around at the airport which gives you I think not five but a four stars wanted level, NOOSE and police will arrive driving around there in one long massive queue or convoy, like a freight train on tyres, and won't bother you at all.  :laugh:
Title: Re: Modding GTA IV
Post by: Binnatics on September 12, 2014, 11:16:52 AM
 :laugh: :-X
Title: Re: Modding GTA IV
Post by: PZ on September 12, 2014, 04:59:57 PM
 :laugh: :-X  kind of like animals in some other games - large but not threatening
Title: Re: Modding GTA IV
Post by: Art Blade on September 12, 2014, 05:23:52 PM
 :) a lot like all those other animals on wheels that cause traffic jams for no apparent reason. At least in this game, I can blow up about all of 'em.  >:D
Title: Re: Modding GTA IV
Post by: OWGKID on March 01, 2015, 11:52:20 AM
https://www.youtube.com/watch?v=ifTIuA8Dq58 (https://www.youtube.com/watch?v=ifTIuA8Dq58)  >:D :laugh: :laugh: :laugh: :laugh: :-D :-() :laugh: :laugh: :laugh: :laugh: Anybody here who have tested negative vehicle friction
Title: Re: Modding GTA IV
Post by: Binnatics on March 01, 2015, 02:37:12 PM
 :laugh:
Title: Re: Modding GTA IV
Post by: Art Blade on March 01, 2015, 04:37:40 PM
omfg LOL :laugh:
Title: Re: Modding GTA IV
Post by: OWGKID on March 01, 2015, 10:39:40 PM
Imagine this in real life  :laugh: >:D :o
Title: Re: Modding GTA IV
Post by: fragger on March 10, 2015, 02:52:20 PM
That's hilarious :laugh: Good choice of music for it too :-X
Title: Re: Modding GTA IV
Post by: OWGKID on March 10, 2015, 11:38:53 PM

The Benny Hill theme can make everything funny  :laugh: :laugh: :-D :-D
Title: Re: Modding GTA IV
Post by: fragger on March 11, 2015, 06:45:41 AM
Yeah, it's a good accompaniment to any kind of craziness :-D

That piece is actually called "Yakety Sax" and was not in fact composed for the Benny Hill show, merely appropriated for it. It goes back a number of years before the Benny Hill shows were made, composed in 1963.
Title: Re: Modding GTA IV
Post by: OWGKID on March 11, 2015, 07:26:12 AM
I know  :laugh: :-D ;)
Title: Re: Modding GTA IV
Post by: fragger on March 15, 2015, 04:07:36 AM
 :)