[SceneLoader & AssetLoader] What different two?

I tried meshes importing.
Current success how was SceneLoader + .obj file.
And i’m still trying assetManager.addMeshTask().

This is easy at the PlayGround. [https://www.babylonjs-playground.com/#ZJYNY#177]
But this hard from case that used my meshes.

Next imported file was same.
Top case was logging well all meshes names.
But bottom case’s isCompleted was always false.

SceneLoader.ImportMesh('', 'static/resources/meshes/', 'back-ground.babylon', scene, meshes => {
  for (const mesh of meshes) {
    console.log(mesh.name);
  }
});

&

const meshTask = assetsM.addMeshTask(
  'bgTask',
  'BG',
  'static/resources/meshes/',
  'back-ground.babylon'
);
setInterval(() => {
  console.log(meshTask.isCompleted);
}, 100);

Two case was different? (directory connection part?).
OR my file was wrong? (exported from blender3D).back-ground.zip (1.7 KB)

Hello!

Do you have any error on the console? Or in the network tab?

Hi, @Deltakosh.

A visible this file at network tab.
And what more checking in network tab? (header, preview, response)?

it was not visible that Error log about import.
Um… not checked onTaskError().

Well I need a repro of the issue then. Maybe you can share it in the playground?

Doc: Using External Assets - Babylon.js Documentation

1 Like

Um. i figured out while coding at PG. [https://www.babylonjs-playground.com/#ZJYNY#180].
I was skip AssetsManager.load().
Sorry and thank you!

And I thought difference between .babylon and .obj. that’s axis. but i was wrong again.
i has set convert axis when exported .obj.

Anyway thanks again!

1 Like