Page 1 of 8

Level files

Posted: Thu Jan 01, 2009 7:17 pm
by someone972
EDIT: For anyone coming across this thread, the most recent and interesting updates are at the end, I suggest skipping there.

I just wanted to share what I've found out about level files, specifically frisco_01.lev. Since I don't plan on doing much of this sort of thing I'll just share what I find when I do.

Long stuff:
In the begining of the file it has a long series of names such as sky01, sky02, cleanwheel, damwheel, hubcap etc. I beleive these are the names of texture files. Using a hex-editor I later came across a series of bytes that looked like image data (see 1 for how). I soon found out that this is a palette (see 2 for how), what is used to provide color information for 8-bit images.

In short:
frisco_01.lev has a series of 8-bit images for textures, some for cars, some for the level. This means that the cars are likely to be contained within these files as well.

1. Color information is usually stored in 4 bytes, one each for red, green, blue, and alpha. I recognised it to be colors since every 4th byte was set to 0, which is usually the case for textures from old games (they have no alpha channel in the image).

2. I found out it was a palette by finding where the bytes mismatched, indicating the end of the colors. I then found the beginning and end of the data and subtracted them, finding the length in bytes. After dividing by 4 I found that there were 256 color entries, indicating a palette.

EDIT: Some more technical stuff:
Up until the 12th byte there doesn't seem to be any information about the images in the initial sequence of names, they are all just null-terminated strings. This means that there is either as many images as names or there is an index file somewhere, possibly one of the short files. I will be examining the first 12 bytes and also other files to find out.

Posted: Fri Jan 02, 2009 10:20 pm
by Fireboyd78
People like you are helping crack the 9 year old mysteries!

Posted: Mon Jan 05, 2009 1:38 pm
by someone972
I have a picture I want to show but I cant figure out how to make an attachment. Do I need to upload it to another site?

Posted: Mon Jan 05, 2009 2:48 pm
by bb_42001
yes.. upload it to photobuck and use the code of forums and paste it here

Posted: Mon Feb 02, 2009 4:02 pm
by someone972
I have found some textures in the level files, I am currently trying to find out how to color them.

Posted: Tue Feb 03, 2009 4:20 pm
by Fireboyd78
use my driver textures account on photobucket

username: drivertextures
password: abc123


please help us crack this god forbidden mystery!!!!

Posted: Wed Feb 04, 2009 8:49 am
by someone972
Image
There it is. This is greyscale since I am only using one byte out of the 4-byte pixel.

Posted: Wed Feb 04, 2009 2:51 pm
by Fireboyd78
DUDE, You are the first person to EVER, and i mean EVER get any texture out of Driver. You are truly amazing. TRULY AMAZING!

We need people like you to help crack Driver! I love you..no homo

Posted: Wed Feb 04, 2009 4:43 pm
by bb_42001
i think he likes you... .lol.. that is so awesome though

Posted: Thu Feb 05, 2009 2:50 pm
by Fireboyd78
how did you do this anyway? manually or some program?

Posted: Sat Feb 07, 2009 5:15 pm
by someone972
I program in C/C++, sp I wrote a program to do it for me. I've been using the Allegro game programming library for a while, so I used that for graphics displaying.

Yay, I got the 100th post in this forum :D.

Posted: Sat Feb 07, 2009 8:01 pm
by bb_42001
what do you mean 100th post? there are 16 000 + posts on here?

Posted: Sun Feb 08, 2009 9:04 am
by someone972
I meant specifically the 'Modifying' section.

Posted: Sun Feb 08, 2009 11:37 am
by bb_42001
Oh i see now.. hahahaha.. good job

Driver Level Textures

Posted: Wed Feb 11, 2009 1:18 am
by Slick
Yeh ive been playing around with this game for a long while too and trying to mod it somehow?? i havn't really got very gd skills in programming but i hav tryed many different things I also discovered that i was able to open ALL the textures from any of the driver *.lev files by opening them in Paint Shop Pro as a RAW file, trouble is they only appear in greyscale, i however changed some of the car textures in one of the vehicles by directly drawing over the car texture in psp and ran the game and the texture on the car did change. Trouble is if there is any way to figure out how to change the colour then modding the textures completely is possible. I also once modded the wheel graphics on the car as well, these came out good because they where kindof in black and white anyway so viewing them as a RAW file in PSP didn't effect their quality.

Posted: Wed Feb 11, 2009 3:09 am
by someone972
What was the effect of drawing over the images? Did you draw over them in color or greyscale? If you used color how did the color of the in-game texture change?

I'm trying to figure out which parts of the image correspond to which colors.

Posted: Wed Feb 11, 2009 3:35 am
by Slick
Yes lets say I drew a scribble over lets say the texture of the miami trees then yeh the scribble would be on the tree when i play the game, however if i drew over the texture with a one of the 256 colours lets say a red in psp for example it never came out as "red" because the colour code is set to a different colour in the level pallette in driver?? make any sense lol

Posted: Wed Feb 11, 2009 4:09 am
by Slick
Do u think theres anyway that a Driver Texture editor can eventually be put together so that any textures from the *.Lev files can be properly edited??

Posted: Wed Feb 11, 2009 4:51 am
by Fireboyd78
Now i know why you could open them as .RAW files - the Driver 2 GFX (PS1) have the car pics contained in .RAW files.

I think we have put together a modding team :D

Posted: Wed Feb 11, 2009 9:39 am
by Slick
Exactly!! another wierd thing that happened was i used a PS1 RAW Graphics viewer and was able to view ALL of the textures in the *.LEV files but heres the next important thing - ALL THE TEXTURES LOOKED A LOT MORE COLOURED than the greyscale way, but not completely but the looked A LOT MORE coloured. Btw im tryin to find the utility now and ill let you all know its name so you can try it out and let me know what u think but i believe we are all truly onto something!!! lol

Posted: Wed Feb 11, 2009 10:02 am
by Slick
Ok ive found it, the name of this utility is PSicture to load up the Driver level textures in it just click File, Open as Raw then browse for the lev file, before you click OK you have to set a few more varibles, you can only view a few textures at a time so to bigger the number set in the Address the deeper you search into the *.Lev files so if you set the number to lets say 800000 in the iview.lev file it displays as far as the wheel textures make sure you set the image width to 512 and height to 512 because this is how the textures seem to look best. Try setting the address to 3000000 in the IVIEW.Lev file LOOK YOU CAN SEE THE COP CAR TEXTURES AND THE DAMAGED COP CAR TEXTURES, let me know what you think

P.S I hope this has all been of help to you all lol because all this has literally taken 2 years of constant playing around and trying different things i figure all this out lol

Posted: Wed Feb 11, 2009 10:09 am
by someone972
Now don't get too exicted (because there is still a lot to do before having a truely functional texture editor), but I got the textures out in color. Sweet, sweet color. :D

Here is a sample:
Image

Technical Ramblings:
Seeing that there were 2 sets of each image I found out that I had the image I was drawing on too big, causing an effect like this:
12
23
56
Where the numbers are the lines of the image. It should have been like this:
1
2
3
4
5
6
When I halved the bitmap width the images aligned properly, but were squished horizontally. This gave me the hint that the images were in truecolor format. I loaded the images in 15-bit color and they displayed fine.

EDIT: Oh my, another post made while I was writing.
EDIT: 2 years, eh? Nice to see some devotion to getting modding done.

Posted: Wed Feb 11, 2009 10:12 am
by Slick
Thats absolutly excellent!!!!!! well done, i think this mystery has been around too long lol did u use your own home made util to this or through PSP?? lol

Posted: Wed Feb 11, 2009 10:15 am
by someone972
I used a home made program. I'll see if I can't find out proper texture loading techniques and get an editor up. Might take a while.

Posted: Wed Feb 11, 2009 10:19 am
by Slick
Thats all great stuff and all shows how possible modding driver can be, are you able to edit the textures and test them in the game ? lol

Posted: Wed Feb 11, 2009 10:36 am
by Slick
Another cool thing btw is that reminds me once i was looking at the textures in the Car Park level and came across the cop car textures, thing was the textures of the cop car looked different to the other levels so i then found out that the earlier design of the cop car was still left unchanged in the level and if you editor the mission and place a cop car in the level you can see it!! lol

Posted: Wed Feb 11, 2009 10:54 am
by someone972
I put a black stipe across a lamppost. I could probably edit the textures better than zeroing out data, but I have things to do right now.

Posted: Wed Feb 11, 2009 1:28 pm
by Nikusakken
Wow, that's cool! Good luck with that! :)

Posted: Wed Feb 11, 2009 9:53 pm
by Slick
At the moment im working a car mod in Driver when im done ill send a snapshot so you can all tell me what you think lol :P What i am aiming to do is allmost redesign a completely new drivable vehicle except i belive no one yet knows how to mod the 3d modelling, however i have been able to drive civillion cars by changing the CIVCAR3 for example to PLAYERCAR1 in the LEV files through a hex editor, similar to driver civcar edition except im doing the modding in the lev files NOT exe's lol. What this means is i will use the VAN civillion car and set it to the PLAYERCAR1 in the lev file, then i will change the textures of the van to look like a JEEP or something similar, but give me a week or so lol

Posted: Wed Feb 11, 2009 10:11 pm
by bb_42001
That would be awesome!