Search Unity

Unity Addressable is too confusing and very hard to use.

Discussion in 'Documentation' started by zoudarren7, Mar 29, 2021.

  1. zoudarren7

    zoudarren7

    Joined:
    Jul 24, 2019
    Posts:
    11
    I create a prefab, add everything i need on it, animations, scripts etc.. then click the addressable button.

    addressables -> groups -> built -> default built. set up upload files generated by addressable in ServerData ->iOS. Then set remote path of the server.

    Then I build and run on iOS. Didn't work. I click -> addressables -> groups -> built -> default built AGAIN.

    It works. But how? I thought by doing build, the file changes and i have to reupload the updated files. But it works. So I try to reproduce what I did, and it stopped working again!

    Lastest verion of unity and addressable



    this is the error

    Code (CSharp):
    1. MissingMethodException: Default constructor not found for type UnityEngine.ResourceManagement.AsyncOperations.ProviderOperation`1[[UnityEngine.AddressableAssets.Initialization.ResourceManagerRuntimeData, Unity.Addressables, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]
    2.   at System.RuntimeType.CreateInstanceMono (System.Boolean nonPublic) [0x00000] in <00000000000000000000000000000000>:0
    3.   at System.Activator.CreateInstance (System.Type type, System.Boolean nonPublic) [0x00000] in <00000000000000000000000000000000>:0
    4.   at UnityEngine.ResourceManagement.Util.LRUCacheAllocationStrategy.New (System.Type type, System.Int32 typeHash) [0x00000] in <00000000000000000000000000000000>:0
    5.   at UnityEngine.ResourceManagement.ResourceManager.CreateOperation[T] (System.Type actualType, System.Int32 typeHash, System.Int32 operationHash, System.Action`1[T] onDestroyAction) [0x00000] in <00000000000000000000000000000000>:0
    6.   at UnityEngine.ResourceManagement.ResourceManager.ProvideResource (UnityEngine.ResourceManagement.ResourceLocations.IResourceLocation location, System.Type desiredType, System.Boolean releaseDependenciesOnFailure) [0x00000] in <00000000000000000000000000000000>:0
    7.   at UnityEngine.ResourceManagement.ResourceManager.ProvideResource[TObject] (UnityEngine.ResourceManagement.ResourceLocations.IResourceLocation location) [0x00000] in <00000000000000000000000000000000>:0
    8.   at UnityEngine.AddressableAssets.Initialization.InitializationOperation.CreateInitializationOperation (UnityEngine.AddressableAssets.AddressablesImpl aa, System.String playerSettingsLocation, System.String providerSuffix) [0x00000] in <00000000000000000000000000000000>:0
    9.   at UnityEngine.AddressableAssets.AddressablesImpl.InitializeAsync (System.String runtimeDataPath, System.String providerSuffix, System.Boolean autoReleaseHandle) [0x00000] in <00000000000000000000000000000000>:0
    10.   at UnityEngine.AddressableAssets.AddressablesImpl.InitializeAsync () [0x00000] in <00000000000000000000000000000000>:0
    11.   at UnityEngine.AddressableAssets.AddressablesImpl.get_ChainOperation () [0x00000] in <00000000000000000000000000000000>:0
    12.   at UnityEngine.AddressableAssets.AddressablesImpl.InstantiateAsync (System.Object key, UnityEngine.ResourceManagement.ResourceProviders.InstantiationParameters instantiateParameters, System.Boolean trackHandle) [0x00000] in <00000000000000000000000000000000>:0
    13.   at UnityEngine.AddressableAssets.AddressablesImpl.InstantiateAsync (System.Object key, UnityEngine.Transform parent, System.Boolean instantiateInWorldSpace, System.Boolean trackHandle) [0x00000] in <00000000000000000000000000000000>:0
    14.   at UnityEngine.AddressableAssets.Addressables.InstantiateAsync (System.Object key, UnityEngine.Transform parent, System.Boolean instantiateInWorldSpace, System.Boolean trackHandle) [0x00000] in <00000000000000000000000000000000>:0
    15.   at UnityEngine.AddressableAssets.AssetReference.InstantiateAsync (UnityEngine.Transform parent, System.Boolean instantiateInWorldSpace) [0x00000] in <00000000000000000000000000000000>:0
    16.   at avatar.Start () [0x00000] in <00000000000000000000000000000000>:0
     
  2. Baste

    Baste

    Joined:
    Jan 24, 2013
    Posts:
    6,338
    You should post here, your post has nothing to do with documentation