- Home /
AsyncOperationHandle.Task is null
Hi!
I'm working with Unity's Addressable's system and after calling Addressables.LoadAssetAsync<T>(location);
on a location that's already been loaded, it returns an AsyncOperationHandle<T>
with Task
as null, causing a null reference exception here: T obj = await handle.Task as T;
I believe it's because an exception is occurring inside of LoadAssetAsync
and it returns an empty AsyncOperationHandle, since it's a struct it can't be null, but I don't know exactly why that could be happening. Is there somewhere in the docs that could state exactly why a handle's Task
var would be left null, I've checked handle.OperationException
already, it's also null.
Thanks in advance!
same question. I run two async one after the other. When the previous async has not completed, I have it await for the previous AsyncOperationHandle.Task , however AsyncOperationHandle.Task become null and the second async throw an error
Your answer
Follow this Question
Related Questions
Creating a fade out and in transition for loading. Functions not executing in order. 1 Answer
Async parse.com query not working on Android/iOS 2 Answers
Instantiate fails with no errors 0 Answers
Take screenshot and use it as texture using ScreenCapture 2 Answers
Identify unity advertisement is finished from another script? 1 Answer