Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Update Addressables window contents

Discussion in 'Addressables' started by LarsGameloft, Oct 4, 2019.

  1. LarsGameloft

    LarsGameloft

    Joined:
    Jun 4, 2019
    Posts:
    31
    So after adding assets to a group in the addressables window, using c#, the group created is empty, but if I close and open the tab the group has assets, I assume I am not refreshing the data for the window. After adding the assets to the group I tried :

    AssetDatabase.Refresh();
    and
    EditorUtility.SetDirty();

    Is there something else I could use?
    Thank you
     
  2. unity_bill

    unity_bill

    Joined:
    Apr 11, 2017
    Posts:
    1,053
    What API are you using to set the thing as addressable? Most of our API's have a "postEvent" flag you can optionally set. When true they'll post an event that the GUI is listening for, triggering it to reload. Perhaps you are calling something with that set to false?
     
  3. LarsGameloft

    LarsGameloft

    Joined:
    Jun 4, 2019
    Posts:
    31
    Yes I was calling it with false. Its working now, thank you.
     
    unity_bill likes this.