Ok so i did a research on about half of the internet to find how minecraft generates its terrain. All of the forums and other sites said that you will need to use noise function as density and then check if its above certain point or below and place a block.If you do this you get something different from when you use noise as height, there appear overhangs and more minecraft - like looking terrain. However it still doesnt look like minecraft terrain. What I want it to have is more natural looking overhangs and not so flat areas. So far I have this result: and . See, it doesnt look natural at all or atleast minecraft like. Here is my code:
math.randomseed(tick()) local smoothness = math.random(50,60) local seed = math.random(1,10e6) for x = 1, 500 do for z = 1, 500 do local height = math.noise(x/smoothness, z/smoothness, seed) --Find out the height for y = 1, (height*100)+10 do local height = math.noise(x/smoothness, z/smoothness, seed) * 4 --Find out the height local density = math.noise(x/smoothness, y/smoothness, z/smoothness) --Find out the density if y > 20 then if density >= 0 then workspace.Terrain:FillBall(Vector3.new(x * 2,y * 2,z * 2) , 5 , "Grass") end else workspace.Terrain:FillBall(Vector3.new(x * 2,y * 2,z * 2) , 5 , "Grass") end end end wait() end
*And yes Its a code of someone else code that i found on internet that i first used when i didnt understand and then forgot to write my own and just edited this one.
So what i want is a way to make this look like minecraft. Maybe through some algorithm since i cant find a way to. Maybe some genious can help.