]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/menu/menu.qc
Merge branch 'terencehill/spectate_player' into 'master'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / menu / menu.qc
index fb6c4aeeda60a612cbe47ffe4c6804022b315c23..891235def666700cc2a0865d8809d9512a1b43ac 100644 (file)
@@ -50,7 +50,7 @@ void m_gamestatus()
        gamestatus = 0;
        if (isserver()) gamestatus |= GAME_ISSERVER;
        if (clientstate() == CS_CONNECTED || isdemo()) gamestatus |= GAME_CONNECTED;
-       if (cvar("developer")) gamestatus |= GAME_DEVELOPER;
+       if (cvar("developer") > 0) gamestatus |= GAME_DEVELOPER;
 }
 
 void m_init()
@@ -73,7 +73,7 @@ void m_init()
 #endif
 
        // list all game dirs (TEST)
-       if (cvar("developer"))
+       if (cvar("developer") > 0)
        {
                for (int i = 0; ; ++i)
                {
@@ -335,7 +335,8 @@ void drawBackground(string img, float a, string algn, float force1)
        if (main.mainNexposee.ModalController_state == 0) return;
        vector v = '0 0 0';
        int scalemode = SCALEMODE_CROP;
-       for (int i = 0, l = 0; i < strlen(algn); ++i)
+       int len = strlen(algn);
+       for (int i = 0, l = 0; i < len; ++i)
        {
                string c = substring(algn, i, 1);
                switch (c)