minetest.register_on_generated

From Minetest Developer Wiki
Jump to: navigation, search

Contents

Syntax

minetest.register_on_generated(function(minp, maxp, blockseed))

Description

  • minp, maxpposition
  • blockseed — integer

Called after generating a piece of world; minp/maxp encompass a 5×5×5 volume of map blocks — that is, 80×80×80 nodes. Modifying nodes inside the area is a bit faster than usually, if voxel manipulation is used, modifying nodes is a lot faster.

minp.y is 48 + n * 80 by default

Examples

minetest.register_on_generated(function(minp, maxp, seed)
	local debug = "minp="..(minetest.pos_to_string(minp))..", maxp="..(minetest.pos_to_string(maxp))..", seed="..seed
	print(debug)
	minetest.chat_send_all(debug)
end)

voxel_manipulation#Example

See Also

Personal tools
Namespaces

Variants
Actions
Navigation
API
Toolbox