This is very strange problem.When I use xampp for remote build and load, it’s everything ok, no any warning and error on console, but I upload files to storage the console show these warning and errors:
Addressables - initialization failed.
UnityEngine.AddressableAssets.Initialization.<>c__DisplayClass14_0:b__0(AsyncOperationHandle1) DelegateList
1:Invoke(AsyncOperationHandle`1) (at Library/PackageCache/com.unity.addressables@1.2.4/Runtime/ResourceManager/Util/DelegateList.cs:69)
UnityEngine.ResourceManagement.ResourceManager:Update(Single)
MonoBehaviourCallbackHooks:Update() (at Library/PackageCache/com.unity.addressables@1.2.4/Runtime/ResourceManager/Util/MonoBehaviourCallbackHooks.cs:19)
Exception encountered in operation UnityEngine.AddressableAssets.Initialization.InitializationOperation, result=‘’, status=‘Failed’ - Chain<CreatureStatusScriptableObject,IResourceLocator>: ChainOperation of Type: CreatureStatusScriptableObject failed because dependent operation failed
Exception of type ‘UnityEngine.AddressableAssets.InvalidKeyException’ was thrown., Key=10e36542c8eb2f54789effdec6e2a093
UnityEngine.ResourceManagement.ChainOperation2:OnWrappedCompleted(AsyncOperationHandle
1)
DelegateList1:Invoke(AsyncOperationHandle
1) (at Library/PackageCache/com.unity.addressables@1.2.4/Runtime/ResourceManager/Util/DelegateList.cs:69)
UnityEngine.ResourceManagement.ResourceManager:Update(Single)
MonoBehaviourCallbackHooks:Update() (at Library/PackageCache/com.unity.addressables@1.2.4/Runtime/ResourceManager/Util/MonoBehaviourCallbackHooks.cs:19)
Here is my addressable setting:
Here is how I get asset:
public AssetReference creatureStatus_SO;
public Text text;
private void Start()
{
Addressables.LoadAssetAsync<CreatureStatusScriptableObject>(creatureStatus_SO).Completed += OnLoadComplete;
}
private void OnLoadComplete(AsyncOperationHandle<CreatureStatusScriptableObject> obj)
{
text.text = obj.Result.power.ToString();
}