I worked on reverse engineering the bnk_pc file formats a while back, and while I got most of the features I wanted out of it, I could never get around to adding brand new audio clips to the game. After some extracting, I found that the clips have an ID of some sort, but I could never figure out where they're referenced from anywhere else in the game files.
Some of the xtbl files for things like radio stations have audio clip IDs, but they only reference audio files by name (like "SWIM_BLACK_MOUNTAIN___LET_SPIRITS_RIDE" for example) instead of the 32-bit number ID in the bnk_pc files. I found out that this ID was a hash for voice clips (a custom one I think), but the same hash didn't work for song names.
Also, the IDs/hashes for music clips seem to be restricted 30-bits instead of a full 32-bits (0 - 0x3FFFFFFF instead of 0 - 0xFFFFFFFF). Any idea why that is?
My code/research:
https://github.com/ToadKing/bnk_pc_extractor/
https://github.com/ToadKing/bnk_pc_extractor/blob/master/bnk_pc.h
Some of the xtbl files for things like radio stations have audio clip IDs, but they only reference audio files by name (like "SWIM_BLACK_MOUNTAIN___LET_SPIRITS_RIDE" for example) instead of the 32-bit number ID in the bnk_pc files. I found out that this ID was a hash for voice clips (a custom one I think), but the same hash didn't work for song names.
Also, the IDs/hashes for music clips seem to be restricted 30-bits instead of a full 32-bits (0 - 0x3FFFFFFF instead of 0 - 0xFFFFFFFF). Any idea why that is?
My code/research:
https://github.com/ToadKing/bnk_pc_extractor/
https://github.com/ToadKing/bnk_pc_extractor/blob/master/bnk_pc.h