Quantcast
Viewing all articles
Browse latest Browse all 388

How to clone the loaded model?

I want to clone the already loaded model and inserted into another location on the map. At the end of the time.

var loader = new BABYLON.AssetsManager(scene);
var taskMesh = loader.addMeshTask('t3', "", "game/t3/", "t.babylon");
taskMesh.onSuccess = function (task) {
   task.loadedMeshes[0].position = new BABYLON.Vector3(0, 0, 0);
   task.loadedMeshes[0].parent = camera;
};

I have not found. Maybe something like this?

taskMesh.loadedMeshes[0].clone();

Viewing all articles
Browse latest Browse all 388

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>