]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Use default path if menu skin does not have the gametype icon
authorMario <mario.mario@y7mail.com>
Wed, 11 Jun 2014 05:09:06 +0000 (15:09 +1000)
committerMario <mario.mario@y7mail.com>
Wed, 11 Jun 2014 05:09:06 +0000 (15:09 +1000)
qcsrc/client/mapvoting.qc

index a3f5d45e9e996d7a712c64074f8e6ec0b094b04b..94f4809698b0c16bd3c81ca11682f6bd0d1d70f7 100644 (file)
@@ -570,7 +570,11 @@ void MapVote_Init()
                if(gametypevote)
                {
                        //map = strzone(strcat("gfx/menu/default/gametype_", map));
-                       map = strzone(sprintf("gfx/menu/%s/gametype_%s", autocvar_menu_skin, map));
+                       //map = strzone(sprintf("gfx/menu/%s/gametype_%s", autocvar_menu_skin, map));
+                       string mv_picpath = sprintf("gfx/menu/%s/gametype_%s", autocvar_menu_skin, map);
+                       if(precache_pic(mv_picpath) == "")
+                               mv_picpath = strcat("gfx/menu/default/gametype_", map);
+                       map = strzone(mv_picpath);
                        mv_pics[i] = map;
                        mv_preview[i] = PreviewExists(map);
                }