From 6f2d9de7691c99b833f71c1414230c5d04c42ae0 Mon Sep 17 00:00:00 2001 From: PilzAdam Date: Sun, 18 Oct 2015 10:41:52 +0200 Subject: Improve Lua settings menu * Add key settings to setting table and ignore them later This way they are added to the auto-generated minetest.conf.example * Add flags type * Add input validation for int, float and flags * Break in-game graphic settings into multiple sections * Parse settingtpes.txt in mods and games * Improve description for a lot of settings * Fix typos and wording in settingtypes.txt * Convert language setting to an enum --- doc/lua_api.txt | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'doc/lua_api.txt') diff --git a/doc/lua_api.txt b/doc/lua_api.txt index 52da2d095..e9d19ad27 100644 --- a/doc/lua_api.txt +++ b/doc/lua_api.txt @@ -64,6 +64,8 @@ e.g. The game directory can contain the file minetest.conf, which will be used to set default settings when running the particular game. +It can also contain a settingtypes.txt in the same format as the one in builtin. +This settingtypes.txt will be parsed by the menu and the settings will be displayed in the "Games" category in the settings tab. ### Menu images @@ -125,6 +127,7 @@ Mod directory structure | |-- depends.txt | |-- screenshot.png | |-- description.txt + | |-- settingtypes.txt | |-- init.lua | |-- models | |-- textures @@ -155,6 +158,10 @@ A screenshot shown in modmanager within mainmenu. ### `description.txt` A File containing description to be shown within mainmenu. +### `settingtypes.txt` +A file in the same format as the one in builtin. It will be parsed by the +settings menu and the settings will be displayed in the "Mods" category. + ### `init.lua` The main Lua script. Running this script should register everything it wants to register. Subsequent execution depends on minetest calling the -- cgit v1.2.3