support comments in language list file
authorRudolf Polzer <divverent@xonotic.org>
Wed, 22 Feb 2012 13:27:43 +0000 (14:27 +0100)
committerRudolf Polzer <divverent@xonotic.org>
Wed, 22 Feb 2012 13:27:43 +0000 (14:27 +0100)
qcsrc/menu/xonotic/languagelist.c

index 5f6226f..ebb947c 100644 (file)
@@ -155,6 +155,8 @@ void XonoticLanguageList_getLanguages(entity me)
        fh = fopen("languages.txt", FILE_READ);
        while((s = fgets(fh)))
        {
+               if(substring(s, 0, 2) == "//")
+                       continue; // comment
                n = tokenize_console(s);
                if(n < 3)
                        continue;