Hello to everyone,
I create two cubes in “Blender” and export them in a single file (say, “scene.obj”).
Now, following the Car Triangle Mesh example (note the “onCarResourceComplete” method), I do the following:
private function _onResourceComplete(event : LoaderEvent) : void {
trace("load complete");
_loader.removeEventListener(LoaderEvent.RESOURCE_COMPLETE, _onResourceComplete);
_loader.removeEventListener(LoaderEvent.LOAD_ERROR, _onLoadError);
var container : ObjectContainer3D = ObjectContainer3D(event.target);
_view.scene.addChild(container);;
var cube : Mesh;
for (var i : uint = 0; i < container.numChildren; i++) {
cube = Mesh(container.getChildAt(i));
}
}
However, the cubes are not displayed on the screen.
Could someone, please, explain to me why?
What I am trying to do, eventually, is assign different “shapes” of the Away3DPhysics engine to each “cube”.
Thanks a lot.
P.S.: I attach the “.blend” and “.obj” files I used.