Addressables WebGL & loading Remote Scenes

Hi all,
I’m trying to work with addressables specifically, w WebGL builds & loading remote scenes from a server

Works in Unity addressable play modes
But Not in Browser
I just get the first empty scene the next never loads

I have read that you need to Download first and then LoadScenes
something like (Pseudo code)

    [SerializeField] AssetReference assetReferenceScene;


    void OnSomething()
    {
        //initialize:
        Addressables.LoadAssetAsync<Scene>(assetReferenceScene);
        // Intantiate:      assetReferenceScene.LoadSceneAsync(UnityEngine.SceneManagement.LoadSceneMode.Additive);

    }

I believe my Workflow is solid :
Loading Scenes Additively may be the best option for me to assemble a variety of assets & dependencies…

a) import addressables package and make new group (I call ‘scenes’) and drag the scenes I want to load inside- Note that alone makes them addressable

  • and because it’s a scene I don’t know if I also need to include the prefabs/ models / materials & textures… but I do and also give them labels

b) I set up another profile I point to a server I control the permissions on and right click to set as the active profile

  • & I make sure all my groups point to using the remotes Load and Build
  • & check the √ build remote catalog button in the Addressableasset settings also

c) in my Starting (almost blank) scene, I have a (working) script to load a remote addressable scene (below)

    [SerializeField] AssetReference assetReferenceScene;


    void OnSomething()
    {         assetReferenceScene.LoadSceneAsync(UnityEngine.SceneManagement.LoadSceneMode.Additive);

    }
  • I test it in the Play mode (use asset database)
  • Then I use the addressables build to build (new build > default) the remote assets to my “Server Data” folder created outside the Assets folder (n my case this is a webGL build, so it creates a webGL folder to hold my bundles .json and hash)
  • After that builds I upload the (WebGL) folder to the remote server (the same file path as the remote setting I provided (above where WebGL is [build target])) & I change the permissions to be completely open so they can be accessed.
  • I test it again in addressable Play mode (with use existing build) selected as this will pull the assets remotely

Works in Unity addressable play modes
But Not in Browser
I just get the first empty scene the next never loads

Thanks in advance!
~b

1 Like

All my hosting permissions of the file have been set to open,
So I even tried in a new open Bucket on Google Cloud and I am still unable to load remote content

Here is the console error:

Exception encountered in operation Resource(remote_scenes_all_7daf21d27e3977a8c1cafcb8f0fd12e4.bundle), status=Failed, result= : RemoteAssetBundleProvider unable to load from url https://storage.googleapis.com/bentonaddresstest//remote_scenes_all_7daf21d27e3977a8c1cafcb8f0fd12e4.bundle, result=‘HTTP/1.1 404 Not Found’.
UnityEngine.AsyncOperation:InvokeCompletionEvent () (at /Users/bokken/buildslave/unity/build/Runtime/Export/Scripting/AsyncOperation.cs:21)

Thanks
~be

1 Like