Skip to content

Commit 14eab22

Browse files
EkdohibsPilzAdam
authored andcommittedAug 6, 2013
Add minetest.registered_biomes
1 parent 96c34d3 commit 14eab22

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed
 

‎builtin/misc_register.lua

+7
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,13 @@ function minetest.register_alias(name, convert_to)
223223
end
224224
end
225225

226+
local register_biome_raw = minetest.register_biome
227+
minetest.registered_biomes = {}
228+
function minetest.register_biome(biome)
229+
minetest.registered_biomes[biome.name] = biome
230+
register_biome_raw(biome)
231+
end
232+
226233
-- Alias the forbidden item names to "" so they can't be
227234
-- created via itemstrings (e.g. /give)
228235
local name

2 commit comments

Comments
 (2)

EvergreenTheTree commented on Aug 6, 2013

@EvergreenTheTree
Contributor

Me thinks someone forgot to add this to the lua_api.txt.

PilzAdam commented on Aug 6, 2013

@PilzAdam
Contributor

@4Evergreen4 no, since register_biome() is not in lua-api.txt

Please sign in to comment.