Skip to content
View in the app

A better way to browse. Learn more.

ResHax

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Help us keep the site running.

Defense Grid 2 - *.hpz

Featured Replies

  • Author
  • Localization

AlphaTwentyThree, posted Mon Mar 30, 2015 10:07 pm (4221)


Hm... it stops at 00087 with an error. :\
I'll upload the complete archives in a bit.
  • Author
  • Localization

aluigi, posted Tue Mar 31, 2015 10:11 am (4229)


It was all ok, it's just that there are 20 bytes at the end of the index file that were read by the script.
So you have extracted all the files correctly.
I have updated the script only to avoid the error message (the extracted files are the same).
  • Author
  • Localization

AlphaTwentyThree, posted Tue Mar 31, 2015 11:41 am (4233)


Ok, good to know, thanks!
  • Author
  • Localization

aluigi, posted Tue Mar 31, 2015 2:40 pm (4244)


I see only some "1FCB" files in them but I don'think they are so useful.
  • Author
  • Localization

AlphaTwentyThree, posted Tue Mar 31, 2015 4:47 pm (4248)


Well, the files themselves are decodable with binka2wav but there are file names in the header of the KNAB file starting at 0xc32c.
Do you have the patience to take a look at how to sync them to the 1FCB files? I could close that project for once then. ;)
  • Author
  • Localization

AlphaTwentyThree, posted Tue Mar 31, 2015 5:07 pm (4249)


Here's what I found out:
- there's an " TSP" identifiert at 0x9778 which seems to mark the beginning of the TOC structure
- the TOC structure consists of 0x3c bytes per file, the offsets are at 0x97f4, 0x9830 and so on, the sizes 0xc bytes after the size
I just can't see the link to the file names at 0xc32c...
  • Author
  • Localization

aluigi, posted Tue Mar 31, 2015 8:35 pm (4255)


*edit* use the script provided by Alpha23
  • Author
  • Localization

AlphaTwentyThree, posted Tue Mar 31, 2015 8:47 pm (4257)


Something is wrong, I get an error message "can't read 1 bytes"...
INFO_OFF is wrong but I don't know where to get the actual info_off.
  • Author
  • Localization

AlphaTwentyThree, posted Tue Mar 31, 2015 8:53 pm (4258)


number_of_files is at 0x34 btw.
  • Author
  • Localization

AlphaTwentyThree, posted Tue Mar 31, 2015 9:04 pm (4260)


Got it :)
Code:
idstring "KNAB"
goto 0x14
get OFFSET long
goto 0x34
get FILES long
goto OFFSET
get NAMES_OFF long
get OFFSET long
get DUMMY long
get SIZE long
get NAME basename
string NAME ".txt"
log NAME OFFSET SIZE
get DUMMY long
get DUMMY long
get DUMMY long
get INFO_OFF long
goto INFO_OFF
for i = 0     get NAME_OFF long
    get DUMMY long
    get OFFSET long
    getdstring DUMMY 0xc
    get SIZE long
    getdstring DUMMY 0x20

    savepos TMP
    goto NAME_OFF
    get NAME string
    goto TMP
    log NAME OFFSET SIZE
next i
  • Author
  • Localization

aluigi, posted Tue Mar 31, 2015 9:05 pm (4261)


Well done
  • Author
  • Localization

happyend, posted Sat Apr 11, 2015 8:22 am (4455)


AlphaTwentyThree wrote:
Got it :)
Code:
idstring "KNAB"
goto 0x14
get OFFSET long
goto 0x34
get FILES long
goto OFFSET
get NAMES_OFF long
get OFFSET long
get DUMMY long
get SIZE long
get NAME basename
string NAME ".txt"
log NAME OFFSET SIZE
get DUMMY long
get DUMMY long
get DUMMY long
get INFO_OFF long
goto INFO_OFF
for i = 0     get NAME_OFF long
    get DUMMY long
    get OFFSET long
    getdstring DUMMY 0xc
    get SIZE long
    getdstring DUMMY 0x20

    savepos TMP
    goto NAME_OFF
    get NAME string
    goto TMP
    log NAME OFFSET SIZE
next i



- select the input archives/files to extract, type * or "" for whole folder and
subfolders
- select the output folder where extracting the files
- open input file D:\quickbms6.2\defense_grid2_base.msscmp
- open script D:\quickbms6.2\msscmp.bms
- set output folder D:\quickbms6.2\rip

offset filesize filename
--------------------------------------
00000c5c 3316 defense_grid2_base.txt

Error: incomplete input file 0: D:\quickbms6.2\defense_grid2_base.msscmp
Can't read 1 bytes from offset 3b343b39.
Anyway don't worry, it's possible that the BMS script has been written
to exit in this way if it's reached the end of the archive so check it
or contact its author or verify that all the files have been extracted.
Please check the following coverage information to know if it's ok.

coverage file 0 0% 3420 45466658

Last script line before the error or that produced the error:
29 get NAME string

Press RETURN to quit
  • Author
  • Localization

AlphaTwentyThree, posted Tue Apr 14, 2015 8:55 am (4507)


Oh... somehow it worked for me. Can you upload the file? I don't have it anymore...
  • Author
  • Localization

AlphaTwentyThree, posted Sat Apr 18, 2015 11:24 am (4619)


Ok this is really strange. My script is brutally wrong but somehow I exracted files with it. No idea how I did that. ;)
Anyway, I'll have to rewrite the whole thing but it's not that obvious... Let's see what I can do. ;)
  • Author
  • Localization

skyline1, posted Mon Jun 08, 2015 11:36 pm (5633)


Hi, sorry to post into an old thread, but I'm trying to extract data from the *.hpz files for Defense Grid 2 as well, and am running into an error while trying to use the script provided by aliugi in the second post. When I try to run quickbms, I get the following error:

QuickBMS generic files extractor and reimporter 0.6.4
by Luigi Auriemma
e-mail: [email protected]
web: aluigi.org
(May 29 2015 - 16:04:52)

http://quickbms.aluigi.org
http://twitter.com/luigi_auriemma
http://zenhax.com

- GUI mode activated, remember that the tool works also from command-line
where are available various options like folder scanning, filters and so on

- select the BMS script or plugin to use
- select the input archives/files to extract, type * or "" for whole folder and
subfolders
- select the output folder where extracting the files
- start the scanning of the input folder: C:\Games\Defense Grid 2\bms\input
- open input file C:\Games\Defense Grid 2\bms\input\.\data0000.hpz
- open script C:\Games\Defense Grid 2\bms\defense_grid_2.bms
- set output folder C:\Games\Defense Grid 2\bms\output

offset filesize filename
--------------------------------------
- enter in folder C:\Games\Defense Grid 2\bms\input
coverage file 0 0% 0 465675
- open input file C:\Games\Defense Grid 2\bms\input\data0000.hpz
- enter in folder C:\Games\Defense Grid 2\bms\input
- open input file C:\Games\Defense Grid 2\bms\input\data0001.hpz

Error: incomplete input file 0: C:\Games\Defense Grid 2\bms\input\data0000.hpz
Can't read 1425597719 bytes from offset 00071b0b.
Anyway don't worry, it's possible that the BMS script has been written
to exit in this way if it's reached the end of the archive so check it
or contact its author or verify that all the files have been extracted.
Please check the following coverage information to know if it's ok.

coverage file 0 99% 465656 465675

Last script line before the error or that produced the error:
22 getdstring NAME NAMESZ

Press RETURN to quit


Any ideas on what I might be doing wrong?

Cheers,
  • Author
  • Localization

skyline1, posted Tue Jun 09, 2015 5:36 am (5634)


Nevermind, just figured out that the script I was using was for a more recent patch of the game!
Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.