Skip to content

Repository Management

Colin Basnett edited this page Aug 20, 2024 · 12 revisions

In order to use your game's assets within the BDK (Blender), the assets must be converted to an asset library.

The repository management tools in the add-on's preferences give you the ability to automatically create these assets and keep them up to date.

Create a Repository

  1. Navigate to the Add-ons tab in the Preferences dialog.
  2. Locate the Unreal BDK addon and click the > arrow to expand the add-ons preferences.
  3. In the Repositories section, click the + button and select Create Repository.
  4. Click the folder button next to Game Directory and navigate to the root directory of your Unreal 1 or 2 game (i.e., the parent folder of the game's System folder).
  5. If you are creating a repository for a mod (e.g., a total conversion mod like Darkest Hour: Europe '44-'45), input the name of the mod folder under Mod. (i.e., DarkestHourDev, MareNostrum).

Repository Rules

Some packages can be excluded from the asset building process. For example, map packages, audio packages etc. You can exclude these packages using "rules".

A game may already be configured with pre-existing rules based on a default configuration file in the root directory (bdk-default.json), in which case you can skip to the Build Assets section.

Example 1: Excluding packages based on extension

For this example, we want to exclude a package based on its extension. In this case, the audio packages for the game in question are .usx files, so we want to exclude all packages with this extension.

  1. Click the + button next to the rule list.
  2. Under Type, select Exclude.
  3. Under Pattern, enter *.usx. (Note that the pattern matching rules are those used in fnmatch).
  4. Click OK.

Example 2: Storing assets outside the default asset directory

This is recommended for projects whose levels have populated myLevel packages. By default, all assets will end up in the common asset pool. With myLevel packages, these cannot be referenced outside the context of the map being run, so we want them to be excluded from the common asset pool so that their assets are not accidentally linked while working on another map.

In this example, we will make sure that all *.rom files are still built, but stored in a separate directory.

  1. Click the + button next to the rule list.
  2. Under Type, select Set Asset Directory.
  3. Under Pattern, input *.rom.
  4. Under Asset Directory, input ./maps. Note that relative paths are stored relative to the repository directory.
  5. Click OK.

When built, these assets will now be outside of the common asset pool, but will be stored in the <GameDirectory>/.bdk/<RepositoryId>/maps folder.

Build Assets

Building the assets is the final step to getting your game's assets into the BDK (Blender).

Before continuing, make sure you have an adequate amount of disk space free on the drive that your game folder is located.

  1. Navigate to the Unreal BDK add-on preferences.
  2. Select the repository for which you want to build assets.
  3. Click the Scan button.
  4. Click the Build Assets button.

Note that this process can take quite a while depending on your computer specs and the number and size of the packages that need to be built.

Using Repository Assets

To view and use the newly built assets, open an Asset Browser editor in the BDK (Blender). You can then drag & drop the assets into your scene!