Skyluker4 / UnityAssetReplacer

A tool to replace data in a Unity Asset Bundle from modified files.
GNU General Public License v3.0
38 stars 7 forks source link
asset-bundle asset-bundles asset-bundling csharp dotnet dotnet-5 dotnet-core extract extract-data extraction extractor reverse-engineering unity

UnityAssetReplacer

Build CodeQL Lint

A tool to dump or replace assets in a Unity asset bundle.

Usage

This program requires an uncompressed Unity asset bundle. Use Unity Assets Bundle Extractor Avalonia (UABEA) to decompress an asset bundle if it's compressed. It also requires the name of the member (the field of an object in the assets file, NOT the game object itself) you'd like interact with in the asset bundle (ex. m_Name), except for when you are dealing with textures. The best way to find members/fields for an object is to open the asset bundle in UABEA or a similar tool, then open the asset file and then the object, where you'll find a list of all members for that object. To extract, you also need to set the path of where you'd like to dump to.

To replace assets, you need to specify the path where the assets to import are and the name of the new asset bundle you're exporting. The files inside of the directory must match the asset names exactly in order to be imported.

For a more in-depth tutorial, check out the guide.

Arguments

Dumping

Replacing

Examples

See the guide for how it is used in action.

Building

Requirements

Using dotnet

  1. Restore any packages with dotnet restore or skip and let it run implicitly when running the next step.
  2. Run dotnet build in the project root.

Using Visual Studio

  1. Open UnityAssetReplacer.sln in Visual Studio
  2. Press Build -> Build Solution to build or the green arrow to build and run.

Resources