How to make a physical object collide with the terrain of a loaded glb

I found a way to fix it.
I used AmmoJSPlugin to apply MeshImpostor to the root mesh, regardless of the number of getTotalVertices.
But, this will cause Out Of Memory (OOM), so we need to increase the memory used by Ammo.js.

Based on the descriptions here, I set TOTAL_MEMORY to 512MB, built, and used the created ammo.js, and a collision occurred.
I hope this helps someone out there!

1 Like