]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
adding the possbility to use dualscreenresolution
authorDebugger <pyngot@hotmail.com>
Thu, 12 Sep 2013 20:32:53 +0000 (22:32 +0200)
committerDebugger <pyngot@hotmail.com>
Thu, 12 Sep 2013 20:32:53 +0000 (22:32 +0200)
defaultXonotic.cfg
qcsrc/menu/xonotic/slider_resolution.c

index 30a03a15a1ba68a0003e36b2753a6d1c2e9fa025..28c1af69dadf7a009b3da3fe094d7116640ff7a9 100644 (file)
@@ -99,6 +99,7 @@ set _menu_vid_width "$vid_width"
 set _menu_vid_height "$vid_height"
 set _menu_vid_pixelheight "$vid_pixelheight"
 seta menu_vid_scale 0
+seta menu_vid_allowdualscreenresolution 0
 // 2D resolution 800x600
 vid_conwidth 800
 vid_conheight 600
index 8bd47e799983abe4207446224c390a6441e4d1bc..b08aac86f2b2c7d555f942e7ab7b4836a9eee76c 100644 (file)
@@ -75,6 +75,7 @@ void XonoticResolutionSlider_addResolution(entity me, float w, float h, float pi
 void XonoticResolutionSlider_configureXonoticResolutionSlider(entity me)
 {
        float i;
+       float autocvar_menu_vid_allowdualscreenresolution = 0;
        vector r0, r;
 
        me.configureXonoticTextSlider(me, "_menu_vid_width");
@@ -93,7 +94,9 @@ void XonoticResolutionSlider_configureXonoticResolutionSlider(entity me)
                if(r_x < 640 || r_y < 480)
                        continue;
                if(r_x > 2 * r_y) // likely dualscreen resolution, skip this one
-                       continue;
+                       if(autocvar_menu_vid_allowdualscreenresolution == 0)
+                               continue;
+                       
                me.addResolution(me, r_x, r_y, r_z);
        }