mirror of
https://github.com/DrBeef/ioq3quest.git
synced 2025-02-15 08:40:40 +00:00
Merge branch 'master' of https://github.com/DrBeef/ioq3quest
This commit is contained in:
commit
90059c4bbc
4 changed files with 61 additions and 51 deletions
Binary file not shown.
|
@ -250,13 +250,14 @@ GRAPHICS OPTIONS MENU
|
||||||
#define ID_RATIO 110
|
#define ID_RATIO 110
|
||||||
#define ID_REFRESHRATE 111
|
#define ID_REFRESHRATE 111
|
||||||
#define ID_DYNAMICLIGHTS 112
|
#define ID_DYNAMICLIGHTS 112
|
||||||
#define ID_SYNCEVERYFRAME 113
|
#define ID_RAILGUN 113
|
||||||
#define ID_SHADOWS 114
|
#define ID_SHADOWS 114
|
||||||
#define ID_PLAYERSHADOW 115
|
#define ID_PLAYERSHADOW 115
|
||||||
#define ID_GAMMA 116
|
#define ID_GAMMA 116
|
||||||
|
|
||||||
#define NUM_REFRESHRATE 4
|
#define NUM_REFRESHRATE 4
|
||||||
#define NUM_SHADOWS 3
|
#define NUM_SHADOWS 3
|
||||||
|
#define NUM_RAILGUN 2
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
menuframework_s menu;
|
menuframework_s menu;
|
||||||
|
@ -285,7 +286,7 @@ typedef struct {
|
||||||
menutext_s driverinfo;
|
menutext_s driverinfo;
|
||||||
menulist_s refreshrate;
|
menulist_s refreshrate;
|
||||||
menuradiobutton_s dynamiclights;
|
menuradiobutton_s dynamiclights;
|
||||||
menuradiobutton_s synceveryframe;
|
menulist_s railgun;
|
||||||
menulist_s shadows;
|
menulist_s shadows;
|
||||||
menulist_s playershadow;
|
menulist_s playershadow;
|
||||||
menuslider_s gamma;
|
menuslider_s gamma;
|
||||||
|
@ -308,7 +309,7 @@ typedef struct
|
||||||
qboolean extensions;
|
qboolean extensions;
|
||||||
int refreshrate;
|
int refreshrate;
|
||||||
qboolean dynamiclights;
|
qboolean dynamiclights;
|
||||||
qboolean synceveryframe;
|
int railgun;
|
||||||
int shadows;
|
int shadows;
|
||||||
int playershadow;
|
int playershadow;
|
||||||
float gamma;
|
float gamma;
|
||||||
|
@ -502,7 +503,7 @@ static void GraphicsOptions_GetInitialVideo( void )
|
||||||
// s_ivo.texturebits = s_graphicsoptions.texturebits.curvalue;
|
// s_ivo.texturebits = s_graphicsoptions.texturebits.curvalue;
|
||||||
s_ivo.refreshrate = s_graphicsoptions.refreshrate.curvalue;
|
s_ivo.refreshrate = s_graphicsoptions.refreshrate.curvalue;
|
||||||
s_ivo.dynamiclights = s_graphicsoptions.dynamiclights.curvalue;
|
s_ivo.dynamiclights = s_graphicsoptions.dynamiclights.curvalue;
|
||||||
s_ivo.synceveryframe = s_graphicsoptions.synceveryframe.curvalue;
|
s_ivo.railgun = s_graphicsoptions.railgun.curvalue;
|
||||||
s_ivo.shadows = s_graphicsoptions.refreshrate.curvalue;
|
s_ivo.shadows = s_graphicsoptions.refreshrate.curvalue;
|
||||||
s_ivo.playershadow = s_graphicsoptions.playershadow.curvalue;
|
s_ivo.playershadow = s_graphicsoptions.playershadow.curvalue;
|
||||||
s_ivo.gamma = s_graphicsoptions.gamma.curvalue;
|
s_ivo.gamma = s_graphicsoptions.gamma.curvalue;
|
||||||
|
@ -832,8 +833,8 @@ static void GraphicsOptions_Event( void* ptr, int event ) {
|
||||||
trap_Cvar_SetValue( "r_dynamiclight", s_graphicsoptions.dynamiclights.curvalue );
|
trap_Cvar_SetValue( "r_dynamiclight", s_graphicsoptions.dynamiclights.curvalue );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ID_SYNCEVERYFRAME:
|
case ID_RAILGUN:
|
||||||
trap_Cvar_SetValue( "r_finish", s_graphicsoptions.synceveryframe.curvalue );
|
trap_Cvar_SetValue( "cg_oldRail", s_graphicsoptions.railgun.curvalue );
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ID_SHADOWS: {
|
case ID_SHADOWS: {
|
||||||
|
@ -1095,7 +1096,7 @@ static void GraphicsOptions_SetMenuItems( void )
|
||||||
}
|
}
|
||||||
|
|
||||||
s_graphicsoptions.dynamiclights.curvalue = trap_Cvar_VariableValue( "r_dynamiclight" ) != 0;
|
s_graphicsoptions.dynamiclights.curvalue = trap_Cvar_VariableValue( "r_dynamiclight" ) != 0;
|
||||||
s_graphicsoptions.synceveryframe.curvalue = trap_Cvar_VariableValue( "r_finish" ) != 0;
|
s_graphicsoptions.railgun.curvalue = trap_Cvar_VariableValue( "cg_oldRail" );
|
||||||
s_graphicsoptions.gamma.curvalue = trap_Cvar_VariableValue( "r_gamma" );
|
s_graphicsoptions.gamma.curvalue = trap_Cvar_VariableValue( "r_gamma" );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1182,6 +1183,12 @@ void GraphicsOptions_MenuInit( void )
|
||||||
"High",
|
"High",
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
static const char *s_railgun[] =
|
||||||
|
{
|
||||||
|
"High",
|
||||||
|
"Low",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
int y;
|
int y;
|
||||||
|
|
||||||
|
@ -1322,16 +1329,6 @@ void GraphicsOptions_MenuInit( void )
|
||||||
s_graphicsoptions.refreshrate.numitems = NUM_REFRESHRATE;
|
s_graphicsoptions.refreshrate.numitems = NUM_REFRESHRATE;
|
||||||
y += BIGCHAR_HEIGHT+2;
|
y += BIGCHAR_HEIGHT+2;
|
||||||
|
|
||||||
// references "r_finish"
|
|
||||||
s_graphicsoptions.synceveryframe.generic.type = MTYPE_RADIOBUTTON;
|
|
||||||
s_graphicsoptions.synceveryframe.generic.name = "Sync Every Frame:";
|
|
||||||
s_graphicsoptions.synceveryframe.generic.flags = QMF_PULSEIFFOCUS|QMF_SMALLFONT;
|
|
||||||
s_graphicsoptions.synceveryframe.generic.x = 400;
|
|
||||||
s_graphicsoptions.synceveryframe.generic.y = y;
|
|
||||||
s_graphicsoptions.synceveryframe.generic.callback = GraphicsOptions_Event;
|
|
||||||
s_graphicsoptions.synceveryframe.generic.id = ID_SYNCEVERYFRAME;
|
|
||||||
y += BIGCHAR_HEIGHT+2;
|
|
||||||
|
|
||||||
// references "r_gamma"
|
// references "r_gamma"
|
||||||
s_graphicsoptions.gamma.generic.type = MTYPE_SLIDER;
|
s_graphicsoptions.gamma.generic.type = MTYPE_SLIDER;
|
||||||
s_graphicsoptions.gamma.generic.name = "Brightness:";
|
s_graphicsoptions.gamma.generic.name = "Brightness:";
|
||||||
|
@ -1344,6 +1341,18 @@ void GraphicsOptions_MenuInit( void )
|
||||||
s_graphicsoptions.gamma.maxvalue = 1.3f;
|
s_graphicsoptions.gamma.maxvalue = 1.3f;
|
||||||
y += BIGCHAR_HEIGHT+2;
|
y += BIGCHAR_HEIGHT+2;
|
||||||
|
|
||||||
|
// references "cg_oldRail"
|
||||||
|
s_graphicsoptions.railgun.generic.type = MTYPE_SPINCONTROL;
|
||||||
|
s_graphicsoptions.railgun.generic.name = "Railgun Effect:";
|
||||||
|
s_graphicsoptions.railgun.generic.flags = QMF_PULSEIFFOCUS|QMF_SMALLFONT;
|
||||||
|
s_graphicsoptions.railgun.generic.x = 400;
|
||||||
|
s_graphicsoptions.railgun.generic.y = y;
|
||||||
|
s_graphicsoptions.railgun.itemnames = s_railgun;
|
||||||
|
s_graphicsoptions.railgun.generic.callback = GraphicsOptions_Event;
|
||||||
|
s_graphicsoptions.railgun.generic.id = ID_RAILGUN;
|
||||||
|
s_graphicsoptions.railgun.numitems = NUM_RAILGUN;
|
||||||
|
y += BIGCHAR_HEIGHT+2;
|
||||||
|
|
||||||
// // references "r_colorbits"
|
// // references "r_colorbits"
|
||||||
// s_graphicsoptions.colordepth.generic.type = MTYPE_SPINCONTROL;
|
// s_graphicsoptions.colordepth.generic.type = MTYPE_SPINCONTROL;
|
||||||
// s_graphicsoptions.colordepth.generic.name = "Color Depth:";
|
// s_graphicsoptions.colordepth.generic.name = "Color Depth:";
|
||||||
|
@ -1489,7 +1498,7 @@ void GraphicsOptions_MenuInit( void )
|
||||||
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.ratio );
|
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.ratio );
|
||||||
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.mode );
|
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.mode );
|
||||||
Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.refreshrate );
|
Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.refreshrate );
|
||||||
Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.synceveryframe );
|
Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.railgun );
|
||||||
Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.gamma );
|
Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.gamma );
|
||||||
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.colordepth );
|
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.colordepth );
|
||||||
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.fs );
|
// Menu_AddItem( &s_graphicsoptions.menu, ( void * ) &s_graphicsoptions.fs );
|
||||||
|
|
|
@ -211,22 +211,6 @@ itemDef {
|
||||||
visible 0
|
visible 0
|
||||||
}
|
}
|
||||||
|
|
||||||
itemDef {
|
|
||||||
name graphics
|
|
||||||
group grpSystem
|
|
||||||
type ITEM_TYPE_YESNO
|
|
||||||
text "Sync Every Frame:"
|
|
||||||
cvar "r_finish"
|
|
||||||
rect 0 70 256 20
|
|
||||||
textalign ITEM_ALIGN_RIGHT
|
|
||||||
textalignx 133
|
|
||||||
textaligny 17
|
|
||||||
textscale .25
|
|
||||||
forecolor 1 1 1 1
|
|
||||||
visible 0
|
|
||||||
action { uiScript glCustom }
|
|
||||||
}
|
|
||||||
|
|
||||||
// itemDef {
|
// itemDef {
|
||||||
// name graphics
|
// name graphics
|
||||||
// group grpSystem
|
// group grpSystem
|
||||||
|
@ -250,6 +234,22 @@ itemDef {
|
||||||
type ITEM_TYPE_SLIDER
|
type ITEM_TYPE_SLIDER
|
||||||
text "Brightness:"
|
text "Brightness:"
|
||||||
cvarfloat "r_gamma" 0.1 0.8 1.3
|
cvarfloat "r_gamma" 0.1 0.8 1.3
|
||||||
|
rect 0 70 256 20
|
||||||
|
textalign ITEM_ALIGN_RIGHT
|
||||||
|
textalignx 133
|
||||||
|
textaligny 17
|
||||||
|
textscale .25
|
||||||
|
forecolor 1 1 1 1
|
||||||
|
visible 0
|
||||||
|
}
|
||||||
|
|
||||||
|
itemDef {
|
||||||
|
name graphics
|
||||||
|
group grpSystem
|
||||||
|
type ITEM_TYPE_MULTI
|
||||||
|
text "Railgun Effect:"
|
||||||
|
cvar "cg_oldRail"
|
||||||
|
cvarFloatList { "High" 0 "Low" 1 }
|
||||||
rect 0 90 256 20
|
rect 0 90 256 20
|
||||||
textalign ITEM_ALIGN_RIGHT
|
textalign ITEM_ALIGN_RIGHT
|
||||||
textalignx 133
|
textalignx 133
|
||||||
|
|
|
@ -115,21 +115,6 @@ itemDef {
|
||||||
visible 0
|
visible 0
|
||||||
}
|
}
|
||||||
|
|
||||||
itemDef {
|
|
||||||
name graphics
|
|
||||||
group grpSystem
|
|
||||||
type ITEM_TYPE_YESNO
|
|
||||||
text "Sync Every Frame:"
|
|
||||||
cvar "r_finish"
|
|
||||||
rect 99 67 256 20
|
|
||||||
textalign ITEM_ALIGN_RIGHT
|
|
||||||
textalignx 128
|
|
||||||
textaligny 20
|
|
||||||
textscale .333
|
|
||||||
forecolor 1 1 1 1
|
|
||||||
visible 1
|
|
||||||
}
|
|
||||||
|
|
||||||
// itemDef {
|
// itemDef {
|
||||||
// name graphics
|
// name graphics
|
||||||
// group grpSystem
|
// group grpSystem
|
||||||
|
@ -153,6 +138,22 @@ itemDef {
|
||||||
type ITEM_TYPE_SLIDER
|
type ITEM_TYPE_SLIDER
|
||||||
text "Brightness:"
|
text "Brightness:"
|
||||||
cvarfloat "r_gamma" 0.1 0.8 1.3
|
cvarfloat "r_gamma" 0.1 0.8 1.3
|
||||||
|
rect 99 67 256 20
|
||||||
|
textalign ITEM_ALIGN_RIGHT
|
||||||
|
textalignx 128
|
||||||
|
textaligny 20
|
||||||
|
textscale .333
|
||||||
|
forecolor 1 1 1 1
|
||||||
|
visible 0
|
||||||
|
}
|
||||||
|
|
||||||
|
itemDef {
|
||||||
|
name graphics
|
||||||
|
group grpSystem
|
||||||
|
type ITEM_TYPE_MULTI
|
||||||
|
text "Railgun Effect:"
|
||||||
|
cvar "cg_oldRail"
|
||||||
|
cvarFloatList { "High" 0 "Low" 1 }
|
||||||
rect 99 92 256 20
|
rect 99 92 256 20
|
||||||
textalign ITEM_ALIGN_RIGHT
|
textalign ITEM_ALIGN_RIGHT
|
||||||
textalignx 128
|
textalignx 128
|
||||||
|
|
Loading…
Reference in a new issue