I’m trying to create a rough and natural-looking vertical shaft through earth – specifically, the rabbit hole from Alice’s Adventures in Wonderland.
I love the terrain object, but it doesn’t appear to let me craft something along the vertical axis. Basically, I want to procedure-generate a straight, vertical cave, with nice bumpy walls. The closest I’ve come is importing said tunnel from Blender, but for the life of me I can’t figure out UV mapping, so the tunnel has no texture.
(I also tried painstakingly crafting a wall from planes, but oy. That didn’t seem feasible.)
Any ideas? Do I just need to learn Blender better?
The built-in Unity terrain does not allow you to create tunnels - vertical or horizontal. If you really like using it, you could model the side of your hole and then export the terrain as a mesh (using, say, Terrain2Obj script, or T4M asset). Then rotate the mesh in Blender and re-import as an FBX.
I would model few chunks of dirt and rocks and tell the script to spawn them one by one downwards, I would use Random.range(min, max) to offset each one of them so the cave would look random (you dont want to offset them to much ore holes might appear) and using the same function make there rotation random as well. Make few of these spawners and arrange them in a circle of needed size, this way they will all spawn those chunks at once making infinite rings of earth and rocks growing downwards. When modeling keep in mind that they will have to intersect one another to avoid holes.