Skip to content

Commit

Permalink
More cvar descriptions and minor corrections.
Browse files Browse the repository at this point in the history
  • Loading branch information
ToKu authored and ToKu committed Oct 31, 2022
1 parent 6fe4ff1 commit fb9f727
Show file tree
Hide file tree
Showing 15 changed files with 50 additions and 43 deletions.
2 changes: 1 addition & 1 deletion code/client/cl_input.c
Original file line number Diff line number Diff line change
Expand Up @@ -970,7 +970,7 @@ void CL_InitInput( void ) {
Cvar_SetDescription( cl_maxpackets, "Set how many client packets are sent to the server per second, can't exceed \\com_maxFPS." );
cl_packetdup = Cvar_Get( "cl_packetdup", "1", CVAR_ARCHIVE_ND );
Cvar_CheckRange( cl_packetdup, "0", "5", CV_INTEGER );
Cvar_SetDescription( cl_packetdup, "Limits the number of previous client commands added in packet, helps in packetloss mitigation, increases client command packets size a bit." );
Cvar_SetDescription( cl_packetdup, "Limits the number of previous client commands added in packet, helps in packet loss mitigation, increases client command packets size a bit." );

cl_run = Cvar_Get( "cl_run", "1", CVAR_ARCHIVE_ND );
Cvar_SetDescription( cl_run, "Persistent player running movement." );
Expand Down
6 changes: 4 additions & 2 deletions code/client/cl_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -3767,7 +3767,7 @@ static void CL_InitGLimp_Cvars( void )

r_noborder = Cvar_Get( "r_noborder", "0", CVAR_ARCHIVE_ND | CVAR_LATCH );
Cvar_CheckRange( r_noborder, "0", "1", CV_INTEGER );
Cvar_SetDescription( r_noborder, "Setting to 1 will remove window borders and titlebar in windowed mode, hold ALT to drag & drop it with opened console." );
Cvar_SetDescription( r_noborder, "Setting to 1 will remove window borders and title bar in windowed mode, hold ALT to drag & drop it with opened console." );

r_mode = Cvar_Get( "r_mode", "-2", CVAR_ARCHIVE | CVAR_LATCH );
Cvar_CheckRange( r_mode, "-2", va( "%i", s_numVidModes-1 ), CV_INTEGER );
Expand Down Expand Up @@ -3863,6 +3863,7 @@ void CL_Init( void ) {
rcon_client_password = Cvar_Get ("rconPassword", "", CVAR_TEMP );
Cvar_SetDescription( rcon_client_password, "Sets a remote console password so clients may change server settings without direct access to the server console." );
cl_activeAction = Cvar_Get( "activeAction", "", CVAR_TEMP );
Cvar_SetDescription( cl_activeAction, "Contents of this variable will be executed upon first frame of play.\nNote: It is cleared every time it is executed." );

cl_autoRecordDemo = Cvar_Get ("cl_autoRecordDemo", "0", CVAR_ARCHIVE);
Cvar_SetDescription( cl_autoRecordDemo, "Auto-record demos when starting or joining a game." );
Expand Down Expand Up @@ -3909,7 +3910,7 @@ void CL_Init( void ) {
Cvar_SetDescription( cl_inGameVideo, "Controls whether in-game video should be drawn." );

cl_serverStatusResendTime = Cvar_Get ("cl_serverStatusResendTime", "750", 0);
Cvar_SetDescription( cl_serverStatusResendTime, "Time between resending server status requests if no response is received (in milli-seconds)." );
Cvar_SetDescription( cl_serverStatusResendTime, "Time between re-sending server status requests if no response is received (in milliseconds)." );

// init cg_autoswitch so the ui will have it correctly even
// if the cgame hasn't been started
Expand All @@ -3923,6 +3924,7 @@ void CL_Init( void ) {
Cvar_SetDescription( cv, "Specify the maximum allowed ping to a server." );

cl_lanForcePackets = Cvar_Get( "cl_lanForcePackets", "1", CVAR_ARCHIVE_ND );
Cvar_SetDescription( cl_lanForcePackets, "Bypass \\cl_maxpackets for LAN games, send packets every frame." );

cl_guidServerUniq = Cvar_Get( "cl_guidServerUniq", "1", CVAR_ARCHIVE_ND );
Cvar_SetDescription( cl_guidServerUniq, "Makes cl_guid unique for each server." );
Expand Down
2 changes: 1 addition & 1 deletion code/client/snd_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@ void S_Init( void )
Cvar_SetDescription( s_muteWhenMinimized, "Mutes all audio while game is minimized." );

cv = Cvar_Get( "s_initsound", "1", 0 );
Cvar_SetDescription( cv, " Whether or not to startup the sound system." );
Cvar_SetDescription( cv, "Whether or not to startup the sound system." );
if ( !cv->integer ) {
Com_Printf( "Sound disabled.\n" );
} else {
Expand Down
2 changes: 1 addition & 1 deletion code/qcommon/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -3667,7 +3667,7 @@ void Com_Init( char *commandLine ) {
Cvar_SetDescription( com_maxfpsUnfocused, "Sets maximum frames per second in unfocused game window." );
com_yieldCPU = Cvar_Get( "com_yieldCPU", "1", CVAR_ARCHIVE_ND );
Cvar_CheckRange( com_yieldCPU, "0", "16", CV_INTEGER );
Cvar_SetDescription( com_yieldCPU, "Attempt to sleep specified amout of time between rendered frames when game is active, this will greatly reduce CPU load. Use 0 only if you're experiencing some lag." );
Cvar_SetDescription( com_yieldCPU, "Attempt to sleep specified amount of time between rendered frames when game is active, this will greatly reduce CPU load. Use 0 only if you're experiencing some lag." );
#endif

#ifdef USE_AFFINITY_MASK
Expand Down
2 changes: 1 addition & 1 deletion code/qcommon/cvar.c
Original file line number Diff line number Diff line change
Expand Up @@ -2079,7 +2079,7 @@ void Cvar_Init (void)
Com_Memset(hashTable, '\0', sizeof(hashTable));

cvar_cheats = Cvar_Get( "sv_cheats", "1", CVAR_ROM | CVAR_SYSTEMINFO );
Cvar_SetDescription( cvar_cheats, "Enable cheating commands (serverside only)." );
Cvar_SetDescription( cvar_cheats, "Enable cheating commands (server side only)." );
cvar_developer = Cvar_Get( "developer", "0", CVAR_TEMP );
Cvar_SetDescription( cvar_developer, "Toggles developer mode. Prints more info to console and provides more commands." );

Expand Down
18 changes: 9 additions & 9 deletions code/renderer/tr_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -1466,7 +1466,7 @@ static void R_Register( void )
r_simpleMipMaps = ri.Cvar_Get( "r_simpleMipMaps", "1", CVAR_ARCHIVE_ND | CVAR_LATCH );
ri.Cvar_SetDescription( r_simpleMipMaps, "Whether or not to use a simple mipmapping algorithm or a more correct one:\n 0: off (proper linear filter)\n 1: on (for slower machines)" );
r_vertexLight = ri.Cvar_Get( "r_vertexLight", "0", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( r_vertexLight, "Turn on vertex lighting on all world surfaces. Disables multi-texture." );
ri.Cvar_SetDescription( r_vertexLight, "Set to 1 to use vertex light instead of lightmaps." );

r_picmip = ri.Cvar_Get( "r_picmip", "0", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_CheckRange( r_picmip, "0", "16", CV_INTEGER );
Expand All @@ -1481,7 +1481,7 @@ static void R_Register( void )
r_roundImagesDown = ri.Cvar_Get ("r_roundImagesDown", "1", CVAR_ARCHIVE_ND | CVAR_LATCH );
ri.Cvar_SetDescription( r_roundImagesDown, "When images are scaled, round images down instead of up." );
r_colorMipLevels = ri.Cvar_Get ("r_colorMipLevels", "0", CVAR_LATCH );
ri.Cvar_SetDescription( r_colorMipLevels, "Debugging tool to artificially color different mipmap levels so that they are more apparent (defaul 0)." );
ri.Cvar_SetDescription( r_colorMipLevels, "Debugging tool to artificially color different mipmap levels so that they are more apparent (default 0)." );
r_detailTextures = ri.Cvar_Get( "r_detailtextures", "1", CVAR_ARCHIVE_ND | CVAR_LATCH );
ri.Cvar_SetDescription( r_detailTextures, "Enables usage of shader stages flagged as detail." );
r_texturebits = ri.Cvar_Get( "r_texturebits", "0", CVAR_ARCHIVE_ND | CVAR_LATCH );
Expand All @@ -1494,7 +1494,7 @@ static void R_Register( void )

r_mapGreyScale = ri.Cvar_Get( "r_mapGreyScale", "0", CVAR_ARCHIVE_ND | CVAR_LATCH );
ri.Cvar_CheckRange( r_mapGreyScale, "-1", "1", CV_FLOAT );
ri.Cvar_SetDescription(r_mapGreyScale, "Desaturate world map textures only, works independently from \\r_greyscale, negative values desaturates lightmaps only.");
ri.Cvar_SetDescription(r_mapGreyScale, "Desaturate world map textures only, works independently from \\r_greyscale, negative values only desaturate lightmaps.");

r_subdivisions = ri.Cvar_Get( "r_subdivisions", "4", CVAR_ARCHIVE_ND | CVAR_LATCH );
ri.Cvar_SetDescription(r_subdivisions, "Distance to subdivide bezier curved surfaces. Higher values mean less subdivision and less geometric complexity.");
Expand Down Expand Up @@ -1558,7 +1558,7 @@ static void R_Register( void )
ri.Cvar_SetDescription( r_ext_multisample, "For anti-aliasing geometry edges, valid values: 0|2|4|6|8. Requires \\r_fbo 1." );
ri.Cvar_SetGroup( r_ext_multisample, CVG_RENDERER );
r_hdr = ri.Cvar_Get( "r_hdr", "0", CVAR_ARCHIVE_ND );
ri.Cvar_SetDescription(r_hdr, "Enables high dynamic range frame buffer texture format. Requires \\r_fbo 1.\n -1: 4-bit, for testing purposes, heavy color banding, might not work on all systems\n 0: 8 bit, default, moderate color banding with multi - stage shaders\n 1: 16 bit, enhanced blending precision, no color banding, might decrease performance on AMD / Intel GPUs\n" );
ri.Cvar_SetDescription(r_hdr, "Enables high dynamic range frame buffer texture format. Requires \\r_fbo 1.\n -1: 4-bit, for testing purposes, heavy color banding, might not work on all systems\n 0: 8 bit, default, moderate color banding with multi-stage shaders\n 1: 16 bit, enhanced blending precision, no color banding, might decrease performance on AMD / Intel GPUs\n" );
ri.Cvar_SetGroup( r_hdr, CVG_RENDERER );
// bloom
r_bloom = ri.Cvar_Get( "r_bloom", "0", CVAR_ARCHIVE_ND );
Expand Down Expand Up @@ -1621,7 +1621,7 @@ static void R_Register( void )

r_greyscale = ri.Cvar_Get( "r_greyscale", "0", CVAR_ARCHIVE_ND );
ri.Cvar_CheckRange( r_greyscale, "-1", "1", CV_FLOAT );
ri.Cvar_SetDescription( r_greyscale, "Desaturates rendered frame, requires \\r_fbo 1." );
ri.Cvar_SetDescription( r_greyscale, "Desaturate rendered frame, requires \\r_fbo 1." );
ri.Cvar_SetGroup( r_greyscale, CVG_RENDERER );

//
Expand All @@ -1639,13 +1639,13 @@ static void R_Register( void )
r_saveFontData = ri.Cvar_Get( "r_saveFontData", "0", 0 );

r_nocurves = ri.Cvar_Get ("r_nocurves", "0", CVAR_CHEAT );
ri.Cvar_SetDescription( r_nocurves, "Disable drawing bezier curves." );
ri.Cvar_SetDescription( r_nocurves, "Set to 1 to disable drawing world bezier curves. Set to 0 to enable." );
r_drawworld = ri.Cvar_Get ("r_drawworld", "1", CVAR_CHEAT );
ri.Cvar_SetDescription( r_drawworld, "Disable drawing world." );
ri.Cvar_SetDescription( r_drawworld, "Set to 0 to disable drawing the world. Set to 1 to enable." );
r_lightmap = ri.Cvar_Get ("r_lightmap", "0", 0 );
ri.Cvar_SetDescription( r_lightmap, "Show only lightmaps on all world surfaces." );
r_portalOnly = ri.Cvar_Get ("r_portalOnly", "0", CVAR_CHEAT );
ri.Cvar_SetDescription( r_portalOnly, "When set to '1' turns off stencil buffering for portals, this allows you to see the entire portal before it's clipped, i.e. more of the room, to get a better feel for who's in there before you jump in." );
ri.Cvar_SetDescription( r_portalOnly, "Set to 1 to turn off stencil buffering for portals." );

r_flareSize = ri.Cvar_Get( "r_flareSize", "40", CVAR_CHEAT );
ri.Cvar_SetDescription( r_flareSize, "Radius of light flares. Requires \\r_flares 1." );
Expand Down Expand Up @@ -1727,7 +1727,7 @@ static void R_Register( void )

r_ext_max_anisotropy = ri.Cvar_Get( "r_ext_max_anisotropy", "8", CVAR_ARCHIVE_ND | CVAR_LATCH );
ri.Cvar_CheckRange( r_ext_max_anisotropy, "1", NULL, CV_INTEGER );
ri.Cvar_SetDescription( r_ext_max_anisotropy, "Sets maximum anistrophic level for your graphics driver. Requires \\r_ext_texture_filter_anisotropic." );
ri.Cvar_SetDescription( r_ext_max_anisotropy, "Sets maximum anisotropic level for your graphics driver. Requires \\r_ext_texture_filter_anisotropic." );

r_stencilbits = ri.Cvar_Get( "r_stencilbits", "8", CVAR_ARCHIVE_ND | CVAR_LATCH );
ri.Cvar_SetDescription( r_stencilbits, "Stencil buffer size, value decreases Z-buffer depth." );
Expand Down
12 changes: 6 additions & 6 deletions code/renderer2/tr_init.c
Original file line number Diff line number Diff line change
Expand Up @@ -1122,15 +1122,15 @@ static void R_Register( void )
r_ext_texture_filter_anisotropic = ri.Cvar_Get( "r_ext_texture_filter_anisotropic", "1", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( r_ext_texture_filter_anisotropic, "Allow anisotropic filtering." );
r_ext_max_anisotropy = ri.Cvar_Get( "r_ext_max_anisotropy", "8", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( r_ext_max_anisotropy, "Sets maximum anistrophic level for your graphics driver. Requires \\r_ext_texture_filter_anisotropic." );
ri.Cvar_SetDescription( r_ext_max_anisotropy, "Sets maximum anisotropic level for your graphics driver. Requires \\r_ext_texture_filter_anisotropic." );

r_picmip = ri.Cvar_Get ("r_picmip", "0", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_CheckRange( r_picmip, "0", "16", CV_INTEGER );
ri.Cvar_SetDescription( r_picmip, "Set texture quality, lower is better." );
r_roundImagesDown = ri.Cvar_Get ("r_roundImagesDown", "1", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( r_roundImagesDown, "When images are scaled, round images down instead of up." );
r_colorMipLevels = ri.Cvar_Get ("r_colorMipLevels", "0", CVAR_LATCH );
ri.Cvar_SetDescription( r_colorMipLevels, "Debugging tool to artificially color different mipmap levels so that they are more apparent (defaul 0)." );
ri.Cvar_SetDescription( r_colorMipLevels, "Debugging tool to artificially color different mipmap levels so that they are more apparent (default 0)." );
r_detailTextures = ri.Cvar_Get( "r_detailtextures", "1", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( r_detailTextures, "Enables usage of shader stages flagged as detail." );
r_texturebits = ri.Cvar_Get( "r_texturebits", "0", CVAR_ARCHIVE | CVAR_LATCH );
Expand All @@ -1147,7 +1147,7 @@ static void R_Register( void )
r_simpleMipMaps = ri.Cvar_Get( "r_simpleMipMaps", "1", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( r_simpleMipMaps, "Whether or not to use a simple mipmapping algorithm or a more correct one:\n 0: off (proper linear filter)\n 1: on (for slower machines)" );
r_vertexLight = ri.Cvar_Get( "r_vertexLight", "0", CVAR_ARCHIVE | CVAR_LATCH );
ri.Cvar_SetDescription( r_vertexLight, "Turn on vertex lighting on all world surfaces. Disables multi-texture." );
ri.Cvar_SetDescription( r_vertexLight, "Set to 1 to use vertex light instead of lightmaps." );
r_subdivisions = ri.Cvar_Get ("r_subdivisions", "4", CVAR_ARCHIVE | CVAR_LATCH);
ri.Cvar_SetDescription(r_subdivisions, "Distance to subdivide bezier curved surfaces. Higher values mean less subdivision and less geometric complexity.");
r_greyscale = ri.Cvar_Get("r_greyscale", "0", CVAR_ARCHIVE | CVAR_LATCH);
Expand Down Expand Up @@ -1313,13 +1313,13 @@ static void R_Register( void )
r_saveFontData = ri.Cvar_Get( "r_saveFontData", "0", 0 );

r_nocurves = ri.Cvar_Get ("r_nocurves", "0", CVAR_CHEAT );
ri.Cvar_SetDescription( r_nocurves, "Disable drawing bezier curves." );
ri.Cvar_SetDescription( r_nocurves, "Set to 1 to disable drawing world bezier curves. Set to 0 to enable." );
r_drawworld = ri.Cvar_Get ("r_drawworld", "1", CVAR_CHEAT );
ri.Cvar_SetDescription( r_drawworld, "Disable drawing world." );
ri.Cvar_SetDescription( r_drawworld, "Set to 0 to disable drawing the world. Set to 1 to enable." );
r_lightmap = ri.Cvar_Get ("r_lightmap", "0", 0 );
ri.Cvar_SetDescription( r_lightmap, "Show only lightmaps on all world surfaces." );
r_portalOnly = ri.Cvar_Get ("r_portalOnly", "0", CVAR_CHEAT );
ri.Cvar_SetDescription( r_portalOnly, "When set to '1' turns off stencil buffering for portals, this allows you to see the entire portal before it's clipped, i.e. more of the room, to get a better feel for who's in there before you jump in." );
ri.Cvar_SetDescription( r_portalOnly, "Set to 1 to turn off stencil buffering for portals." );

r_flareSize = ri.Cvar_Get ("r_flareSize", "40", CVAR_CHEAT);
ri.Cvar_SetDescription( r_flareSize, "Radius of light flares. Requires \\r_flares 1." );
Expand Down
Loading

0 comments on commit fb9f727

Please sign in to comment.