Is the header and footer of each files identical and/or the same length?
It seems to be a sort of container, but I think there's useful data inside, like bdat length, number of item to extract, etc.
It these header/footer are present it's because there's a purpose, or else they would use the same format than the other files.
So when repacking it would need modification, that's certainly why you don't have translated text when testing your repacked file in game.
here is some idea if the header doesn't contain data which needs modification :
• To extract :
- If it's the same length + same data, then make a copy of the header and footer and save it into header.bin and footer.bin
- If it's the same length but different data, it can be cropped using a program which is doing binary copy for xxx bits to create 3 files (filename.header, filename.bdat, filename.footer) in a new folder ("extracted_bdat" for example).
- If the length is always different, then the extractor will need to do string search and extract the bdat, but then it's best to understand what these header are used for to be able to rewrite them correctly.
• Then to repack if header data isn't important :
- If header/footer are the same for all files, then it can be easy to repack all the bdat using a command line :
Code:
for %%f in (extracted_bdat\*.bdat) do copy /b "header.bin+extracted_bdat\%%f+footer.bin bdat\%%f"
(to test, I just write if from memory)
with header.bin and footer.bin saved in the current folder.
- If header/footer are different for all files :
Code:
for %%f in (extracted_bdat\*.bdat) do copy /b "extracted_bdat\%%~nf.header+extracted_bdat\%%f+extracted_bdat\%%~nf.footer bdat\%%f"
using each header and footer for the correct filename.
extracted_bdat\ content will be repack into bdat\
Read each *.bdat files and apply a binary copy "header+data+footer -> full.bdat" using :
%%f = filename with extension
%%~nf = filename without extension
The best way would be an updated XBSE.exe taking the header/footer in account.