Understanding Track Wad -which files do what?

Posted by RuiTap 
Understanding Track Wad -which files do what?
Date: July 22, 2021 12:47PM
Posted by: RuiTap
I like to to build tracks but after building 5 of them I still dónt undertsand fully the logic of some files and folders that make a wad track.
So I decided to initiate this topic where everyone who knows something about them can share.
I think that a topic like this will be very useful for all those that like to modify and create new tracks.
First I have to leave here all my admiration for the work of Laurent Rousseau aka Lo2k ( for GPbuilder and the other tools) and also PrBlanco (and F1 virtual team) who gave me a great help with the only video tutorials with great quality there are out there.

First I'll write down what I know so far:
*.gp4 ; *.dat;*.bin and *.col - the files that are the core of a track !
*.crd - crowd flashes ? ( i hate the flashes but dont know if it can be removed , i think so...)
*wdt - weather ... controls the light and the sky dome if the track as one.

Now the folders and files that I dont fully understand
*.env - environment ? what is the relation with the tga files that begin with env****.tga ?
*.vcl - what is is it for ?
*.ccl - what is is it for ?
*.hze - what is is it for ?

Folder "resources":
trackmaps.tex - they show an image of the original track but dont understand ...
tarmacmap.tex; tarmacmap1.tex - i think they control the color and definition of the real tarmac in the game, why different versions ( is it like Lods?)
Folder "samples/reverbdata" and "samples/crowddata"


Finally some simple random questions about object Classes and other stuff:

The CROWD class objects always cast flashes or only if the have FULL in their name?
How to control the red lights animation in the start ?
In a tunnel can i make the tarmac always darker ? I know it has something to do with with inverting normals in the BIN file but does it work ?
The only way to control bumps is inside an ini file ?
Is there anyway to animate exterior objects (like helicopters or water) besides using atx_flag*.txt textures ?

Please share your knowledge for those like me that haven´t found the complete answers in the old topics.
Re: Understanding Track Wad -which files do what?
Date: July 22, 2021 12:56PM
Posted by: Noog
I'll take the easy one:

0 ; [MAIN VIEW] Draw crowd camera flashes

(In the f1graphics.cfg, about halfway down).
*.env - environment ? what is the relation with the tga files that begin with env****.tga ? reflection of a static environment on cars and helmets
*.ccl - what is is it for ? best line used by cars controlled by computer
*.hze - what is is it for ? heat haze effect
In a tunnel can i make the tarmac always darker ? I know it has something to do with with inverting normals in the BIN file but does it work ? invert normals on the bin file and place the bin file inside the track somewhere in the resources folder in the gp4 main directory
Is there anyway to animate exterior objects (like helicopters or water) besides using atx_flag*.txt textures ? not possible at the moment



My Grand Prix 4 Files

I'm a total dick. How many people can say that?
Re: Understanding Track Wad -which files do what?
Date: July 22, 2021 02:12PM
Posted by: Prblanco
Lots to answer, let's go! Hope I don't repeat what was answered already. Starting by the .wad and its files...

.ccl - This is a GP4Builder exclusive format, not read by the game, so no need to store it in the .wad. Used to import/export cc-lines.

.cfp - This one stores the crowd flashes positions. I tried editing a .cfp file once but couldn't see any change ingame. I believe flashes have no relation to CROWD_ objects, that is, you can delete these objects and still have flashes, but it's been a long time since I tested this so I might be wrong.

.env - Specifies which corresponding textures (env*.tga) are used by static reflections in specific track sectors. From what I can see, there is one default reflection (usually envface*.tga) and this file specifies the sector ranges where an alternate reflection map is used instead. Not used if dynamic reflection is enabled.

.hze - Properties of the heat haze effect, when enabled ingame. It's in plain text, I believe its format to be three coordinates for position (X, Z, Y - see below), three for size, and two for orientation. Never run tests on it so I can't guarantee.

.vcl - No idea.

weather.wdt - Skydome properties and general track lighting parameters, some nice investigation on it has been done here: https://www.grandprixgames.org/read.php?4,1044268. One thing to note is it affects only the game-generated skydome; if the track has a 3d skydome (which many custom tracks do), its properties are determined in the .gp4 file as any other 3d object.

resources\tarmacmap.tex - Used only if "bump mapping" is disabled in graphics options. This could be any texture (you could make a Mario Kart Rainbow Road with it), but tarmac color always reverts to gray if bump mapping is enabled. I don't know why there is a second texture for this, not all tracks have the second one.

resources\trackmaps - This folder contains the images used by the ingame map if "Arcade overlays" are enabled.

samples\reverbdata - This folder contains the reverb.bin file, which controls the noise reverb effect (most noticeable at Monaco tunnel). GP4 has four reverb "modes": no reverb, reverb above (bridges), reverb on sides (used in Monaco where many buildings are close to the track, and also Spa where there is tall terrain next to the track), reverb above and on sides (tunnels). This can be edited with an hex editor, I'll try and remember to describe its format when I have time.

samples\crowddata - This folder contains the .crd file, which control the sources (position and intensity) of crowd noise. Some years ago me and Lo2k realized these had the same positions as CROWD_*_FULL objects in the .gp4, so GP4Builder has the ability to generate a .crd.


Now for general questions... the flashes issue I told all I know above, so let's go to the others.

Red lights animation - All you can do with it is change its position in the [StartingLights] of the .ini file.

Darker tarmac on tunnel - Reversing the normals on the .bin is one option (I don't like the idea of reverse normals, but it works), using a SHADOW class object slightly above track also works (but the effect might not be as good). I don't remember how it's done at the original Monaco track, better answers might be in those files.

Bumps - Can be controlled by the last few parameters of magic data (by the way, the topic on magic data discussion is my absolute favorite https://www.grandprixgames.org/read.php?4,1012878). Alternatively, you can use GP4Builder's Track Profiler to add some randomness to track banking and create bumps as a result.

Animations - Restricted to atx_flag textures as far as I know. File names and number of frames are all fixed and can't be changed.

(X, Z, Y)? - Yes, most coordinates in GP4 are stored in "screen coordinates" while GP4Builder uses "world coordinates" so Z and Y are swapped. I guess one of them is also reversed but can't remember exactly.


I'm not at home so some things I wrote from what I could remember, also thanks for kerley for providing me a .wad to look at and refresh my memory.

General piece of advice, in doubt always look at original, unmodded files; based on the assumption that the game creators knew how the game works, and we modders don't (fully). ;-)


My unfinished tracks: [www.grandprixgames.org]
Send bug reports and track editing questions to f1virtualblog@gmail.com
Re: Understanding Track Wad -which files do what?
Date: July 22, 2021 03:27PM
Posted by: RuiTap
Thanks for your answers.
I´ll save them for future check.
PrBlanco is the best track building teacher ! Thanks a lot !
Re: Understanding Track Wad -which files do what?
Date: September 06, 2021 12:58PM
Posted by: zifox
Prblanco Wrote:
-------------------------------------------------------
> resources\tarmacmap.tex - Used only if "bump
> mapping" is disabled in graphics options. This
> could be any texture (you could make a Mario Kart
> Rainbow Road with it), but tarmac color always
> reverts to gray if bump mapping is enabled. I
> don't know why there is a second texture for this,
> not all tracks have the second one.
>

Thanks for the info, this means that you can't actually have different textures for different parts of the track then. :(

I need to make some tests and see what is actually possible with bump map (I usually don't use it as it doesn't look good).
Re: Understanding Track Wad -which files do what?
Date: September 06, 2021 10:09PM
Posted by: zifox
I have a question regarding "random" patterns and skid marks on the tarmac: how can they be controlled (if they can be)? I'm trying to use a bright tarmac texture, and these overlays are too visible to my taste, as if their color/opacity was fixed and the brigther the tamarc texture, the more we see them.
Also, they are quite crude, is there a way to get more definition, have smoother patterns ?
Sorry, only registered users may post in this forum.

Click here to login

Maintainer: mortal, stephan | Design: stephan, Lo2k | Moderatoren: mortal, TomMK, Noog, stephan | Downloads: Lo2k | Supported by: Atlassian Experts Berlin | Forum Rules | Policy