Cave Systems - 3D Perlin Noise


I was able to get 3D perlin noise working which allows for cave systems to be added into the game. Game world optimization is the next step.. Wish me luck.

Script Not mine - C#

public static float Perlin3D(float x, float y, float z) {
        float ab = Mathf.PerlinNoise(x, y);
        float ba = Mathf.PerlinNoise(y, x);

        float bc = Mathf.PerlinNoise(y, z);
        float cb = Mathf.PerlinNoise(z, y);

        float ac = Mathf.PerlinNoise(x, z);
        float ca = Mathf.PerlinNoise(z, x);

        float abc = ab + bc + ac + ba + cb + ca;
        return abc / 6f;
    }

Get Cavecraft - A Minecraft Clone