One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Skeletons, animations, shaders, texturing, converting, fixing and anything else related to read game models
einherjar007
Posts: 35
Joined: Fri Sep 20, 2019 7:55 am

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by einherjar007 »

@spiritovod: Thanks for the v2 update, more files are now decrypted. Some files won't open due to the header shift not working, but with manual correction I can open them with no problem.

The following is a list of files that cannot be successfully decrypted in either v1 or v2. These files will crash quickbms.

045af336764f7d421909f8bfee45b0fd.ab
0598efb19962e8cc643c225afbede6df.ab
260d0e48a7caa00c0e262fe3aa26d004.ab
2e20626d593781544c97a23e6463d446.ab
39d69a49c13006172628300cb1b773b2.ab
3a1432adc3c9b7631781953f32f63a2f.ab
3c2311507e670527d09e4b7270d82e91.ab
4105220a3b78978e6044e6dc8af8f9ea.ab
440bf5d02cdd7c0a6f4b522e3bb58cb6.ab
58d4be1e1dc16cdfd3cf68ef81efcb16.ab
624c446ead76ef8796df3f12ab96d17b.ab
62794cd9dcd91c5e3c9163d7d661ffeb.ab
669841b614a1fce1eb2e079439074d5c.ab
7b9f597ab71e15370712f6b3a3d3d1d3.ab
7e90bb86c1ff4ddb89198b8359e8ba09.ab
833aae59d6110916e2650fdd8ca2adf5.ab
9415178c56c50461f3981a3f1a29e6b8.ab
a447c27671d86d0b19f7b196ffcacd95.ab
a55dcaafcb7cf4c0b580c70023cdaf14.ab
a657451257df2b655658922f11639e7b.ab
ac5fa7d2583344a1fa5c611d687e3a57.ab
b1c9c660a3bcc28c7d393cc4341874f5.ab
bd0363ca3b505d121db21f572ccce27d.ab
d092dac5bc47a10b2cb61e082e4eb707.ab
de651b8e56e4cb1bf8fca0f614632004.ab
e84cc2dbe83ebd17c4d306daaf5fa92a.ab
fafb6a16523216152dc831d32cb212e4.ab

and also assume that these files have been successfully decrypted, but we cannot open them. They may have been corrupted originally.
609abf41d73d3fe248f564960510de40.ab
015590db50f0ed9f1a92f769ffb09f40.ab
e9a2f4dedf82ff56b3829123d89ea97b.ab
Meonpie
Posts: 16
Joined: Mon Feb 07, 2022 4:18 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by Meonpie »

spiritovod wrote:@einherjar007: Thanks for explanation, so that field is compression flag. I've updated the script, now output would be compatible with AssetStudio without additional modifications if possible.
As for the rest - the script is using workaround, which shouldn't be used to begin with. But it's not possible to use the same approach as original python script, because quickbms can't catch exceptions. Not sure if it can be processed properly in quickbms without reversing how encryption is actually applied to avoid workaround (something like rotation of used bytes based on hashed names).

Update: Another small update for the script, apparently there are uncompressed chunks within some bundles, they're now handled properly.
The old version of AssetStudio can ignore the lz4 error import, but there is a problem with the texture. I don’t know if it is caused by the decryption process or if AssetStudio does not support it.


Image
spiritovod
Posts: 719
Joined: Sat Sep 28, 2019 7:00 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by spiritovod »

@einherjar007: I can't do much with the encryption part - like it was already said above, normally it would be better to modify original python script instead. I've only created quickbms script as template, which can be used for other unity games with similar issues with minimum adjustments. Though that "header shift" part can be probably fixed - I suppose in some situations re-compressed modified info block is smaller/larger than original and inserting it as-is at the same place breaks offsets of the bundle (failed to reproduce it locally though).
VRLuffy
Posts: 4
Joined: Tue Oct 25, 2022 7:10 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by VRLuffy »

..
Last edited by VRLuffy on Sun Nov 13, 2022 6:50 pm, edited 1 time in total.
VRLuffy
Posts: 4
Joined: Tue Oct 25, 2022 7:10 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by VRLuffy »

..
VRLuffy
Posts: 4
Joined: Tue Oct 25, 2022 7:10 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by VRLuffy »

..
einherjar007
Posts: 35
Joined: Fri Sep 20, 2019 7:55 am

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by einherjar007 »

@spiritovod: thanks advice.
If I add bs.seek(64) to resolve the data misalignment and replace the key with the latest one, it does indeed decompress, but AS cannot read it. The fact that the error occurs with a random COMPRESS TYPE suggests that it is probably not decrypting perfectly correctly.
I will upload a revised *.py later and I hope you will take a look at it.

*Edit
Edited py script. It does decompress, but I don't think it is the correct result.

*Edit
Apparently there are some files that can be successfully decrypted, and these are the only ones that I have not been able to decrypt with quickbms, manual fixes, updated python, or any other means I can take. If I can decrypt these files, then I have decrypted the entire contents of the apk for now.

045af336764f7d421909f8bfee45b0fd.ab
0598efb19962e8cc643c225afbede6df.ab
260d0e48a7caa00c0e262fe3aa26d004.ab
3a1432adc3c9b7631781953f32f63a2f.ab
4105220a3b78978e6044e6dc8af8f9ea.ab
440bf5d02cdd7c0a6f4b522e3bb58cb6.ab
58d4be1e1dc16cdfd3cf68ef81efcb16.ab
624c446ead76ef8796df3f12ab96d17b.ab
62794cd9dcd91c5e3c9163d7d661ffeb.ab
669841b614a1fce1eb2e079439074d5c.ab
7b9f597ab71e15370712f6b3a3d3d1d3.ab
7e90bb86c1ff4ddb89198b8359e8ba09.ab
833aae59d6110916e2650fdd8ca2adf5.ab
9415178c56c50461f3981a3f1a29e6b8.ab
a447c27671d86d0b19f7b196ffcacd95.ab
a55dcaafcb7cf4c0b580c70023cdaf14.ab
ac5fa7d2583344a1fa5c611d687e3a57.ab
bd0363ca3b505d121db21f572ccce27d.ab
d092dac5bc47a10b2cb61e082e4eb707.ab
de651b8e56e4cb1bf8fca0f614632004.ab
609abf41d73d3fe248f564960510de40.ab
015590db50f0ed9f1a92f769ffb09f40.ab
e9a2f4dedf82ff56b3829123d89ea97b.ab

*Edit
After further manual adjustments, I was able to read the failed file in AS, and it seems that the decryption was successful, but the file size values listed in the header and before the CAB information are different. I assume that the file size is also written to the archive, but I suspect that these are also incorrect values. It is possible to open the file in AS, but it is broken.
Meonpie
Posts: 16
Joined: Mon Feb 07, 2022 4:18 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by Meonpie »

spiritovod wrote:@einherjar007: Thanks for explanation, so that field is compression flag. I've updated the script, now output would be compatible with AssetStudio without additional modifications if possible.
As for the rest - the script is using workaround, which shouldn't be used to begin with. But it's not possible to use the same approach as original python script, because quickbms can't catch exceptions. Not sure if it can be processed properly in quickbms without reversing how encryption is actually applied to avoid workaround (something like rotation of used bytes based on hashed names).

Update: Another small update for the script, apparently there are uncompressed chunks within some bundles, they're now handled properly.
Your script can also decrypt Devil May Cry: Peak game using "old xor set", but it has the same problem, there is a problem with the texture
hunshisuipian.zip
einherjar007
Posts: 35
Joined: Fri Sep 20, 2019 7:55 am

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by einherjar007 »

Meonpie wrote:Your script can also decrypt Devil May Cry: Peak game using "old xor set", but it has the same problem, there is a problem with the texture
It seems to be possible to load one if the results are adjusted. I still think it would be faster to adjust the AS. I would like to do a few more tests, so please wait a bit.
Image
Meonpie
Posts: 16
Joined: Mon Feb 07, 2022 4:18 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by Meonpie »

einherjar007 wrote:
Meonpie wrote:Your script can also decrypt Devil May Cry: Peak game using "old xor set", but it has the same problem, there is a problem with the texture
It seems to be possible to load one if the results are adjusted. I still think it would be faster to adjust the AS. I would like to do a few more tests, so please wait a bit.
Image
Hello, how is your script modification going? :)
spiritovod
Posts: 719
Joined: Sat Sep 28, 2019 7:00 pm

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by spiritovod »

I've added modified AssetStudio to my base post, it should work with Burning Will bundles directly.

Update: Studio is updated, it should be compatible with both new and old BW versions, and also with chinese versions of DMC: Peak of Combat now.
einherjar007
Posts: 35
Joined: Fri Sep 20, 2019 7:55 am

Re: One Piece: Burning Will (航海王:燃燒意志) Unity3d File Help

Post by einherjar007 »

Thank you very much, I was unable to solve the read error against the image and was at my wit's end.