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 30a03a1..28c1af6 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 8bd47e7..b08aac8 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);
        }