]> git.xonotic.org Git - xonotic/netradiant.git/blobdiff - radiant/environment.cpp
disable gtktheme compilation
[xonotic/netradiant.git] / radiant / environment.cpp
index 484258d79f73d1a04d3b2f078a3528c7da9317de..a84a7d42bc7ba0b10fc25b465aa2098fbff582ae 100644 (file)
@@ -110,7 +110,8 @@ bool gamedetect_check_game( char const *gamefile, const char *checkfile1, const
 void gamedetect(){
        // if we're inside a Nexuiz install
        // default to nexuiz.game (unless the user used an option to inhibit this)
-       bool nogamedetect = false;
+       //bool nogamedetect = false;
+       bool nogamedetect = true;
        int i;
        for ( i = 1; i < g_argc - 1; ++i )
        {
@@ -264,6 +265,18 @@ void environment_init( int argc, char const* argv[] ){
 
 #include <windows.h>
 
+char* openCmdMap;
+
+void cmdMap(){
+       openCmdMap = NULL;
+       for ( int i = 1; i < g_argc; ++i )
+       {
+               if ( !stricmp( g_argv[i] + strlen(g_argv[i]) - 4, ".map" ) ){
+                       openCmdMap = g_argv[i];
+               }
+       }
+}
+
 void environment_init( int argc, char const* argv[] ){
        args_init( argc, argv );
 
@@ -293,6 +306,7 @@ void environment_init( int argc, char const* argv[] ){
                home_path = home.c_str();
        }
        gamedetect();
+       cmdMap();
 }
 
 #else