X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=builtin%2Fmainmenu%2Fdlg_create_world.lua;h=32e1fbf8304b1779a14a7569417a1942d1114da2;hb=5cf911ffe140e447e6ec3791e2244ae5dd0361d8;hp=5771d8b27d30b5bcc41cdbe4659ab76c60b9cb43;hpb=15f3713e2f2f272c8f6b8d59e507c9af8417f26e;p=oweals%2Fminetest.git diff --git a/builtin/mainmenu/dlg_create_world.lua b/builtin/mainmenu/dlg_create_world.lua index 5771d8b27..32e1fbf83 100644 --- a/builtin/mainmenu/dlg_create_world.lua +++ b/builtin/mainmenu/dlg_create_world.lua @@ -16,7 +16,7 @@ --51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. local function create_world_formspec(dialogdata) - local mapgens = {"v6", "v7", "singlenode"} + local mapgens = core.get_mapgen_names() local current_seed = core.setting_get("fixed_map_seed") or "" local current_mg = core.setting_get("mg_name") @@ -62,6 +62,16 @@ local function create_world_formspec(dialogdata) "button[5,5.5;2.6,0.5;world_create_confirm;" .. fgettext("Create") .. "]" .. "button[7.5,5.5;2.8,0.5;world_create_cancel;" .. fgettext("Cancel") .. "]" + + if #gamemgr.games == 0 then + retval = retval .. "box[2,4;8,1;#ff8800]label[2.25,4;" .. + fgettext("You have no subgames installed.") .. "]label[2.25,4.4;" .. + fgettext("Download one from minetest.net") .. "]" + elseif #gamemgr.games == 1 and gamemgr.games[1].id == "minimal" then + retval = retval .. "box[1.75,4;8.7,1;#ff8800]label[2,4;" .. + fgettext("Warning: The minimal development test is meant for developers.") .. "]label[2,4.4;" .. + fgettext("Download a subgame, such as minetest_game, from minetest.net") .. "]" + end return retval