Page 6 of 17

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 7:36 am
by flatz
Hello, again! I haven't included a different stream cipher into my source code earlier because I haven't found a time to refactor some of its functions (generate_key_stream and generate_key), but they works fine. However I've tested them only on GT5. I think this algorithm is the general one and should work on several files, but you need to specify a correct seed to decrypt the file you want. I've included a seed for MOVIE/tv_451_120285132.pam (from GT5), so you can try to decrypt this one if you add these snippets of code into my source code and compile it: http://pastie.org/private/zssddzm7yqsoibn8s6xr9a
rex1825 wrote:GT5/Academy'13/GT6 will internally work with even more decrypt algo's for the file I'm looking at.
If you have worked with most files can you say which files are encrypted using this algorithm?

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 2:37 pm
by rex1825
0xqk wrote:hi folks, for a first time post, I'd like to offer something - instead of asking any crap questions...
rex1825 wrote:is there any table that states what is what car
Yes, there is. I've got it down for quite some months now. But, I don't like to get anything of that knwoledge into the wild public.
So "rex1825" - feel lucky as you've won a "gimme 10" voucher.

Name 10 Cars(either in game body ID or general ID or extracted folder modelcode)/COURSES NAMES while telling me what ID/NAME yout want (English Name, like the game would display them).
And I'll post their extracted counter part like exact name/body id/modelcode/whatnot in return..

I haven't automated their name extraction, as I'm not interested about that for like some months anymore.
I would have a "manual" look into a database for these car names/body id/modelcode/other relation/you name it.

And no, it's not a file that flatz's tool (btw, I bow down before his work for like a third time) would decrypt. GT5/Academy'13/GT6 will internally work with even more decrypt algo's for the file I'm looking at.

So, either take my offer or refuse it :)

Regards, q-k
...thanks

These are 3 cars I'd really like to have:

Lamborghini Miura P400
Toyota 2000GT
Honda S2000

if anyone else wanna add some to the list of 10 fell free :)

Cheers...

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 2:47 pm
by EcheloCross
Ferrari formula 1 wrote:Sorry for double posting :)
I'm on my mobile phone now, so I can't post images here,I will return to my pc at sunday ;)

Just take a look here-theese are screenshots from the official polyphony digital presentation of gt6
http://www.google.com/search?q=gran+tur ... CAcQ_AUoAQ

I also want to mention, that adaptive tessellation works only on the one thing:when your rival is getting far away, the game may not change a lod of a car, but use a tesselation to make it look better.

I saw it 3 times, when lexus was leading in the race:rear window was jamming a little, just like if I use a "reduce amoun of polygons" in cinema4d

All the details are must be hidden there :)
Please send me a lod0 model file from gt5.

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 3:04 pm
by rex1825
EcheloCross wrote:Please send me a lod0 model file from gt5.
It is confirmed many times that GT5/6 have high lod models for premium cars, especially those that are used for photo mode.

http://beyond3d.com/showthread.php?s=cb ... b2&t=43975

Code: Select all

Gran Turismo 3, PS2, 2001
Cars - ~2,000-4,000 polygons

Gran Turismo 4, PS2, 2004
Cars - ~2,000-5,000 polygons

Gran Turismo 5: Prologue, PS3, 2007
Cars - 200,000 polygons (probably interior + exterior)

Gran Turismo 5
Cars ~500K photomode
So those thingies must be somewhere hidden...

No bad feeling, thanks for all your effort and work till now m8 :)

Cheers, you got a beer from me when we see us 8D

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 5:07 pm
by EcheloCross
Hmm, I'm seeing more data now

unsigned shorts
Image

front of abarth 500 '09
Image

So looking like this data I suspected to be 48bit floats is just unsigned shorts. Now to find the faces.

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 5:47 pm
by rex1825
EcheloCross wrote:Hmm, I'm seeing more data now

unsigned shorts
Image

front of abarth 500 '09
Image

So looking like this data I suspected to be 48bit floats is just unsigned shorts. Now to find the faces.
I knew you'll make it :) GJ

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 9:37 pm
by EcheloCross
making progress..
still need to find faces, but now parsing all highest lod vertices from body_s automatically, I see the bounding box too, next step is to scale it according to the bounding box

Image

Image

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 9:39 pm
by 0xqk
flatz wrote:If you have worked with most files can you say which files are encrypted using this algorithm?
I'm grabbing all of my information that I'll attach to this posting from the specdb:

/specdb/GT6/DB0105.dat EDIT2 This file is not really being used. I guess it is a leftover as PD have planned to carry over GT5 savegames but abandoned that idea due to heavy savegeame modding at some point /EDIT2
/specdb/GT6/DB0106.dat

These files are encrypted by an algorithm that is not covered in your published source code. They are in fact sqlite3 databases as well.
I'm totally confident that you'll get the two way encryption algorithm of it down in minutes, no doubt. But I'd like to ask you not to make it public.
Although it is quite funny to have the game running with a modded specdb (as I've called it) and every car's price is 1cr, it will somehow allow real bad modding as well. This file is being used by the game to determine "in game" limits for the cars. For example, the boundaries for a custom suspension. like, how low can you set your ridehight.
All of that stuff may be modded right at the source and the game won't even know about bad modding.
Although I don't play the game anymore for quite some time now, I'm reasonable enough to not let my knowledge about the crypt algo go into public and let other unreasonable people go wild on modded specdb's..

The interesting fact about the algo is, I've only seen it being used on the specdb.
It is a static substitution algorithm. It will work for GT5/Academy 2013 and GT6 without changing anything at all.
I haven't checked GT5 Prologue yet, but I guess the seed will also be the name of a desert. Kalahari, Cholistan, Piscinas.. I do see a pattern here :)

I couldn't get the Movie files you've mentioned to decrypt earlier. I haven't tried you new source on them yet. EDIT3: I don't know what went wrong on my side, but I can't see any .pam file in the extracted GT5 folder.. I also don't have a /movies folder in it.. can you provide the file number for that specific movie .pam? I'm then able to extract it from the PDIPFS folder ;) /EDIT3
EDIT I had a glimpse at the new crypt algorithm. I don't think I have seen it before, so this might be the 6th crypt algo they are using.
1 and 2: for savegames (and I'm not interested in making them public either)
3 and 4: the two you are using in your tool, where I've seen the one that is being used on the header (0x00 from file gt.vol) only being used on the header
5: the specdb algo
6: the new algo
/EDIT

All other files (except for specdb and movies), should just decrypt fine with your tool.
I wouldn't say I've looked into everything yet, but I still remember the specdb and movies using another crypt besides the first layer (which is covered in your tool).
rex1825 wrote:...thanks

These are 3 cars I'd really like to have:

Lamborghini Miura P400
Toyota 2000GT
Honda S2000

if anyone else wanna add some to the list of 10 fell free :)
I've made up my mind about it. There's no harm in publically posting them..

I'm not an SQL expert, so bare with me :)

ModelCodes:
select GC.ModelCode,CNA.LabelID,CNA.Name from GENERIC_CAR as GC, CAR_NAME_ALPHABET as CNA where CNA.LabelID = GC.ID;

Courses:
select CRS.ModelName,CRS.label,CRS.NameEng from COURSE as CRS where CRS.PWY = 0 and CRS.Scenery = 0 and CRS.Rail = 0;

You'll have to add leading zeros to the ModelCode until you have 8 digits. For Example:

Code: Select all

RecNo | ModelCode | LabelID | Name
2     | 10002     | 30      | Mazda Atenza Concept '01
ModelCode will need further 3 leading zeros: 00010002
Split it after 4 digits, you'll then have the folder names for /car/:

0001
0002

Which makes in total: /car/0001/0002

and that's the folder for your modelcode..

Courses should just read fine..

Have Fun with it :)

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 11:39 pm
by flatz
0xqk wrote:I couldn't get the Movie files you've mentioned to decrypt earlier. I haven't tried you new source on them yet. EDIT3: I don't know what went wrong on my side, but I can't see any .pam file in the extracted GT5 folder.. I also don't have a /movies folder in it.. can you provide the file number for that specific movie .pam? I'm then able to extract it from the PDIPFS folder
They are not in GT.VOL, they are at USRDIR/movie, if I recall correctly.

Re: Gran Turismo 6 Models

Posted: Sat Aug 23, 2014 11:44 pm
by 0xqk
ah ok. I've extracted GT5 prologue stuff some minutes ago. There's a TV.DAT file on the disc. I guess it will be the same for GT5 and thus provide further files I didn't know about until now. I've never looked into GT5 data that deep like I did for GT6 :)

Re: Gran Turismo 6 Models

Posted: Sun Aug 24, 2014 2:01 am
by EcheloCross
So far, ushort for highest lod is only working for some models, the vertices look like they can have different amounts of bits for different cars.

the following pictures are the (1132 0140 0003 1932 Abarth 1500 Biposto Bertone B.A.T 1 '52)
Image

Image

the reason they're scaled/squished, is I'm not scaling to their bounding boxes yet, working on that now

Re: Gran Turismo 6 Models

Posted: Sun Aug 24, 2014 1:22 pm
by rex1825
@ EcheloCross, is it same for Tracks, or they are easily to extract?

Cheers...

Re: Gran Turismo 6 Models

Posted: Sun Aug 24, 2014 4:14 pm
by EcheloCross
rex1825 wrote:@ EcheloCross, is it same for Tracks, or they are easily to extract?

Cheers...
As far as I can tell, the .rwy files are just the roadway of each track. 32bit floats for vertices and 24bit faces. Also the edges of the roadway seem to be stored as a separate group of 32bit floats and ushort faces, but not nearly as detailed as the data with 24bit faces.

The cNNNx files contain multiple mdl3 and other data. (buildings + objects + etc..)
When I finish the car/XXXX/YYYY/body + body_s I'll go for those.

Re: Gran Turismo 6 Models

Posted: Sun Aug 24, 2014 4:31 pm
by rex1825
EcheloCross wrote:
rex1825 wrote:@ EcheloCross, is it same for Tracks, or they are easily to extract?

Cheers...
As far as I can tell, the .rwy files are just the roadway of each track. 32bit floats for vertices and 24bit faces. Also the edges of the roadway seem to be stored as a separate group of 32bit floats and ushort faces, but not nearly as detailed as the data with 24bit faces.

The cNNNx files contain multiple mdl3 and other data. (buildings + objects + etc..)
When I finish the car/XXXX/YYYY/body + body_s I'll go for those.
Thank you...

Re: Gran Turismo 6 Models

Posted: Tue Aug 26, 2014 7:36 pm
by Ferrari formula 1
Hmmm...
That's very cool and amazing! :D

But i can't really understand,why did they decrypted cars that much,so we can't locate meshes... :?

As i understand,extracting standart cars is already totally done?)
Because i would like to start getting cars out... :roll:

Premium cars have amazing detail,I really hope you can get meshes and textures,guys! 8D

Also,how about DLC cars,like amazing Vision GT cars?
I think they must be downloaded on PS3 harddrive separate from the game Blu-ray...