Add notice when only minimal is installed
authorrubenwardy <rubenwardy@gmail.com>
Thu, 16 Oct 2014 18:23:02 +0000 (19:23 +0100)
committerkwolekr <kwolekr@minetest.net>
Tue, 28 Oct 2014 17:17:14 +0000 (13:17 -0400)
builtin/mainmenu/dlg_create_world.lua
builtin/mainmenu/gamemgr.lua

index 5771d8b27d30b5bcc41cdbe4659ab76c60b9cb43..6d433bde4952958c01100e791cf237e419dc88d6 100644 (file)
@@ -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
 
index 64fb41b9dfa904b9b395107ba2356766cd5febea..b6faa71d9077aa1f49ad7608b4d0ada01640be02 100644 (file)
@@ -68,7 +68,7 @@ end
 function gamemgr.gamelist()
        local retval = ""
        if #gamemgr.games > 0 then
-               retval = retval .. gamemgr.games[1].id
+               retval = retval .. gamemgr.games[1].name
 
                for i=2,#gamemgr.games,1 do
                        retval = retval .. "," .. gamemgr.games[i].name