]> git.lizzy.rs Git - minetest.git/blobdiff - src/game.cpp
command-line/world game selection
[minetest.git] / src / game.cpp
index 0e3f570f493770e41681ba14a660fd5f9969f6d6..ebf5028b7fb5e1ee64a61b40276923433030cb7a 100644 (file)
@@ -51,6 +51,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
 #include "itemdef.h"
 #include "tile.h" // For TextureSource
 #include "logoutputbuffer.h"
+#include "subgame.h"
 
 /*
        Setting this to 1 enables a special camera mode that forces
@@ -651,11 +652,12 @@ void the_game(
        std::string map_dir,
        std::string playername,
        std::string password,
-       std::string address,
+       std::string address, // If "", local server is used
        u16 port,
        std::wstring &error_message,
        std::string configpath,
-       ChatBackend &chat_backend
+       ChatBackend &chat_backend,
+       const SubgameSpec &gamespec // Used for local game
 )
 {
        video::IVideoDriver* driver = device->getVideoDriver();
@@ -705,7 +707,7 @@ void the_game(
        if(address == ""){
                draw_load_screen(L"Creating server...", driver, font);
                infostream<<"Creating server"<<std::endl;
-               server = new Server(map_dir, configpath, "mesetint");
+               server = new Server(map_dir, configpath, gamespec);
                server->start(port);
        }