GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Extraction and unpacking of game archives and compression, encryption, obfuscation, decoding of unknown files
penguino
Posts: 7
Joined: Thu Oct 11, 2018 4:15 pm

GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by penguino »

I need help unpacking these files
The files can be found in AFS_DATA in the game, AFS01 AND AFS00 only have audio.
The pzz files have textures, text, character files and models
HIT files seem to be something related to the hit-boxes of the characters
Pzzs seem to use some sort of compression and seems to be some sort of archive like format
they seem somewhat similar to PTR2's INT files, probably using a common type of compression in ps2

First 16 bytes of the files
PZZ (file: pl00.pzz)
0D 00 00 00 1B 00 00 80 03
PZZ (file: sd0a0.pzz)
03 00 00 00 02 00 00 00 01 00 00 00 21 00 00 00 00 00 00 00 00 00
PZZ (file: ball.pzz)
03 00 00 00 02 00 00 80 01 00 00 00 01 00 00 80 00 00 00 00 00 00
HIT (file: pl10.hit )
20 00 00 00 58 00 00 00 B0 01 00 00 F0 02 00 00 10 03 00 00 B0 03
HIT (file: pl00.hit )
20 00 00 00 64 00 00 00 BC 01 00 00 FC 02 00 00 1C 03 00 00 BC 03
BIN (file: c00_tbl.bin)
04 00 00 00 08 00 00 00 18 00 00 00 40 01 00 00 94 02 00 00 A8 03
BIN (file: rc0a1_tbl.bin)
03 00 00 00 08 00 00 00 14 00 00 00 3C 01 00 00 D0 01 00 00 00 00

Some sample files: https://mega.nz/#F!2bQzxYLC!M39HH3f7p3OpzeJr2-eYaA
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by aluigi »

I guess the format of the PZZ files is like the following:

Code: Select all

get FILES long
for i = 0 < FILES
    get SIZE long
    math FLAGS = SIZE
    math FLAGS u>> 31
    math SIZE & 0x7fffffff
    math SIZE * 0x800
    putarray 0 i SIZE
    putarray 1 i FLAGS
next i
for i = 0 < FILES
    padding 0x800
    getarray SIZE  0 i
    getarray FLAGS 1 i
    savepos OFFSET
    log "" OFFSET SIZE
    math OFFSET + SIZE
    goto OFFSET
next i

I don't know what's the meaning of that FLAG value, I tought it was related to some compression but there is no decompression size.
penguino
Posts: 7
Joined: Thu Oct 11, 2018 4:15 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by penguino »

any progress?
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by aluigi »

The script I posted should be able to extract the files, have you tried it?
penguino
Posts: 7
Joined: Thu Oct 11, 2018 4:15 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by penguino »

yes, but is there a way to decompress the files?
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by aluigi »

Currently no way.
penguino
Posts: 7
Joined: Thu Oct 11, 2018 4:15 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by penguino »

that sucks, but thanks for helping!
infval
Posts: 3
Joined: Sun May 24, 2020 11:18 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by infval »

aluigi wrote:I don't know what's the meaning of that FLAG value, I tought it was related to some compression but there is no decompression size.
Yes, it's compression flag. If 0x80000000 is set, file is compressed.

penguino, I've created (de)compressor: https://github.com/infval/pzzcompressor_jojo. Python version can unpack like BMS script, C version is faster without unpacking.
aluigi
Site Admin
Posts: 12984
Joined: Wed Jul 30, 2014 9:32 pm

Re: GIOGIO Japanese PS2 game PZZ, BIN and HIT files

Post by aluigi »

Well done ;)