-
Notifications
You must be signed in to change notification settings - Fork 124
Using latest threejs #42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: gh-pages
Are you sure you want to change the base?
Using latest threejs #42
Conversation
|
This is great, thanks for contributing! It is going to take me some time to be able to give this a thorough review, but I just want to let you know that it is on my radar and it looks pretty good at first glance. |
Awesome. Would you be interested in me integrating a physics library with the terrain so a character could walk across the terrain with varying height maps, or I could have objects or something drop in? Not sure how hard it would be yet. I just created a new threejs example PR with basic terrain and heightmaps using Rapier. |
|
I don't think most physics libraries would need explicit integration with this library. To let a character walk across the terrain, just cast a ray down from the character's position and check where it intersects with the terrain. No physics library needed for that. For something more complex, depending on the physics library you're working with, you could pass the mesh itself or the vertices to create a hull. But if you have something specific in mind where an integration would be helpful, I'd be interested to hear about it. |
|
Thank you for the answer. I've been trying to get heightfield with physics working with three.terrain like this example I added to three.js, ported from ammo: https://raw.githack.com/andytriboletti/three.js/dev/examples/physics_rapier_terrain.html I haven't been able to get it working. So I will try your suggestion with raycasting. It would be nice to get the physics_rapier_terrain sample working with this project I think but I may be wrong. I noticed my changes renamed Three.Terrain to TerrainNS because you can no longer modify Three.js objects, right? Also, I tried using this and couldn't figure out how to use the packaged version so I just used the modules importing index. There's a lot still to do, including updating docs, so I understand if it takes a while to review/do your part. Also, you could make a list of things to do for me for this PR and I could do them. I think you had bower setup before, I wanted an easy way to develop with hot reloading so I chose Vite. |
Hello! I like this library.
I updated it to use the latest version of threejs!
I added npm start which will start a vite dev server.
I am happy to correct any mistakes.
Live demo
https://raw.githack.com/andytriboletti/THREE.Terrain/using-latest-threejs/index.html