Limitations

While the Spatial Creator Toolkit tries to integrate Addressables as natively as possible, there are some limitations that exist to ensure everything runs smoothly in Spatial.

If there's a feature with Addressables that is not supported in Spatial, and you strongly believe that it should be, please reach out and send a feature request!

Space Packages Only

Since C# scripting is only supported for Space package types and Addressables API is only accessible through C#, they will be the only package type that supports Addressables.

No Scene Assets

Direct access to scene loading and unloading via the Addressables API is restricted in order to be compatible with internal systems in Spatial. We will introduce multi-scene workflows and loading in the near future.

Some Settings Are Enforced

At build time, we overwrite many values under the default settings asset, as well as some values stored in Asset Group(s) schemas. This is to ensure they are configured correctly for Spatial. Below are tables of overridden config values, and some additional context for why it's enforced.

Project-wide Config (Sandbox only)

NameEnforced ValueAdditional Notes
MonoScript Bundle Naming PrefixDefault Group GUIDFor C# scripts attached to Addressable assets to work
Shader Bundle Naming PrefixDefault Group GUIDPrevent shaders from conflicting with internal shader types
Non-Recursive Dependency CalculationtrueHelps with build times and runtime memory usage
Send Profiler EventsfalseProfiling is disabled
Log Runtime ExceptionstrueAssists with debugging
Build PathLibrary/AssetBundles/SandboxBuild location cannot be modified
Build Remote CatalogtrueSpatial only supports remote catalogs

Note

The project wide settings (AddressableAssetSettings) only affects the Spatial Sandbox build. When publishing a package, this settings asset is excluded from the export entirely and any modifications to the settings will have no effect in your space.

Bundled Asset Group Config

NameEnforced ValueNotes
Bundle NamingAppend HashAvoids naming conflicts with other bundles
Asset Bundle Compression (Web)LZ4LZMA is unsupported on WebGL, so LZ4 is the next best option
Asset Bundle Compression (non-Web)LZMALZMA gives favorable compression ratio to LZ4
Use Asset Bundle CachetrueCaching speeds up loading time
Use CRCEnabled, Excluding CachedDisabled completely when publishing since it's incompatible with a custom compression algorithm

Banned C# API

The Spatial client also uses Addressables to load internal assets, so usage of some of these APIs can interfere with the app. Almost all API outside of the Addressables static class and AsyncOperationHandle struct are not allowed, with very few exceptions. Attempting to use these APIs will result in compilation errors and publishing failures.

Some examples of banned API:

  • Some obsolete functions, like AssetReference.LoadAsset
  • The entire UnityEngine.ResourceManagement.Diagnostics namespace
  • The entire UnityEngine.ResourceManagement.ResourceProviders namespace

Single Content Catalog

There can only be one content catalog associated with your space. Loading additional catalogs at runtime is not supported.

No Custom Build Scripts

For simplicity and security reasons, custom build scripts and schemas are not allowed. Spatial only supports the BundledAssetGroupSchema type in Asset Groups. Any other schema/group type will be ignored.