DereTore icon indicating copy to clipboard operation
DereTore copied to clipboard

How do I make a hca file header that is a C8 C3 C1 file?

Open huashao2019 opened this issue 5 years ago • 2 comments

I extracted some hca from the game, I found that their file headers are C8 C3 C1, now how do I generate such a file, the file headers I make using hcaenc are 48 43 41

Test hca download link https://www.lanzous.com/i4a3upc

huashao2019 avatar May 24 '19 01:05 huashao2019

The headers are simply XORed with 0x80. You can write a simple program, or use any hex editor to do that. By the way, most HCA decoders accept both c8 c3 c1 and 48 43 41.

hozuki avatar May 31 '20 21:05 hozuki

I think what you generated was simply unencrypted HCA, while the HCA extracted from the game is encrypted - therefore you should then encrypt your generated HCA with correct key (otherwise you'll get incorrect waveform, which sounds like unpleasant noise) if you want to replace such audio resource in the game.

segfault-bilibili avatar Feb 24 '22 15:02 segfault-bilibili