Voxel generation

That makes sense XD Few tweaking of things and I managed to also figure out how to make dirt go on blocks below green ones (doesn’t always work, but I guess it’s close enough :smiley: ) :+1:

If you know of a way to actually make blocks below the green ones brown 100% then that would be amazing

Changed the parts to be models too :smiley:


Can see that the grass parts still spawn below other grass parts tho :confused:

if d > 0 and d < 0.04 then
					local block
					if d > 0.0175 then
						block = script.Dirt:Clone()
					else
						block = script.Grass:Clone()
					end
					
					block:SetPrimaryPartCFrame(CFrame.new(x * 4, y * 4, z * 4))
					block.Parent = workspace
				end

And what about getting different heights? Ways to see how high the actual blocks are, allowing change to color based on height, or overhangs? Instead of just being hills

And is there a faster way to generate the land? If I have it so the player doesnt spawn till all the land has been created then it takes forever? Would I be best to say ‘create’ the land via the code, but not insert the blocks unless the player is within a certain radious of the blocks?