]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
Tomaz's patch to add fov to options menu
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 13 May 2004 19:10:44 +0000 (19:10 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 13 May 2004 19:10:44 +0000 (19:10 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4160 d7cf8633-e32d-0410-b094-e92efae38249

menu.c

diff --git a/menu.c b/menu.c
index c648333c63642d0e3b96332f1de9d14c1b4ab8b8..0a1289b13dd5eeac11ec4ed7fcaf8731862d4032 100644 (file)
--- a/menu.c
+++ b/menu.c
@@ -1168,7 +1168,7 @@ void M_DrawCheckbox (int x, int y, int on)
 }
 
 
-#define OPTIONS_ITEMS 36
+#define OPTIONS_ITEMS 37
 
 int options_cursor;
 
@@ -1203,6 +1203,8 @@ void M_Menu_Options_AdjustSliders (int dir)
                Cvar_SetValueQuick (&scr_conbrightness, bound(0, scr_conbrightness.value + dir * 0.2, 1));
        else if (options_cursor == optnum++)
                Cvar_SetValueQuick (&scr_viewsize, bound(30, scr_viewsize.value + dir * 10, 120));
+       else if (options_cursor == optnum++)
+               Cvar_SetValueQuick (&scr_fov, bound(1, scr_fov.integer + dir * 1, 170));
        else if (options_cursor == optnum++)
                Cvar_SetValueQuick (&scr_screenshot_jpeg, !scr_screenshot_jpeg.integer);
        else if (options_cursor == optnum++)
@@ -1331,6 +1333,7 @@ void M_Options_Draw (void)
        M_Options_PrintSlider(  "     Console Alpha", true, scr_conalpha.value, 0, 1);
        M_Options_PrintSlider(  "Conback Brightness", true, scr_conbrightness.value, 0, 1);
        M_Options_PrintSlider(  "       Screen size", true, scr_viewsize.value, 30, 120);
+       M_Options_PrintSlider(  "     Field of View", true, scr_fov.integer, 1, 170);
        M_Options_PrintCheckbox("  JPEG screenshots", jpeg_dll != NULL, scr_screenshot_jpeg.integer);
        M_Options_PrintSlider(  "      JPEG quality", jpeg_dll != NULL, scr_screenshot_jpeg_quality.value, 0, 1);
        M_Options_PrintCheckbox("               Sky", true, r_sky.integer);