- Home /
How can I implement "3D voxel digging"?
Like this: https://www.reddit.com/r/Unity3D/comments/8v96ie/i_implemented_3d_voxel_digging_for_a_treasure/
I've been searching for a while but I can't find any tutorials or explainations of how it's done. Would be grateful for answers :)
Answer by HighApp · Dec 30, 2019 at 10:03 AM
https://github.com/Eldemarkki/Marching-Cubes-Terrain https://www.youtube.com/watch?v=Tge_kwjj2So (code not mine),try using this: https://www.youtube.com/watch?v=Tge_kwjj2So
Answer by Esteem · Dec 29, 2019 at 09:04 AM
search for marching cubes science papers (either cs or sometimes it's in medical topology) and using that you can construct meshes. if you make a large 3D array of these marching cubes, you can create smaller meshes each drawing a small section of the whole. when you apply "pressure" to a point in space (the way they do in the example you provided) you can calculate the distance of all surrounding mesh sections and update their mesh data (you'll understand what it means when you read the papers)
Your answer
Follow this Question
Related Questions
What is wrong with this mesh editing code? 0 Answers
Manual culling of voxel faces? 0 Answers
Determining where a mesh triangle faces 1 Answer
Splitting a Mesh into Submeshes 2 Answers
Simple plane generation 1 Answer