Indiana Jones and the emperor's tomb (PS2) HSH+PK2

Extraction and unpacking of game archives and compression, encryption, obfuscation, decoding of unknown files
Game Ripper
Posts: 123
Joined: Sat Sep 02, 2017 12:56 pm

Indiana Jones and the emperor's tomb (PS2) HSH+PK2

Post by Game Ripper »

Hi all, I guess I'm here today to attract your attention to some relatively easy task of unpacking yet another bigfile. I'd be really grateful for some BMS which can automatically extract all contents of that package using given index file.

So we have INDY.PK2, that huge archive holding almost all data used by the game and INDY.HSH, a small plain text file with the following structure (or simply saying lines):

Code: Select all

path1 size1 offset1
path2 size2 offset2
...
pathN sizeN offsetN


where path# is complete filename (for example "Sound/Music/Cin_Music_SFX/m01_1.mib"), size# is decimal filesize & offset# is decimal offset for file start. I attached entire INDY.HSH file to my post so that you can have a look at it.

The reason I'm asking for your help is because ripping this VG might (and definitely will) turn into chores if I actually tried and attempted to extract ~150 BGMs by hand. That's why any QuickBMS code you come up with would be highly appreciated.
Goodbye!
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Indiana Jones and the emperor's tomb (PS2) HSH+PK2

Post by aluigi »

Mygoshi
Posts: 654
Joined: Mon Oct 27, 2014 1:49 pm

Re: Indiana Jones and the emperor's tomb (PS2) HSH+PK2

Post by Mygoshi »

I also wanted to extract data from this game. Your script works, thank you, but you made an error though. It's not NSH but HSH.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Indiana Jones and the emperor's tomb (PS2) HSH+PK2

Post by aluigi »

oh thanks, fixed the link and script
Game Ripper
Posts: 123
Joined: Sat Sep 02, 2017 12:56 pm

Re: Indiana Jones and the emperor's tomb (PS2) HSH+PK2

Post by Game Ripper »

Thank you so much Luigi!
I think I'll also test it on another PS2 game with the same archiving scheme. I don't remember if there're decimal filesizes & offsets in that title but the index file was very similar to INDY.HSH here.
Bye!
Game Ripper
Posts: 123
Joined: Sat Sep 02, 2017 12:56 pm

Marc Ecko's Getting up (PS2) HSH+PK2

Post by Game Ripper »

Hello, I'm trying to unpack bigfiles from another game by the same team & from the same era and I decided it's the best place to ask for help. I hope it's only a matter of a tiny tweak to make above script work on that 2nd title because formats don't seem to differ much.

You see Marc Ecko's videogame uses something pretty similar to Indiana's archives but a bit different: there're 2 PK2 bigfiles & 1 HSH file (actually there's PS2PAK.HSH + PS2PAK.NEW but both seem to contain info about the same amount of files; my guess is that PS2PAK.NEW should be preferred to PS2PAK.HSH); the latter has such lines:

Code: Select all

path1 X size1 offset1
path2 X size2 offset2
...
pathN X sizeN offsetN


where N is the number of the last contained file & X is either 0 or 1. This argument should point at the 1st or the 2nd PK2 archive (PS2PAK_0.PK2 or PS2PAK_1.PK2 respectively), that's the only theory I've got but it looks plausible.

This time I attached samples to my post; if you need cuts from PK2 bigfiles tell me and I'll post them too.
Best regards!
Game Ripper
Posts: 123
Joined: Sat Sep 02, 2017 12:56 pm

Re: Marc Ecko's Getting up (PS2) HSH+PK2

Post by Game Ripper »

Last edited by Game Ripper on Wed Jan 30, 2019 6:43 pm, edited 1 time in total.
Game Ripper
Posts: 123
Joined: Sat Sep 02, 2017 12:56 pm

Re: Marc Ecko's Getting up (PS2) HSH+PK2

Post by Game Ripper »

I found some sort of a solution and here it is for anyone interested: open PS2PAK.NEW (or PS2PAK.HSH if you want) in a text editor, cut the first 2578 lines, paste those in a new doc and save it as PS2PAK_0.HSH. Then save your edited smaller PS2PAK.NEW or PS2PAK.HSH file as PS2PAK_1.HSH (you should have 295 lines there and it should end with a "new paragraph" symbol IE empty 296th line).
Finally you have to replace " 0 " with " " in PS2PAK_0.HSH & " 1 " with " " in PS2PAK_1.HSH (even notepad.exe can do that in batch mode), save both HSH files and use indy_hsh_pk2.bms on 2 resulting pairs of HSH/PK2 files.

Bye!
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: Indiana Jones and the emperor's tomb (PS2) HSH+PK2

Post by aluigi »

Script 0.1.1