Important information: this site is currently scheduled to go offline indefinitely by end of the year.

Final Fantasy XI .DAT (PC)

Post questions about game models here, or help out others!
finale00
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 2382
Joined: Sat Apr 09, 2011 1:22 am
Has thanked: 170 times
Been thanked: 307 times

Re: Final Fantasy XI .DAT (PC)

Post by finale00 »

It looks like even if I tried to skip the start, I don't know how many chunks there are.

I would imagine I would have to determine what kind of data I'm going to read in, cause for sure the textures are all over the place.

But anyways I got a copy of the game so I can start with some of the smaller files...

EDIT: Ok, so everything is stored in DAT files.

Anyways let's just suppose this is a chunk-based format, where it gives the tag along with 4 bytes that identify what kind of information is stored and maybe some counts

The first tag is always followed by 0x 01 01.
There will always be a corresponding "end" chunk somewhere later.

You can see that the texture chunks also some common bytes following it (0x20)

Having this parenthesis matching makes it easier since now you can just do a while loop and build a parse tree from it.

Everything appears to be 16-byte aligned (judging from the pixel data, unless those 00's at the end are common).

There appears to be a chunk size somewhere. For example if you look at shiryu, the "cse0" chunk has token 0x87.
If you look a little further, you'll see 0xD8 or 216. If you look at the size of the entire chunk, it is about that much.

Now look at the "mse0" chunk at offset 0x200. It also has token 0x87, but this time if you look at the chunk size, you see 0x144, or 324.

Again, if you highlight the rest of the bytes until you get to the next chunk ("mse1"), you'll see it is a little more than 324 bytes.
goder2910
advanced
Posts: 45
Joined: Sat Jun 04, 2011 2:36 pm
Has thanked: 13 times
Been thanked: 13 times

Re: Final Fantasy XI .DAT (PC)

Post by goder2910 »

Thank you, finale00 !

Ah i understand a littte on your words.

Like you said, The .Dat format is "chunk-base format", right ?

And every chunk have its size. The first chunk (cse0) has 216, and futher the next chunk (mse0) has 324.

From here, because all things was stored in .DAT file, so we can split these chunks into piece and some chunk will contain vertex or bones , right ?

But the thing that i dont understand is all of .DAT file have same structure or just some of DAT file have same structure?
finale00
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 2382
Joined: Sat Apr 09, 2011 1:22 am
Has thanked: 170 times
Been thanked: 307 times

Re: Final Fantasy XI .DAT (PC)

Post by finale00 »

I would imagine all dat files have the same structure.
I looked at a couple that were dealing with things like UI, and they were stored in the same way.

Some dat files even have only 4 bytes: 00 00 00 00

The textures are pretty much the same things. You just have to see what pixel format it uses to calculate the size of the pixel data.
MrAdults
Moderator
Posts: 1007
Joined: Mon Mar 23, 2009 2:57 am
Has thanked: 44 times
Been thanked: 505 times

Re: Final Fantasy XI .DAT (PC)

Post by MrAdults »

This one's on my todo list already, but it's super-low priority. (well below FF12) I haven't played FFXI in years and have been too lazy to install it again to get at the data as well. I only care for the sake of main-numbered FF series completion in Noesis, because I'm a weirdo like that. I had planned to do it in the form of a native plugin as well...but if you're already working on it in the form of a Python script, I can probably assist if you get really stuck.

On a semi-related note, FF14 should also work in Noesis already. Probably. They may have changed the format since the beta, I never bought the game to test it. I recall chrrox telling me that it does work still. But if they did change it anyway, it's probably a trivial change to make the files load, but I'd have to have some data to see.

Edit: I forgot to mention, also, I came across a PDF at some point which completely detailed this file format and even had animation info. I can't seem to find it now, though. But it's out there somewhere, and should save anyone interested in the format many hours of guessing games. If you do find it, please post it here as well.
User avatar
Rimbros
ultra-veteran
ultra-veteran
Posts: 495
Joined: Fri Jul 09, 2010 12:23 am
Has thanked: 41 times
Been thanked: 16 times

Re: Final Fantasy XI .DAT (PC)

Post by Rimbros »

Final Fantasy its the father and mother of the RPG games, i play the first Final Fantasy in 1985 with the Nintendo, I remember Squaresoft made 2 games to nintendo, one its rad racer a very old game of cars and then made this RPG, because the company are broquen the developers put the name of Final Fantasy to the game like the Final Hope for Squaresoft, now its a big company SQUARE-ENIX, i dont like the fusión and i think the RPG of square lost Quality with the fusión, yest that one with 2 red butoms, and then i play all the final fantasy series, i stop in Online Final Fantasy series coz i really dont like the Online series of this.
If Mr. Adults Already can made Noesis the Official Tool to open the models of the FF series this made the NOESIS a epic tool.
Renders Art by Rimbros
http://s303.photobucket.com/albums/nn12 ... E/Renders/

Personal Game repository samples, send PM
goder2910
advanced
Posts: 45
Joined: Sat Jun 04, 2011 2:36 pm
Has thanked: 13 times
Been thanked: 13 times

Re: Final Fantasy XI .DAT (PC)

Post by goder2910 »

@Mr.Adult It 's hard to find .DAT file structure like you said. I tried to search around the internet 2 month ago but all the link related to FFXI was died. Maybe someone know Japan Language can help us to find .DAT structure in Japanese forum.
finale00
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 2382
Joined: Sat Apr 09, 2011 1:22 am
Has thanked: 170 times
Been thanked: 307 times

Re: Final Fantasy XI .DAT (PC)

Post by finale00 »

Unrelated, but I decided to continue with my MQO plugin for noesis and was testing it on the MQO exports provided.

And here's odin!

Image

Don't tell me they only store half of the model?
Or maybe the export dev decided to store only half the vertices to make it easier for the 3D tool.

And here's half a shiryu...

Image
pixellegolas
ultra-veteran
ultra-veteran
Posts: 423
Joined: Mon Aug 11, 2008 11:30 pm
Has thanked: 27 times
Been thanked: 15 times

Re: Final Fantasy XI .DAT (PC)

Post by pixellegolas »

I think I read somewhere that final fantasy, especially on game consoles where optimized in this way, just storing half models etc. I think I read it connected to ffx on ps2
MrAdults
Moderator
Posts: 1007
Joined: Mon Mar 23, 2009 2:57 am
Has thanked: 44 times
Been thanked: 505 times

Re: Final Fantasy XI .DAT (PC)

Post by MrAdults »

Nope, FFX didn't use any kind of mirroring. FFXII might, though.
Ninja
veteran
Posts: 84
Joined: Sat Feb 26, 2011 3:44 am
Has thanked: 1 time
Been thanked: 20 times

Re: Final Fantasy XI .DAT (PC)

Post by Ninja »

The mirror flag is quite obvious in the Alexander model because there is one object in the model that isn't mirrored.
How the hell do you skin it?
finale00
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 2382
Joined: Sat Apr 09, 2011 1:22 am
Has thanked: 170 times
Been thanked: 307 times

Re: Final Fantasy XI .DAT (PC)

Post by finale00 »

Oh, ya, the towers at the top aren't mirrored lol.

So you've found the flag?
Ninja
veteran
Posts: 84
Joined: Sat Feb 26, 2011 3:44 am
Has thanked: 1 time
Been thanked: 20 times

Re: Final Fantasy XI .DAT (PC)

Post by Ninja »

Yeah, sticks out like a sore thumb.
Headers for the objects in 47.dat (alexander)

Code: Select all

00339008 68685F62 AAB40600 00000000 00000000 01008000 01002000 00003336 53360000 0C005F36 hh_b   ......... . . . ...36S6.. ._6
00339044 00000200 61360000 1407753D 0000C82D 3D6B0000 00000000 00003D6B 00000000 00000000 .. .a6..  u=.. -=k........=k........
00339080 00000000 00000000 10808080 80800000 80450000 803F0000 00000000 803F0000 00000000 ........      .. E.. ?...... ?......
00339116 00000000 00008045 00000000 00430000 00000080 74696D20 20202020 616C7865 3031     ...... E.....C..... tim     alxe01  

00393936 68685F61 2A130400 00000000 00000000 01000000 01002000 0000D21F F21F0000 13000520 hh_a*  ......... ... . ...    .. .  
00393972 00000200 07200000 B404BB24 0000681C 23410000 00000000 00002341 00000000 00000000 .. .  ..   $..h #A........#A........
00394008 00000000 00000000 10808080 80800000 80450000 803F0000 00000000 803F0000 00000000 ........      .. E.. ?...... ?......
00394044 00000000 00008045 00000000 00430000 00000080 74696D20 20202020 616C7865 3031     ...... E.....C..... tim     alxe01  

00427312 68665F70 AAA40400 00000000 00000000 01008000 00002000 00004226 62260000 09006B26 hf_p   ......... . ... ...B&b&.. .k&
00427348 00000200 6D260000 1E058B2B 0000B41E 3F4A0000 00000000 00003F4A 00000000 00000000 .. .m&..   +..  ?J........?J........
00427384 00000000 00000000 10808080 80800000 80450000 803F0000 00000000 803F0000 00000000 ........      .. E.. ?...... ?......
00427420 00000000 00008045 00000000 00430000 00000080 74696D20 20202020 616C7865 3031     ...... E.....C..... tim     alxe01 

00465344 68685F68 AAD30100 00000000 00000000 01008000 01002000 0000F50F 15100000 02001710 hh_h   ......... . . . ...    .. .  
00465380 00000200 19100000 D001E911 0000400B 291D0000 00000000 0000291D 00000000 00000000 .. .  ..    ..@ ) ........) ........
00465416 00000000 00000000 10808080 80800000 80450000 803F0000 00000000 803F0000 00000000 ........      .. E.. ?...... ?......
00465452 00000000 00008045 00000000 00430000 00000080 74696D20 20202020 616C7865 3035     ...... E.....C..... tim     alxe05  

00480304 68685F74 2A1C0800 00000000 00000000 01000000 01002000 00007C43 9C430000 1100AD43 hh_t*  ......... ... . ...|C C.. . C
00480340 00000200 AF430000 DC088B4C 00002835 B3810000 00000000 0000B381 00000000 00000000 .. . C..   L..(5  ........  ........
00480376 00000000 00000000 10808080 80800000 80450000 803F0000 00000000 803F0000 00000000 ........      .. E.. ?...... ?......
00480412 00000000 00008045 00000000 00430000 00000080 74696D20 20202020 616C7865 3031     ...... E.....C..... tim     alxe01  
byte 21 in the object header, if you can't see it. (don't include the offsets in the count)
finale00
M-M-M-Monster veteran
M-M-M-Monster veteran
Posts: 2382
Joined: Sat Apr 09, 2011 1:22 am
Has thanked: 170 times
Been thanked: 307 times

Re: Final Fantasy XI .DAT (PC)

Post by finale00 »

Hmm, so we have a bunch of entries at the top (maybe stuff like bones?), followed by a bunch of textures, followed by vertices, and then followed by faces (which contains mat name as a string, vert indices as shorts, and the UV's as 6 floats)

Another per-face format great...I can see why converting this to MQO was a natural choice just because when I'm looking at it all that comes to mind is MQO MQO MQO MQO MQO MQO
paulgswanson
ultra-n00b
Posts: 2
Joined: Sun Sep 04, 2011 9:00 pm
Has thanked: 1 time
Been thanked: 2 times

Re: Final Fantasy XI .DAT (PC)

Post by paulgswanson »

Sorry to necro this, but has anyone come up with a final solution for this? Sadly i can't read or do code, but using all the apps provided like FFXItools, Metasequia, and ModelViewer I can get the model and texture but none of the animations. And really all I wanted was the animations for retargeting. :( anyone have a already coded solution for this?
Allen
n00b
Posts: 15
Joined: Fri Feb 17, 2012 9:49 am
Has thanked: 7 times
Been thanked: 9 times

Re: Final Fantasy XI .DAT (PC)

Post by Allen »

paulgswanson wrote:Sorry to necro this, but has anyone come up with a final solution for this? Sadly i can't read or do code, but using all the apps provided like FFXItools, Metasequia, and ModelViewer I can get the model and texture but none of the animations. And really all I wanted was the animations for retargeting. :( anyone have a already coded solution for this?
read this maybe help you.
http://gameresearch.haotui.com/thread-343-1-3.html
My friends and I researched this game, but the animation is not complete.
Post Reply