Guillem Serra | Portfolio
{ video games programmer }
Procedural cave generation
UnityProcgen

April 2019
Editor to create hexagonal cave levels.
Test with the editor my procedural generation algorithm, made in C# in Unity.
The original game that uses it is Deep Beneath.
Algorithm process:
Random positions in 2D hexagon grid. 3D Hexagonal Caves instantiation, walls cutting. Graph creation based on hexs (nodes). Edges creation (tunnels) based on walls normals and checking intersections. Breadth First Search to check if the level is explorable. Tunnels instantiation according to edges. Props instantiation. Rocks instantiation using Poisson-Disc Sampling algorithm. Falling Path creation (slightly different algorithm). 3D assets by Pol Blanes & Adrià Fret.
You can download the project on GitHub.








Deep Beneath: