diff options
author | kwolekr <kwolekr@minetest.net> | 2014-12-29 12:58:55 -0500 |
---|---|---|
committer | kwolekr <kwolekr@minetest.net> | 2014-12-29 12:59:59 -0500 |
commit | 5e2753c712e8f65fa50f4889fc1422393ba21413 (patch) | |
tree | 04aab9306f77497e712ad13ae3445d878280881d /builtin | |
parent | ff3cfb746e203ed02160de09b1912b543c5a25f0 (diff) | |
download | minetest-5e2753c712e8f65fa50f4889fc1422393ba21413.tar.gz minetest-5e2753c712e8f65fa50f4889fc1422393ba21413.tar.bz2 minetest-5e2753c712e8f65fa50f4889fc1422393ba21413.zip |
Expose mapgen parameters on scripting init
Add minetest.get_mapgen_params()
Deprecate minetest.register_on_mapgen_init()
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/game/register.lua | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/builtin/game/register.lua b/builtin/game/register.lua index 1c9e62422..f7ebdee9a 100644 --- a/builtin/game/register.lua +++ b/builtin/game/register.lua @@ -390,7 +390,6 @@ end core.registered_on_chat_messages, core.register_on_chat_message = make_registration() core.registered_globalsteps, core.register_globalstep = make_registration() core.registered_playerevents, core.register_playerevent = make_registration() -core.registered_on_mapgen_inits, core.register_on_mapgen_init = make_registration() core.registered_on_shutdown, core.register_on_shutdown = make_registration() core.registered_on_punchnodes, core.register_on_punchnode = make_registration() core.registered_on_placenodes, core.register_on_placenode = make_registration() @@ -409,3 +408,9 @@ core.registered_craft_predicts, core.register_craft_predict = make_registration( core.registered_on_protection_violation, core.register_on_protection_violation = make_registration() core.registered_on_item_eats, core.register_on_item_eat = make_registration() +-- +-- Compatibility for on_mapgen_init() +-- + +core.register_on_mapgen_init = function(func) func(core.get_mapgen_params()) end + |