]> git.lizzy.rs Git - minetest.git/blobdiff - doc/menu_lua_api.txt
Attached particle spawners
[minetest.git] / doc / menu_lua_api.txt
index e5ba46d4c0998e63eb259c59a757256682d8b262..479880266fca9144f3bad955d07786e5d41256cd 100644 (file)
@@ -1,4 +1,4 @@
-Minetest Lua Mainmenu API Reference 0.4.12
+Minetest Lua Mainmenu API Reference 0.4.14
 ========================================
 
 Introduction
@@ -31,8 +31,8 @@ core.start()
 core.close()
 
 Filesystem:
-core.get_scriptdir()
-^ returns directory of script
+core.get_builtin_path()
+^ returns path to builtin root
 core.get_modpath() (possible in async calls)
 ^ returns path to global modpath
 core.get_modstore_details(modid) (possible in async calls)
@@ -59,10 +59,6 @@ core.get_gamepath() (possible in async calls)
 ^ returns path to global gamepath
 core.get_texturepath() (possible in async calls)
 ^ returns path to default textures
-core.get_dirlist(path,onlydirs) (possible in async calls)
-^ path to get subdirs from
-^ onlydirs should result contain only dirs?
-^ returns list of folders within path
 core.create_dir(absolute_path) (possible in async calls)
 ^ absolute_path to directory to create (needs to be absolute)
 ^ returns true/false
@@ -145,8 +141,8 @@ core.get_game(index)
        addon_mods_paths = {[1] = <path>,},
 }
 core.get_games() -> table of all games in upper format (possible in async calls)
-core.get_mapgen_names() -> table of all map generator algorithms registered in
-                           the core (possible in async calls)
+core.get_mapgen_names([include_hidden=false]) -> table of map generator algorithms
+    registered in the core (possible in async calls)
 
 Favorites:
 core.get_favorites(location) -> list of favorites (possible in async calls)
@@ -195,6 +191,8 @@ core.create_world(worldname, gameid)
 core.delete_world(index)
 
 Helpers:
+core.get_us_time()
+^ returns time with microsecond precision
 core.gettext(string) -> string
 ^ look up the translation of a string in the gettext message catalog
 fgettext_ne(string, ...)
@@ -212,6 +210,10 @@ string:trim()
 ^ eg. string.trim("\n \t\tfoo bar\t ") == "foo bar"
 core.is_yes(arg) (possible in async calls)
 ^ returns whether arg can be interpreted as yes
+minetest.encode_base64(string) (possible in async calls)
+^ Encodes a string in base64.
+minetest.decode_base64(string) (possible in async calls)
+^ Decodes a string encoded in base64.
 
 Version compat:
 core.get_min_supp_proto()