Add get_biome_id(biome_name) callback
authorDuane Robertson <duane@duanerobertson.com>
Tue, 29 Sep 2015 17:38:08 +0000 (12:38 -0500)
committerest31 <MTest31@outlook.com>
Fri, 2 Oct 2015 20:49:31 +0000 (22:49 +0200)
commita5bdfb6b3cfddaac1e961bd8c8780c74ccde3567
tree3844d522cc817395be35dfac4d9d61f562d0854e
parent21944a0d3c5284f6bf1e61286ddbcc2ab2f1e2aa
Add get_biome_id(biome_name) callback

It returns the index used in mg->biomemap for a given biome name.
The biomemap is useless without this unless you re-register all existing biomes,
which could cause problems for anyone else trying to use biomemap.
With this, you can quickly create a lookup table of ids and names.
doc/lua_api.txt
src/script/lua_api/l_mapgen.cpp
src/script/lua_api/l_mapgen.h