Add shutdown hook interface to Lua API
Scripts can call minetest.register_on_shutdown() to register a shutdown hook. Document that minetest.register_on_shutdown() callbacks may not be run If the server crashes, it is unlikely that callbacks registered using minetest.register_on_shutdown() will be called.
This commit is contained in:
parent
2d07416f38
commit
f171cb855f
|
@ -303,6 +303,7 @@ end
|
|||
|
||||
minetest.registered_on_chat_messages, minetest.register_on_chat_message = make_registration()
|
||||
minetest.registered_globalsteps, minetest.register_globalstep = make_registration()
|
||||
minetest.registered_on_shutdown, minetest.register_on_shutdown = make_registration()
|
||||
minetest.registered_on_punchnodes, minetest.register_on_punchnode = make_registration()
|
||||
minetest.registered_on_placenodes, minetest.register_on_placenode = make_registration()
|
||||
minetest.registered_on_dignodes, minetest.register_on_dignode = make_registration()
|
||||
|
|
Loading…
Reference in New Issue