AssetManager Not loading

Hey everyone,

I have an assetManager i already use for loading image and texture assets. I am now trying to add a single mesh, so i create a meshTask. I added a small onSuccess function to just console log success, and set a global var as the task.loadedMeshes[0]. I get the success however when i try to use that mesh later on i get error undefined. So i console logged that whole array (task.loadedMeshes) and it was empty, which is very strange. I was however able to get the mesh into my scene using BABYLON.SceneLoader.Append with the same file.
So what i dont understand is why might my assetManager not work yet SceneLoader does work?
How can i get assetManager working?

The skeletons and particle systems array are also empty (as they should be)

Alright so it seems that what i was doing wrong is in the constructor i put a task name and mesh name, just made them up as i thought the constructor would name the mesh that name. It does not seem like that is the case, i made the name “” and now i have the mesh!

1 Like

Thanks for getting back to us

1 Like