From: Perttu Ahola Date: Sun, 20 May 2012 14:41:40 +0000 (+0300) Subject: Allow using --worldname for local game too X-Git-Url: http://81.2.79.47:8989/gitweb/?a=commitdiff_plain;h=388906ac70ff13c4a2b88833872b9123034f5d1a;p=zefram%2Fminetest%2Fminetest_engine.git Allow using --worldname for local game too --- diff --git a/src/main.cpp b/src/main.cpp index ec305d4b..a990032d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1037,6 +1037,31 @@ int main(int argc, char *argv[]) } } + // If a world name was specified, convert it to a path + if(commanded_worldname != ""){ + // Get information about available worlds + std::vector worldspecs = getAvailableWorlds(); + bool found = false; + for(u32 i=0; i worldspecs = getAvailableWorlds(); - world_path = ""; - for(u32 i=0; iget("name"); if(cmd_args.exists("name"))