Skip to content

Instantly share code, notes, and snippets.

@Jordach
Created September 16, 2012 10:08
Show Gist options
  • Save Jordach/3731863 to your computer and use it in GitHub Desktop.
Save Jordach/3731863 to your computer and use it in GitHub Desktop.
local grass_gen = function( minp, maxp )
if maxp.y < 40 then
for lx = minp.x, maxp.x do
for ly = minp.y, maxp.y do
for lz = minp.z, maxp.z do
local p = { x = lx, y = ly, z = lz }
local n = minetest.env:get_node( p )
minetest.env:add_node( p, { name = "default:dirt_with_grass" } )
end
end
end
end
end
end
minetest.register_on_generated( grass_gen )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment