Free Game Research Forum | Official QuickBMS support | twitter @zenhax | SSL HTTPS://zenhax.com
It is currently Fri Nov 16, 2018 7:37 am

All times are UTC

Post new topic  Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Tue Feb 13, 2018 12:04 am 
User avatar

Joined: Tue Feb 13, 2018 12:00 am
Posts: 2
To begin with, I'm fairly new to the game hacking scene. I normally only deal with scripts and graphical editing/ripping from Ace Attorney and Dai Gyakuten Saiban, so I apologize in advance for my ignorance.

I wish to extract graphical and sound assets from the Tengen Toppa Gurren Lagann game. Unfortunately, as with a few games in Japanese on the DS, the files are compressed into .nfp.

There are only two threads from 2008 (With this one being the only one which appears to make major progress) which even touch upon the subject. The second one only briefly mentions that someone had created a tool to extract from it, and provides some basic information on addresses. However, the tool itself is not linked, and no further mention of the file format appears until a 2013 post on asking for information regarding the format.

Any assistance would be appreciated, either direct, or in pointing me in a good direction in regards to where to go to begin working with unknown compression formats.

An archive of the relevant files can be found here.

PostPosted: Tue Feb 13, 2018 9:44 am 
Site Admin
User avatar

Joined: Wed Jul 30, 2014 9:32 pm
Posts: 9236
The only problem of this format is how the data is compressed and where are stored the information about the compressed size.
What I mean is that the TOC (information about the archived files) contains only the filename, offset and uncompressed size, if you go at the offset you can see 4 bytes used only to tell what's the type of file and the rest is a bit chaotic because if you compare the first file of ETC.NFP and the first of SOUND.NFP they clearly have no format in common.

I leave an incomplete script (DOES NOT WORK) to document the TOC:
idstring "NFP2.0"   # "NFP2.0 (c)NOBORI 1997-2006"
goto 0x34
get FILES long
get INFO_OFF long
get BASE_OFF long
for i = 0 < FILES
    getdstring NAME 0x10
    get OFFSET long
    get SIZE long

    savepos TMP
    goto OFFSET
    get ???
    comtype ???
    goto TMP
next i

PostPosted: Tue Feb 13, 2018 7:33 pm 
User avatar

Joined: Tue Feb 13, 2018 12:00 am
Posts: 2
If it helps at all, that thread I linked mentions this:

0x00000000 ~ 0x0000002F a header that says "NFP2.0 ©NOBORI 1997-2002"
0x00000030 ~ 0x00000033 00's
0x00000034 ~ 0x00000037 the number of files contained in the NFP (1695 in this file)
0x00000038 ~ 0x0000003B offset where the file table starts (0x00000040 in this file)
0x0000003C ~ 0x0000003F offset where the individual files start (0x00016990 in this file)

and then comes the file table section. Each file is divided into a 16 byte section:

0x00000000 ~ 0x0000000B the file name
0x0000000C ~ 0x0000000F pointer for the file

Apologies if it's something you already knew. I'm fairly in the dark in regards to what ACTUALLY needs to be done. And I'm not certain if it applies to all nfp files.

Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 posts ] 

All times are UTC

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Limited