Search Unity

CCD + Cloud Build + Addressables Load scene

Discussion in 'Unity Cloud Content Delivery' started by Steimond1, Apr 26, 2021.

  1. Steimond1

    Steimond1

    Joined:
    Jan 20, 2021
    Posts:
    12
    Hey everybody!

    I need some help with loading the scene from addressable using CCD.
    Here is my flow.
    Unity Cloud Build builds my game and sends created addressables to the CCD. My game in the map preloader checks if the scene exists in the game build. If not, the game will try to load the scene from the addressables.

    I want to make my game easier, for that I want to save the addressables with some scenes in the CCD (not in the .apk file or some other place) and add more scenes to the addressables in the future.

    After reading the guides, I followed all the steps below.
    1. I added to addressables all scenes that should be in the CCD.
    2. Placed these scenes in a separate addressables group.
    3. In the Advanced Options of the group, I chose Pack Separately bundle mode to download 1 scene from the CCD, and not the entire address file.
    4. I configured Cloud Build to send the generated addressables on the CCD and make releases on the CCD.
    5. I changed the Remote Load Path in the addressables profile settings to the path to my CCD bucket with addressables.
    6. In the preloader of the scene, I try to load a scene with a CCD addressable like this
    Code (CSharp):
    1. var sceneTask = Addressables.LoadSceneAsync(sceneName, mode).Task;
    2. await sceneTask;
    3. var loadedScene = sceneTask.Result.Scene;
    sceneName - addressable name

    I feel like I missed something important. And yes, this method doesn't work.
     
    apkdev likes this.
  2. Steimond1

    Steimond1

    Joined:
    Jan 20, 2021
    Posts:
    12
    I just realized that I have to specify Build Path and Load Path to RemoteBuildPath and RemoteLoadPath in the Addresables group settings.
     
    apkdev likes this.
  3. RJSD3V

    RJSD3V

    Joined:
    Aug 30, 2019
    Posts:
    4
    Hi @Steimond1 , I tried using the same code you have mentioned above to load a scene deployed on Unity CCD, my application and editor freezes. Is there an alternative?
     
    GilbertoBitt likes this.