Information on FF7.exe

  • Thread starter Thread starter The SaiNt
  • Start date Start date
Status
Not open for further replies.
I'm back!!!
Wow, I've only been away for a few days and you guys have made the thread so long that i'll have to take some time to read everything through.
Another assumption that I'll think I'll make.
The .DAT files should be within the EXE file.
In fact I think there are many files in the EXE file and I think they are combined in the same format as the .P files.Ficedula: About FF7.EXE making a it's own library of files, I have to agree with you cause if you look in the .EXE file you will notice them refering to files in the LGP with directory structures like flevellibblabala.cpp or such, I think. (This is coming out of my head so don't blaim me if something is wrong)
 
I have to agree with you
There is more evidence to support internal files/libararies;
there is reference to s3d.cpp and s2d.cpp files which are similar in name to the temp files in the ff7 root directory; 2 of them are s2d.p and s3d.p !
 
Erm ... yes. I wouldn't take .CPP files as proving this theory (though I think it's right!) since they're the names of the source code files that the EXE was compiled from. They're probably in there so if something f***s up, an error message pops up telling the programmers which source code file the error occurred in.
 
I wish I had something to add. Unfortunately, at the moment I don't really have anything. Just thought I should welcome The SaiNt back and encourage you three to keep up the good work. I am going to study over this theory, btw.[This message has been edited by Srethron Askvelhtnod (edited January 26, 2001).]
 
congrats on the freak status srethron  :D
ficedula: if they (the temp files) arent libaries/code then what in your opinion are they? if you dont know what they are ive posted the link to then on the first page of the cosmo topic
 
Skillster: I've no idea. All I'm saying is, just because you find filenames like FLEVELFIELDWHATEVER.CPP it doesn't prove FF7 makes it's own "virtual files" to hold data in - CPP files are the source files it was compiled from. I think it probably DOES do that, but nobody's proved it yet.
 
Since this topic is so hot now, I might as well post my question here.
About the .P files do you guys think they are compressed? Although the file size is small it is not unlikely that they have compressed it. Some savegames are still compressed though they are small in size.
 
Unlikely. They tend to compress files either to:a) Save disk space. Hence the levels are compressed since they're quite large (>100MB for thewhole game)

b) Prevent hacking - hence the savegames!
 
While I was analysing the hex data of aaac.p today(I printed it out cause it was too tedious to read it on the screen), I noticed something that might interest some of the people here. Maybe some of you might already have noticed it but I wouldn't know so I'll just tell you guys just in case.Here's a snippet of aaac.p from address
00000270 - 000002E0
**********************************
0200 0000 0000 0300 0300 0100 0000 0400
0400 0300 0000 0500 0500 0600 0600 0000
0200 0500 0100 0700 0700 0800 0800 0100
0700 0900 0900 0800 0300 0700 0800 0200
0400 0700 0400 0900 0500 0A00 0A00 0600
0A00 0B00 0B00 0600 0A00 0C00 0C00 0B00
0D00 0C00 0C00 0500 0500 0D00 0C00 0900

**********************************

Here you can obviously see that a hex value of '00' appears after every one value.

Refering to the example of a .PLY file,
the #poligon section contains no. that are alternated by spaces. This is what I think the hex represents. Any other opinions?

If the .P files are in fact "not compressed",
then the .PlY, .GRP and .MAT files should only be combined into one file and their text would be written in a different ASCII order(assumption again).

If this proves to be the case, then all I have to do is do a statistical appearance of all characters in the .P file. Then, I can check for characters that occur less than 3 times, since the '@' can only appear a maximum of 3 times as a header to describe the version of the .PLY, .MAT or .GRP file.

Anyone have any other opinions on how the files would be combined?
 
Unfortunately, the .P files aren't simple combinations of the PLY/MAT/GRP files. PLY/MAT/GRP are text file formats. .P files, while we all agree they hold the same data, are most definitely binary files. So don't assume they'll contain the same sort of headers, or even have the data in the same order.That said, give it a go!
 
Okay, after looking at the AAAC.P file for a while, i have come to a conclusion that they are definitely not compressed.
This is cause there are many repeated strings of information that can easily be compressed.
Something i would like to add,
I have colour coded the AAAC.P file for easier viewing, and I suggest some of you take a look so you know what I'm talking about.
It's at  [url="<a]http://pwp.maxis.net.my/zhenjock/images/scan1.jpg[/url]" TARGET=_blank>http://pwp.maxis.net.my/zhenjock/images/scan1.jpg  [url="<a]http://pwp.maxis.net.my/zhenjock/images/scan2.jpg[/url]" TARGET=_blank>http://pwp.maxis.net.my/zhenjock/images/scan2.jpg
So far, I assume that the '00's are spaces
and '0000' means next line?
I also noticed that the data in the file can be divided into 3 main parts, divided by three repetitive patterns
7749 61FF and 7CDA 7701
You might also notice that the top most portion consist of many different hex values which i think most likely are text.
The centre portion is made up of very small hex values; usually with at 0 in front like 01 02 03 etc....
The last section is erratic again like the first section so it could be text?
I need to go to sleep now, so if anyone would like to help me out here, feel free to do so. I'll probably check the board again tomorrow morning.
 
Yep, the files aren't compressed.Maybe I'll take a look when *I* get back to my home PC...
 
The Skillster: Thanks. Now I'm a freak here, just like I am in real life.  :)I believe the temp files in FF7 are simply direct copies of .P files, perhaps directly extracted from the .LGPs by the game. Just a guess but maybe when a scene is loaded, the game pre-caches all the character models it needs.

Ficedula:
Re: creating virtual files: Is there anyway I or someone else could prove or disprove whether the game does or doesn't create them?

The SaiNt: Thanks for all the info.
 
Proving the Virtual File theory? Well, if you could show that a file referenced in the EXE like VINCENT.DAT was definitely the limit break - and textures/models used in the limit break came from other files, which you could show to us -that'd be pretty conclusive proof.
However, I'm willing to believe it now - it seems probable enough. Just saying, we don't *know* yet, so don't assume anything. Maybe they are actual files that have been compiled into the EXE.
 
Here's what I can finalize from my 2nd time going through the .P files
This time my example will be aaae.p
You can get it at [url="<a]http://pwp.maxis.net.my/zhenjock/images/scan3.jpg[/url]" TARGET=_blank>http://pwp.maxis.net.my/zhenjock/images/scan3.jpg  [url="<a]http://pwp.maxis.net.my/zhenjock/images/scan4.jpg[/url]" TARGET=_blank>http://pwp.maxis.net.my/zhenjock/images/scan4.jpg  [url="<a]http://pwp.maxis.net.my/zhenjock/images/scan5.jpg[/url]" TARGET=_blank>http://pwp.maxis.net.my/zhenjock/images/scan5.jpg  [url="<a]http://pwp.maxis.net.my/zhenjock/images/scan6.jpg[/url]" TARGET=_blank>http://pwp.maxis.net.my/zhenjock/images/scan6.jpg  [url="<a]http://pwp.maxis.net.my/zhenjock/images/scan7.jpg[/url]" TARGET=_blank>http://pwp.maxis.net.my/zhenjock/images/scan7.jpg Here's what I have noticed:-

1. The top part of the file (00000000 - 00000030) has the same format as the end (00000EF0 - 00000FE0).
2. The hex value C0 seems to appear in a someone arranged order in scan3.jpg
3. The values '5FEF 1040 65FC B33F C959 90BF' appear twice in the same order in scan3.jpg
4. From (000004D0 - 000006B0), a certain order appears. Some of the characters here seem to appear in the aaac.P (refer to last post for details)
5. Data from 000006C0 - 00000E30 seems to have a proper arrangement. It's as if the '00' areas are shelves to keep arrays of data.
6. In between this array of data, '50DA 7701' appears in a regular order (Is this an indicator to divide the data?)
7. This has led me to believe that the whole file can divided into several sections:-
a) The Header (00000000 - 00000030)
b) The Alphanumeric section (00000040 - 000004D0)
c) The file divider? (000004E0 - 000006B0)
d) Numerical section (000006C0 - 00000E30)
e) ?????? Section (00000E40 - 00000ED0)
f) 2nd Alphanumeric section (00000EE0 - 00000EF0)
g) The Footer (00000F00 - 00000FE0)

That's all for now. And yes I know that you can view all of this through the "open as" command in Adobe Photoshop in RAW format. I just prefer the manual colouring way cause I can cut out things which I think are irrelevant cause the PC is somewhat stupid in the sense it can't see certain patterns, it just colours everything.
I really someone like ficedula, Qhimm or Halkun decides to shed some light here. I think I really need some help.

ficedula : My current belief is that the .DAT files are in fact compiled within the EXE itself
 
All right, I can't stand just sitting here while you people whine trying to figure out the .p format...  :wink:Here's the source code for a 3DSMAX(R3) plugin designed to import the FF7 models straight from the data files. It can't handle textures or bone rotation data, but the vertices, polygons and colors are all correctly read, so just examine the source and you should pick up a few helpful pointers.

[url="<a]http://qhimm.3dstream.net/ff7_3d.zip[/url]" TARGET=_blank>http://qhimm.3dstream.net/ff7_3d.zip
 
The SaiNt: Thanks for the continued info. I wish I could do more than comment...Qhimm: This is cool. Hmmm, maybe when I learn a bit more, I can use this code to make a similar plugin for Milkshape...
 
well loads of info here, but werent we discussing the ff7.exe? and what other skeletons (code) is hiding in qhimms cudboard?
 
You mean closet, don't you?   :wink: And yeah, I thought it was the .exe as well, but I'm not complaining about this new breakthrough.   :D Actually, it is sort of related to the .exe because of the .DAT files, right? Well, mostly it's probably your questions about the game creating virtual files. I'm inclined to agree that they must be in the .exe as it's the only current option I see that makes much sense.[This message has been edited by Srethron Askvelhtnod (edited February 01, 2001).]
 
Status
Not open for further replies.
Back
Top