XeNTaX Forum Index
Forum MultiEx Commander Tools Tools Home
It is currently Mon Sep 24, 2018 12:50 am

All times are UTC + 1 hour


Forum rules


Please click here to view the forum rules



Post new topic Reply to topic  [ 24 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Just Cause 3 Arc/Tab format.
PostPosted: Tue Dec 01, 2015 6:03 pm 
Offline
double-veteran
double-veteran

Joined: Sun Apr 20, 2008 2:58 am
Posts: 840
Has thanked: 5 times
Have thanks: 33 times














You can make the ads go away by registering

If anyone can take a look thanks.

https://www.sendspace.com/file/w516pe


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Wed Dec 02, 2015 12:40 am 
Offline
M-M-M-Monster veteran
M-M-M-Monster veteran

Joined: Wed Mar 31, 2010 6:54 am
Posts: 1627
Has thanked: 61 times
Have thanks: 780 times
You provided invalid TAB file (game33.tab) for ARC (game34.arc). Anyway try this http://aluigi.altervista.org/bms/justcause2.bms


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Wed Dec 02, 2015 9:31 pm 
Offline
Moderator

Joined: Mon Jul 05, 2010 8:55 pm
Posts: 633
Has thanked: 20 times
Have thanks: 248 times
Very simple format. Looked at this yesterday.

1. .tab files contain the filetable, offsets to files and their hashes.
2. .arc contains the actual filedata.
3. Each tab is paired with an .arc file. It also has a .txt file paired containing all the filenames including their hashes (looks like devs accidentally left them over).
4. Don't ask me about compression, some files might be compressed and there's probably a flag somewhere. It should be zlib.

Code:
struct tabFileEntry
{
   unsigned int m_hashedName;
   unsigned int m_fileOffset;
   unsigned int m_fileSize;
};

struct tab
{
   unsigned int m_magic;//"TAB "
   unsigned short m_unk00;//Probably version always 2
   unsigned short m_unk01;//Always 1?
   unsigned long  m_unk02;//Alignment?
   tabFileEntry[numFiles];
};

numFiles = (tabfileSize-0xC)/0xC;

_________________
Click the thanks button if I helped!


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 12:58 am 
Offline
M-M-M-Monster veteran
M-M-M-Monster veteran
User avatar

Joined: Fri Apr 20, 2012 9:24 am
Posts: 2382
Location: Nexus, searching for Jim Kirk
Has thanked: 562 times
Have thanks: 1241 times
yeah, totally easy. You can even cut an uncompressed file from the .arc using a hexeditor and create a wav from it using daemon1's fmod_extr:

Code:
HASH       BYTEOFFSET SIZE       DCOMP SIZE  NAME     
========== ========== ========== ==========  ==========
0x9437BC85 0x00000000 0x0000DD10 0x0000DD10  sound/dialogue/bra/mission_mm220_dial_gameplay_shieldup_010.wavc


btw: it's not from the .arc in the opening post - it's from game55.arc in another parallel thread that obviously has been deleted to not confuse people. :)


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.


_________________
Bigchillghost, Reverse Engineering a Game Model: http://forum.xentax.com/viewtopic.php?f=29&t=17889
extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
Make_H2O-ForzaHor3-jm9.zip


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 10:23 am 
Offline
ultra-n00b

Joined: Wed Dec 10, 2014 5:24 pm
Posts: 6
Has thanked: 0 time
Have thanks: 1 time
Yep, that was my post.. No matter, is there any easier way than cutting this with a hex editor? I mean, the files are 800MB big :D


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 1:18 pm 
Offline
M-M-M-Monster veteran
M-M-M-Monster veteran
User avatar

Joined: Fri Apr 20, 2012 9:24 am
Posts: 2382
Location: Nexus, searching for Jim Kirk
Has thanked: 562 times
Have thanks: 1241 times
easy ways are boring, aren't they?

here you go (tested with Sound Archive game55.arc only!):
Code:
# Just Cause 3, tested with Sound Archive game55.arc only!
# script for QuickBMS http://quickbms.aluigi.org

open FDDE "tab" 0
open FDDE "arc" 1

set EXT string "fsb"

get ARC_SIZE asize 1
get TAB_SIZE asize
goto 12

for i = 0
    savepos CURR_OFF
    if CURR_OFF >= TAB_SIZE
        cleanexit
    endif
    get NAME_CRC long
    get OFFSET long
    get FSIZE long

    math OFFSET += 16
    math FSIZE -= 16
   
    string NAME p= "%08x.%s" NAME_CRC EXT
    log NAME OFFSET FSIZE 1
next i

Will extract 1365 fsb files from game55.arc.
Filenames are not "un-hashed", sry.

_________________
Bigchillghost, Reverse Engineering a Game Model: http://forum.xentax.com/viewtopic.php?f=29&t=17889
extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
Make_H2O-ForzaHor3-jm9.zip


Last edited by shakotay2 on Thu Dec 03, 2015 1:33 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 1:25 pm 
Offline
M-M-M-Monster veteran
M-M-M-Monster veteran

Joined: Wed Mar 31, 2010 6:54 am
Posts: 1627
Has thanked: 61 times
Have thanks: 780 times
Almost finish.

See below.


Last edited by Ekey on Thu Dec 03, 2015 3:57 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 2:45 pm 
Offline
n00b
User avatar

Joined: Sun Aug 17, 2014 10:46 am
Posts: 10
Has thanked: 5 times
Have thanks: 0 time
How can I find a particular file in an .arc archive using hash names in Hex Editor?


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 3:04 pm 
Offline
ultra-n00b

Joined: Wed Dec 10, 2014 5:24 pm
Posts: 6
Has thanked: 0 time
Have thanks: 1 time
CzlowiekDrzewo wrote:
How can I find a particular file in an .arc archive using hash names in Hex Editor?

Get the Byte offset and the length, then a great hex editor like HxD, open the arc file where its inside, calculate the end adress with a hex calculator (byte offset + length), and mark all bytes between the start and end adress. Copy that in a new file and save it as the extension you need, and your done. In HxD you can use Ctrl+E for easier selecting of a range of bytes :)


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 3:56 pm 
Offline
M-M-M-Monster veteran
M-M-M-Monster veteran

Joined: Wed Mar 31, 2010 6:54 am
Posts: 1627
Has thanked: 61 times
Have thanks: 780 times
Ok, unpacker is out. I will share packer later.

https://www.sendspace.com/file/nel9xi


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 6:50 pm 
Offline
ultra-n00b

Joined: Wed Dec 10, 2014 5:24 pm
Posts: 6
Has thanked: 0 time
Have thanks: 1 time
Ekey wrote:
Ok, unpacker is out. I will share packer later.

https://www.sendspace.com/file/nel9xi

Nice, but how to actually extract a file? This looks more like a viewer to me..


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 7:23 pm 
Offline
M-M-M-Monster veteran
M-M-M-Monster veteran

Joined: Wed Mar 31, 2010 6:54 am
Posts: 1627
Has thanked: 61 times
Have thanks: 780 times
iUltimateLP wrote:
Ekey wrote:
Ok, unpacker is out. I will share packer later.

https://www.sendspace.com/file/nel9xi

Nice, but how to actually extract a file? This looks more like a viewer to me..

Just open tab index file. Extracting files will be automaticly! You must see output directory with extracted files in same tab folder > Unpacked. Examples:

Code:
Tab Location: e:\Games\Just Cause 3\archives_win64\game2.tab
Output directory will be here: e:\Games\Just Cause 3\archives_win64\Unpacked


Packer for test only
https://www.sendspace.com/file/hmugmy

Make backup files!


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 7:35 pm 
Offline
ultra-n00b

Joined: Wed Dec 10, 2014 5:24 pm
Posts: 6
Has thanked: 0 time
Have thanks: 1 time
Ah lol didn't know that, thanks for your work!!


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Thu Dec 03, 2015 7:58 pm 
Offline
ultra-n00b

Joined: Wed Dec 02, 2015 4:50 pm
Posts: 1
Has thanked: 0 time
Have thanks: 0 time
Can anyone help me getting a high rez image file of the map pls? Would be very appreciated.


Top
 Profile  
 
 Post subject: Re: Just Cause 3 Arc/Tab format.
PostPosted: Fri Dec 04, 2015 1:21 pm 
Offline
Moderator

Joined: Mon Jul 05, 2010 8:55 pm
Posts: 633
Has thanked: 20 times
Have thanks: 248 times
I don't have the game, is anyone able to share a model file?

_________________
Click the thanks button if I helped!


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 24 posts ]  Go to page 1, 2  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: TSelman61X and 3 guests


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:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group