ROM Hack UnityFS editing (such as Doom)

Nazosan

Well-Known Member
OP
Member
Joined
May 12, 2009
Messages
556
Trophies
1
XP
969
Country
United States
So I've been trying my hand at really simple modding on a lot of things lately and one thing that has really been a problem for me for a long time are those UnityFS files -- eg "assets." For example, in Doom I thought it would be nice if I could edit the soundtrack. (It's not a popular thing among most -- most prefer the original MIDI from Reznor and I can understand why, but I have always felt that the PS1's soundtrack had a very interesting dark atmospheric feel that suited the game well. On some PC Doom engine implementations I can use a custom WAD I made with it and I thought it would be nice if I could get its soundtrack into this too.) Unfortunately, it seems I can't even find tools to extract the files properly. (UnityAssetsBundleExtractor for instance is able to open it and decompress it to a new file, but the actual physical audio data is inaccessible in a separate "tree" or whatever you call it.)

I've seen a lot of mods of this sort out there for various games, so I know it's possible, but apparently none of my searching in all this time has yielded the right tools.
 

Falo

Well-Known Member
Member
Joined
Jul 22, 2012
Messages
680
Trophies
2
XP
2,611
Country
Germany
Use UnityAssetsBundleExtractor to extract "CAB-d5ae2b5aa3edc0f73b4bb6b1ae125a53" and "CAB-d5ae2b5aa3edc0f73b4bb6b1ae125a53.resource"

The first file is the index, it tells the game where the audio data is, the second file contains the audio, format is encrypted FSB5.
You can unpack it with quickbms and this script: https://pastebin.com/4LbFA7Ar

You can then play these with in_vgmstream and xmplay.

About modding the audio, never tried it, but unity is not mod friendly, especially on consoles, most unity mods require to hook the .NET code, which is not possible on Switch (il2cpp makes it impossible).
 

masagrator

The patches guy
Member
Joined
Oct 14, 2018
Messages
5,459
Trophies
2
XP
9,927
Country
Poland
For extracting playable audio better to use AssetStudio or find audio file with UABE, then click on "Plugins" and "Extract audio". You get then playable wav file.

With replacing will be a little issue. I've tried already by packing new asset pack with Unity 2018.3 (DOOM is using 2018.3.12f1 when for PC the closest one is 2018.3.14f1), Hex editing Information files to have the same Informations about pack and replaced resources blob in audio UnityFS archive. And game stucks.
 
Last edited by masagrator,

Nazosan

Well-Known Member
OP
Member
Joined
May 12, 2009
Messages
556
Trophies
1
XP
969
Country
United States
To be clear, I don't really want to extract or play the original audio, just replace it. I already have a XG synthesizer which handles the original MIDI about as well as anything is going to.
 

You may also like...

General chit-chat
Help Users
    trepp0 @ trepp0: lets go