Jump to content

UABE - Asset Bundle Extractor


DerPopo

Recommended Posts

In .assets files, the ResourceManager asset in the mainData or globalgamemanagers file (depends on the Unity version of the game) has all the names. Copy the first entry (or any other entry) in m_Container, set your name and file/path ID and adjust the size. The file id here isn't the same one as in the list UABE shows, you need to look for other named assets in the same .assets file to find the correct one.

 

Thank you very much. This advice helped me. I also noticed that file id should be as UABE shows when mainData is opened, not when you open individual .assets file. In my example, resources.assets shows File_Id 0, mainData 1. I specified 1 in UnnamedAsset of ResourceManager type. But it also seems that I was mistaken with bundles. I don't have m_Container and only have resources.assets and couple of sharedresourcesX.assets files.

 

Thanks again!

 

EDIT: Make sure you enter only lower case letters in path/filename in UnnamedAsset of ResourceManager type, or it won't work.

Edited by Zayyeh (see edit history)
Link to comment
Share on other sites

Does UABE support command line extracting textures etc? If not, could you please add command line extracting textures etc?

 

When there are a lot of asset bundles, doing it one by one in the UI seems impossible. Thanks a lot.

this

https://7daystodie.com/forums/showthread.php?22675-Unity-Assets-Bundle-Extractor&p=534617&viewfull=1#post534617

or this

https://7daystodie.com/forums/showthread.php?22675-Unity-Assets-Bundle-Extractor&p=410211&viewfull=1#post410211

 

suitable?

Link to comment
Share on other sites

 

Thanks a lot for the reply.

 

I managed to find batch extract assets from bundles after a few articles.

However, I didn't find batch to extract textures etc.

 

Tried to open all assets and then extract as you mentioned in the first link, I think there are probably too many files, program just hanged.

 

I managed to achieve this by combining with another tool called Unity Studio, great results at the end. :D

Link to comment
Share on other sites

  • 3 weeks later...
Guest NunzioArdi

Merci beaucoup

 

J'ai quelque demande pour améliorer le logiciel :

 

-Une option (à cocher)lors d'une extraction qui créerais les dossiers dans lesquelles ce trouver les fichiers. exemple:Screenshot_1.jpg.2eeac03ec3b8696cba24b689891cbbac.jpg

 

-Pouvoir extraire les fichiers .shaders qui sont de simple fichier texte

 

 

Sinon merci beaucoup pour ce logiciel.

Edited by NunzioArdi (see edit history)
Link to comment
Share on other sites

Could you add support for dumping MonoBehaviour files into JSON format (and of course importing from JSON)? The current format is easy for people to read, but not easy for programs to process. I'm dealing with a large MonoBehaviour asset (hundreds of elements in an array) and it's inconvenient to process the current format. JSON is a good format that balances between human readability and machine readability.

Link to comment
Share on other sites

Adding files to sharedresources1.assets

 

In a game I'm editing there are resources.assets and four sharedresourcesX.assets.

I added a resource to empty sharedresourcesX.assets file, which contains only PreloadData.

How to let mainData know about resource you add to sharedresourcesX.assets file? mainData simply does not see this file.. No problem when I add it to resources.assets, but I want to add it to sharedresourcesX.assets so all modded resources will be contained in one place.

 

in ResourceManager file I have something like

 

0 vector m_DependentAssets
 0 Array Array (149 items)
  0 int size = 149
  [0]
   0 ResourceManager_Dependency data
    0 PPtr<Object> m_Object
     0 int m_FileID = 1
     0 int m_PathID = 634
    0 vector m_Dependencies
     0 Array Array (1 items)
      0 int size = 1
      [0]
       0 PPtr<Object> data
        0 int m_FileID = 2
        0 int m_PathID = 422

 

but I can't figure out what to do here.

 

In mainData I can see something like this:

0 PreloadData Base
1 string m_Name = ""
0 vector m_Assets
 0 Array Array (5 items)
  0 int size = 5
  [0]
   0 PPtr<Object> data
    0 int m_FileID = 1
    0 int m_PathID = 10210
  [1]
   0 PPtr<Object> data
    0 int m_FileID = 1
    0 int m_PathID = 11998
  [2]
   0 PPtr<Object> data
    0 int m_FileID = 1
    0 int m_PathID = 11999
  [3]
   0 PPtr<Object> data
    0 int m_FileID = 1
    0 int m_PathID = 12000
  [4]
   0 PPtr<Object> data
    0 int m_FileID = 1
    0 int m_PathID = 12001

 

Any help would be really appreciated!

Edited by Zayyeh
Added details (see edit history)
Link to comment
Share on other sites

Sorry for the late responses.

Does UABE support command line extracting textures etc? If not, could you please add command line extracting textures etc?

 

When there are a lot of asset bundles, doing it one by one in the UI seems impossible. Thanks a lot.

 

UABE usually doesn't really hang but it could indeed take some time to complete. More console commands definitely are a todo but I can't tell when I get to it.

 

J'ai quelque demande pour améliorer le logiciel :

 

-Une option (à cocher)lors d'une extraction qui créerais les dossiers dans lesquelles ce trouver les fichiers. exemple:[ATTACH=CONFIG]18457[/ATTACH]

 

-Pouvoir extraire les fichiers .shaders qui sont de simple fichier texte

 

 

Sinon merci beaucoup pour ce logiciel, encore merci

My French writing skills aren't much better than Google's.

- I'll note that down on my todo list.

- Shaders in newer Unity versions are compiled and compressed, so they would have to be decompiled. I'll add support for the old shader format in the TextAsset plugin though.

 

Could you add support for dumping MonoBehaviour files into JSON format (and of course importing from JSON)? The current format is easy for people to read, but not easy for programs to process. I'm dealing with a large MonoBehaviour asset (hundreds of elements in an array) and it's inconvenient to process the current format. JSON is a good format that balances between human readability and machine readability.

 

Will do.

 

In a game I'm editing there are resources.assets and four sharedresourcesX.assets.

I added a resource to empty sharedresourcesX.assets file, which contains only PreloadData.

How to let mainData know about resource you add to sharedresourcesX.assets file? mainData simply does not see this file.. No problem when I add it to resources.assets, but I want to add it to sharedresourcesX.assets so all modded resources will be contained in one place.

in ResourceManager file I have something like

<snip/>

but I can't figure out what to do here.

In mainData I can see something like this:

<snip/>

Any help would be really appreciated!

 

In case you are adding the assets to an existing sharedresourcesX.assets file, they should be visible instantly. If you want to add a path, you need to set it in the m_Container Array in ResourceManager. mainData should have dependencies on all the sharedresources files, the file id can't be directly seen in UABE though. If you count the file id starting with 0 in View->Go to asset, excluding "unity default resources" and "unity_builtin_extra", you usually have the actual file id from what mainData sees.

In case the sharedresources file isn't listed in the Go to asset window, UABE doesn't allow adding new dependencies but I'll definitely add that feature.

Edited by DerPopo (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

UABE 2.1 is out with Unity 5.5 support and various smaller improvements.

 

i use UABE extra this bundle file to file assets file :/

but i don't know how to pack this file assets to bundle

 

This File origin is 3 mb

File extra 16,7 mb

Any one can help me ???

Plz make tutorial :)

This file :)

https://drive.google.com/drive/folders/0B5JULaL16BZ3anV0a1hrdXJsaGs?usp=sharing

[ATTACH=CONFIG]18531[/ATTACH]

 

Both files are bundle files, one is compressed and the other one is decompressed. UABE can't compress the bundle file but it should still be usable in game.

 

DerPopo, let me ask - very interesting as You use Your Utility? For modding? :)

 

I actually haven't created mods for quite a while (except dummy mods to test UABE releases).

UABE has started as an "extension" to grimreefer's UAE to modify .assets in bundles and grown into a general .assets and bundle modification tool with over 30000 own lines of code utilizing 14 third-party-libraries (8 of which are only used for textures). The time I'd otherwise spend making mods is mostly used up by UABE development.

Link to comment
Share on other sites

editing .assetbundle

 

I am having hard time looking at the internet on how do they edit the skin of a certain game on mobile and I found this post, I hope you can help me out. Basically it is a mobile game thay uses .assetbundle, one of the guy shared a file which they edited and worked when replaced on game data inside the mobile phone. Can this tool help me extrac5 and edit the skin character of the game? This is one of the file you can try.

https://mega.nz/#!dBQRWZZb!Vs5iy_ofJ16ZMM2RYNGMHgwOsJEiv4Wwf4gM84h446I

Please help me, I am new to modding textures and skins. Thank you

Link to comment
Share on other sites

I am having hard time looking at the internet on how do they edit the skin of a certain game on mobile and I found this post, I hope you can help me out. Basically it is a mobile game thay uses .assetbundle, one of the guy shared a file which they edited and worked when replaced on game data inside the mobile phone. Can this tool help me extrac5 and edit the skin character of the game? This is one of the file you can try.

https://mega.nz/#!dBQRWZZb!Vs5iy_ofJ16ZMM2RYNGMHgwOsJEiv4Wwf4gM84h446I

Please help me, I am new to modding textures and skins. Thank you

Link to comment
Share on other sites

  • 2 weeks later...
I am having hard time looking at the internet on how do they edit the skin of a certain game on mobile and I found this post, I hope you can help me out. Basically it is a mobile game thay uses .assetbundle, one of the guy shared a file which they edited and worked when replaced on game data inside the mobile phone. Can this tool help me extrac5 and edit the skin character of the game? This is one of the file you can try.

https://mega.nz/#!dBQRWZZb!Vs5iy_ofJ16ZMM2RYNGMHgwOsJEiv4Wwf4gM84h446I

Please help me, I am new to modding textures and skins. Thank you

I'm not familiar with mobile stuff, but your file that you shared has no useful data.

But most likely what you need is doable with this Tool.

Link to comment
Share on other sites

Extracting Terrain with Textures

 

The minibike is created from the GameObject "entities/vehicles/minibike_prefab" (if you open globalgamemanagers through UABE, you can search for that path without " of course). It contains a Transform component (in View Data, expand m_Component, Array, 0, data, second and view asset) that has all minibike parts linked as children Transform (they contain a reference to the according GameObject).

There are two options :

1) Extending one of the minibike's part meshes by the whip antenna, which requires adding your texture to an existing one (I'm not sure if that's easily doable).

You can find the mesh location in GameObject->m_Component->Array->(usually 1)->data->second->view asset->Base->m_Mesh, the file id in brackets is the one you're looking for.

You can find the texture location in GameObject->m_Component->Array->(usually 1)->data->second->view asset->Base->m_Materials->Array->0->data->view asset->Base->m_SavedProperties->m_TexEnvs->Array->5->data->second->m_Texture.

UABE can't export rigged meshes and can't import meshes at all so far. As far as I know, all the minibike parts have bones though so it likely won't work good. The only way to import a mesh is through the .assets of a built custom Unity project with that mesh in a scene.

2) Adding another part to the minibike.

While it should work in theory, I haven't found a way not crashing the game even though I have created a new Transform, GameObject and SkinnedMeshRenderer and added all necessary dependencies to the ResourceManager assets. The game crashes because it somehow doesn't load my assets properly but tries to access them, so either the assets themselves are wrong or I am missing another dependency tree.

I'll report back if I find a way to fix it.

 

 

 

 

 

In case you store your texture in a bundle file, there should be an unnamed asset of type AssetBundle (path id always is 1 afaik) in at least one of the bundle's .assets that contains the names in the m_Container array. Export a dump, copy the last entry in m_PreloadTable and adjust it so it e.g. looks like this :

 0 Array Array (144 items)
  [b][size=3]0 int size = 145[/size][/b]
... (entries 0-142)
  [143]
   0 PPtr<Object> data
    0 int m_FileID = 0
    0 SInt64 m_PathID = 45
  [b][size=3][144][/size]
   [size=3]0 PPtr<Object> data[/size]
    [size=3]0 int m_FileID = 0[/size]
    [size=3]0 SInt64 m_PathID = 46[/size][/b]

The changed lines are marked in bold font.

You don't need to fix the index in the brackets. It's important that the new entry is at the end and that you fix the size. Adjust the file id and path id to match your asset.

Perform similarly on m_Container. Copy one item (you can use any in this case), increase the size, enter the new name, set preloadIndex to the index of the entry in m_PreloadTable, preloadSize to 1 and also modify the PPtr to match your asset.

 

In .assets files, the ResourceManager asset in the mainData or globalgamemanagers file (depends on the Unity version of the game) has all the names. Copy the first entry (or any other entry) in m_Container, set your name and file/path ID and adjust the size. The file id here isn't the same one as in the list UABE shows, you need to look for other named assets in the same .assets file to find the correct one.

 

Is it possible to extract the terrain with the textures if so please let me know thank you so much. :tears_of_joy:

Link to comment
Share on other sites

Is dev dead ??

 

No, I'm fine :D

I'm relatively busy at the moment so it can sometimes take a bit longer for me to respond.

 

Hi. This is such a great tool because it support 64 bit an all, but it can only read .asset files. HOw about associated file like .asset.resS?

Please add support to extract .resS files.

 

.resS and .resource files only contain raw data used by the .assets file, such as for Texture2D and AudioClip assets. The data from these files can be exported with plugins from the opened .assets file.

 

Is it possible to make a Mac version of UABE, maybe one that would run under Mono? Or maybe release src code to enable porting to Mac?

 

UABE is written in native C++ so Mono doesn't work. Maybe it works with the Win32 compatibility layer Wine (at least older versions of UABE work on Linux with Wine). There are some well-written instructions on how to install Wine on OSX.

A native Linux version (maybe also OSX) is on my long ToDo-list, even if it becomes a console version.

 

Is it possible to extract the terrain with the textures if so please let me know thank you so much. :tears_of_joy:

 

If you use View Data on the TerrainData asset, you can look for texture references in m_SplatDatabase->m_Splats and m_DetailDatabase->m_DetailPrototypes. Note down the File ID in brackets and the Path ID for each of the textures you want to export and locate the textures to export them as with other textures.

 

Hey DerPopo :) can you add more function ?

Unity Assets Bundle Extractor

Support extract all assets one time :)

And Considered images directly on tools :)

Can you support more ???

 

I'm not completely sure what you mean. In an opened .assets file, you can select multiple assets of the same type (e.g. all Texture2Ds) by sorting for the type first and export them like you would do with a single asset. You can't export all Texture2Ds and AudioClips at the same time

If you need to export from multiple .assets files at the same time, you can easily select multiple .assets files in the file open dialog.

Edited by DerPopo (see edit history)
Link to comment
Share on other sites

No, I'm fine :D

I'm relatively busy at the moment so it can sometimes take a bit longer for me to respond.

 

 

 

.resS and .resource files only contain raw data used by the .assets file, such as for Texture2D and AudioClip assets. The data from these files can be exported with plugins from the opened .assets file.

 

 

 

UABE is written in native C++ so Mono doesn't work. Maybe it works with the Win32 compatibility layer Wine (at least older versions of UABE work on Linux with Wine). There are some well-written instructions on how to install Wine on OSX.

A native Linux version (maybe also OSX) is on my long ToDo-list, even if it becomes a console version.

 

 

 

If you use View Data on the TerrainData asset, you can look for texture references in m_SplatDatabase->m_Splats and m_DetailDatabase->m_DetailPrototypes. Note down the File ID in brackets and the Path ID for each of the textures you want to export and locate the textures to export them as with other textures.

 

 

 

I'm not completely sure what you mean. In an opened .assets file, you can select multiple assets of the same type (e.g. all Texture2Ds) by sorting for the type first and export them like you would do with a single asset. You can't export all Texture2Ds and AudioClips at the same time

If you need to export from multiple .assets files at the same time, you can easily select multiple .assets files in the file open dialog.

 

Wow. it works flawless now :D I couldn't get it to work with version 2.0

Also, does this tool support say...replacing contents in the .asset or .resS files.

Link to comment
Share on other sites

Hi guys, I have a question, if the files have a cab compression and it has the cache as it is extracted automatically?

I have more than 200 hundred files and model split it in parts ...

Unpack each individually and look of the model, I will spend a lot of time :nightmare:

 

Is it possible to automatically make the decompression of all cache files in a folder?

Link to comment
Share on other sites

  • DerPopo changed the title to UABE - Asset Bundle Extractor

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...