Asteroid Hunter
This is my 3D project while learning Unity. I started learning how could I destroy meshes in real time and learning about Triangulation algorithms like Bowyer-Watson or Quickhull. However, mesh destruction is a pretty well known topic and it is far from easy. So I decided to use the 3D Marching Cubes algorithm which is known for creating procedural environments and even destruct them. This algorithm does not triangulate per se, it divides the 3D space in cubes and the several ways a cube can be drawn, depending on which vertices has active, are already known and located in a look up table.
In the end, I settled with a simple runner to try out this algorithm. I also wanted to convey the feel of being inside an asteroid and trying to escape.
- Procedural mesh generation for the asteroids
- 3D Marching Cubes algorithm implementation for vertices and triangles.
- Triplanar mapping for UV mapping the asteroid texture.
- Dinamic destruction for the asteroids rebuilding the mesh on impact.
- Player movement.
- Shaders for player attacks (shots and laser).
- Camera options (back camera or first person camera).
- Turning on flashlights automatically when player is inside an asteroid.
- Spawning asteroids system.