[v3.1-alpha] Inspector fails to load after physics impostor is added to externally-loaded mesh
See original GitHub issueI’m fetching a low-poly tree model from an external .obj file via the AssetsManager
and adding a cylinder physics impostor after it has finished loading. All of this is working fine. Here’s my tree:
Next, I’m duplicating the tree and adding more because Bob Ross said they get lonely, but I digress.
Here’s the code:
var loader = new BABYLON.AssetsManager(scene);
var tree = loader.addMeshTask("happyTree", "", "meshes/", "tree.obj");
loader.load();
tree.onSuccess = function (task) {
var treeMesh = BABYLON.Mesh.MergeMeshes(task.loadedMeshes);
treeMesh.material = treeMaterial;
var tree1 = treeMesh.clone();
treeMesh.dispose();
tree1.position = new BABYLON.Vector3(-20, 17, 10);
tree1.physicsImpostor = new BABYLON.PhysicsImpostor(tree1, BABYLON.PhysicsImpostor.CylinderImpostor, { mass: 0, restitution: 8 }, scene);
...
}
If I comment out the line where I assign tree1.physicsImpostor
, the inspector loads fine. As it stands, this is what I’m seeing in the JS console:
I’m pulling down the relevant JS files from preview.babylonjs.com
just to make sure I have the latest and greatest. Seen on Chrome v60.0.3112.101 on Windows 10.
This is the first issue I’ve filed in this repo, so please let me know if I’ve forgotten anything!
Issue Analytics
- State:
- Created 6 years ago
- Comments:11 (8 by maintainers)
Top Results From Across the Web
Advanced Physics Features | Babylon.js Documentation
A heightmap is not a mesh impostor. It is possible that objects coming from the side will not collide with it. The heightmap...
Read more >Inspection Information for Residents - HUD
HUD property and unit inspections · Report an issue or concern · Step-by-step: REAC inspection process · Properties that fail inspection · Get...
Read more >Adding PhysicsImpostor turning meshes upside-down
I'm loading a mesh from a GLB file that I've exported from Blender. The problem I'm having is that as soon as I...
Read more >Motor Vehicle Inspection Regulations - New York DMV
79.2 Vehicles subject to inspection (Amended 12/29/10 and 7/01/12) . ... (d) If a vehicle subject to the OBD II emissions inspection fails...
Read more >Construction Inspections - City and County of Denver
Schedule an inspection. Inspections will be completed within 2 business days. Inspections cannot be scheduled for permits that are still under review.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Nailed it! That fixed the issue.
Thanks! 😄
Fixed in https://github.com/BabylonJS/Babylon.js/pull/3052