Table of Contents

Class AssetBundleLoadingUtils

Namespace
Nautilus.Utility
Assembly
Nautilus.dll
Utilities related to loading Asset Bundles.
public static class AssetBundleLoadingUtils
Inheritance
AssetBundleLoadingUtils
Inherited Members

Methods

LoadFromAssetsFolder(Assembly, string)

Loads an UnityEngine.AssetBundle from the the mod's Assets folder. Expects a folder named Assets to exist in the same folder as the Assembly, and expects this folder to contain an asset bundle with the same name as defined in the assetBundleFileName parameter.
public static AssetBundle LoadFromAssetsFolder(Assembly modAssembly, string assetBundleFileName)

Parameters

modAssembly Assembly
The mod assembly, in the same folder that contains the Assets folder. See GetExecutingAssembly().
assetBundleFileName string
The name of the Asset Bundle file in your Assets folder, i.e. "deextinctionassets" or "gargantuanassets". These typically do not have a file extension.

Returns

AssetBundle

LoadFromModFolder(Assembly, string)

Loads an UnityEngine.AssetBundle from a given path. Expects an asset bundle to exist at pathToBundle (relative to the containing folder of the DLL).
public static AssetBundle LoadFromModFolder(Assembly modAssembly, string pathToBundle)

Parameters

modAssembly Assembly
The mod assembly used to find the mod's folder. See GetExecutingAssembly().
pathToBundle string
The relative path to the Asset Bundle file from your plugin folder, i.e. "Assets/deextinctionassets" or "Assets/AssetBundles/gargantuanassets". See Combine(string, string) for creating the path. These typically do not have a file extension.

Returns

AssetBundle
See Also