Welcome, Unregistered.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Reply
Old 18-Jul-2005, 09:21   #1
micky
Member
 
Join Date: Nov 2004
Location: at work
Posts: 91
Default Half life 2 tweaks

Apologies if this has been done before--if so can somebody post the link, I did try searching first but failed misserably.

Anyone know of some good, usefull tweaks that may help frame rates etc.

I know there was a guide on Tweakguide.com but as I'm at work, filters block me from seeing that site for some reason. Any chance of somebody going on there and copy and pasting etc etc on to here?

Much appreciated.
__________________
One day I will wake up and my PC will fith the requirements-untill that day....
micky is offline   Reply With Quote
Old 18-Jul-2005, 09:51   #2
Diplo
Senior Member
 
Join Date: Apr 2004
Location: UK
Posts: 1,474
Default

You can change more than just the handful of settings available under the in-game options in Half Life 2. The Source Engine by Valve is highly customizable: there are over 1800 Command Variables (cvars) which can be used to alter everything from the way the game allocates memory to providing additional game information to recording demos and running custom benchmarks. This gives us an excellent opportunity to tweak Half Life 2 to its fullest potential. This section provides details of how to tweak Half Life 2 correctly using the command variables, and the next few pages provide a list of the more useful command variables and what they do.

There are four main ways in which you can implement command variables in Half Life 2: In the game's Console; through Config (.cfg) files; in the Steam Launch Options box; or in your game icon's Target box. These various methods usually result in the same outcome for each command, however they provide flexibility in the ways in which you can test, add, edit and remove cvars for the game. If this section looks familiar to you, that's because you may have seen something just like it in my Doom 3 Tweak Guide. There are a lot of similarities between tweaking Doom 3 and Half Life 2. This is no coincidence - although Half Life 2 has a completely different engine from Doom 3, it is the sign of an advanced and highly modifiable engine that you can access a large range of command variables in a variety of ways.

The way to access and use each method is covered below. Make sure you read through this information carefully otherwise the tweaks in the Advanced Tweaking section will not function correctly if at all:

Half Life 2 Console

To enable the Half Life 2 console, you will first need to go into the in-game options, and under the Keyboard tab, click the Advanced button and tick the 'Enable developer mode (console)' option (see the Keyboard option under the In-Game Settings section above). Now you can open and close the console at any time by pressing the '~' key (the key under ESC). The Half Life 2 Console is a window into the game's Source engine. It allows you to see a range of information about the game and you can use it to change the way the engine behaves.

Half Life 2 Config Files

Half Life 2 holds many of the settings you select in the in-game options - along with a range of other custom variables - in a file called config.cfg, which can be found in your \Program Files\Valve\Steam\SteamApps\[username]\half-life 2\hl2\cfg\ directory. This file can be opened and edited using any text editor, such as the Windows Wordpad. The config.cfg file is very important, so you should first create a backup of it before you edit it in any way.

While you can add, edit and remove commands directly in config.cfg, it is recommended that instead you create an entirely new file for adding custom commands. To do this, in the same directory as config.cfg, right-click in an empty area and select New>Text Document. Rename this new text document to autoexec.cfg (not autoexec.cfg.txt), and you can now insert all your custom commands into this config file. By default the Half Life 2 engine looks for autoexec.cfg at startup, and if it finds it, it will automatically load and execute all the valid commands in it along with those in config.cfg while starting up Half Life 2.

Additionally, you can create any other .cfg files you need, name them as you wish (as long as they end in .cfg), such as mytweaks.cfg, place them in the same directory as config.cfg, and then run the commands they contain from the Half Life 2 console (or from autoexec.cfg) by using the "exec" command. For example typing the command: exec mytweaks.cfg in the console will execute the command variables contained in the mytweaks.cfg file. They will not run automatically at startup however - only autoexec.cfg and config.cfg can do that.

Steam Launch Options

You can add various command variables into the launch options for Half Life 2, ensuring that they are activated each time Half Life 2 is launched. To do this, right-click on your Steam icon and select 'Play Games'. Right-click on the Half Life 2 entry under 'My Games' and select Properties. In the Properties box which opens, click the 'Launch Options' button. You can now enter command variables in this box and they will be executed whenever you start Half Life 2 from Steam or your desktop icon.

Half Life 2 Icon Properties

Similar to the way you can add command variables to the Steam Launch Options, you can also add them to the Half Life 2 startup by editing the desktop icon used to launch the game. If you don't have a desktop icon for Half Life 2, go to Steam>Play Games and right-click on Half Life 2 under 'My Games', then select 'Create desktop shortcut'. Right-click on the desktop icon for Half Life 2 and select Properties. Under the properties, you can enter command variables in the Target box. For example:

"C:\Program Files\Valve\Steam\Steam.exe" -applaunch 220 -heapsize 512000 +map_background none

The above command line will launch Half Life 2 (-applaunch 220) with a memory allocation of around 500MB (-heapsize 512000), and Half Life 2 will start without a 3D background on the main menu (+map_background none). You can add as many variables as will fit in the Target box, simply make sure you put a single space between each command.

Note that unlike entering the commands in the Steam Launch Options box, if you enter them in the desktop icon's Target box they will not apply when you run Half Life 2 from Steam, whereas the Steam Launch Option variables will apply to Half Life 2 even when you launch it from a desktop icon.

Command Line Commands

There are some commands which can only be used in the Target box of your HL2 icon, or in the 'Launch Options' box of Steam. They cannot be used in the game's console or in your autoexec.cfg file. These are referred to as 'Command Line' commands, and the most useful of these commands are:

-heapsize [Kilobytes]: This command tells Half Life 2 to allocate more RAM to the game system heap, where it can be accessed by the game to improve performance by storing more game information in RAM and hence reducing loading pauses. The default heapsize is 64MB, however you can safely allocate around 128MB (i.e. -heapsize 128000) for most systems. You can use higher values if you have more RAM, but I don't recommend exceeding half your physical RAM (e.g. for 1GB RAM, set heapsize of 512000).

-console: Speeds up the loading of Half Life 2 at startup by not loading up the background 3D graphics on the main menu and instead loading up a blurry background picture and the Half Life 2 console open. Note you can close this console using the '~' key.

-width [pixels] -height [pixels]: Using these two commands you can set a custom resolution in Pixel Width x Pixel Height (e.g. -width 640 –height 480 starts HL2 with 640x480 resolution). Make sure you choose a resolution supported by your monitor and with the correct ratio of width to height (usually 4:3).

-dxlevel [version]: Using this command allows you to force Half Life into only using the specified DirectX version for shaders. For example, use -dxlevel 70 to force Hardware DirectX7.0 level support for shaders. This means a reduction in image quality but an increase in performance. Other values include -dxlevel 80 -dxlevel 81 and -dxlevel90. Note that this only works if you choose a DirectX version which is lower than the current one supported by your graphics card. See the Hardware DirectX Version option under the In-Game settings for more details.

-refresh [Hz]: Specifies the refresh rate the game will use upon loading. This is normally not required as your system should already use the optimal refresh rate at your chosen resolution. However if this is not the case you can force it to a specific refresh rate (e.g. -refresh 85). Make absolutely certain that the rate you are trying to apply does not exceed your monitor's capabilities otherwise you may damage your monitor - especially if you change resolutions and forget to change this option.

-novid: Prevents the Valve startup animation from playing when loading up the game, speeding up startup time.

Notice that all of the command line commands above have a '-' in front of them. This only applies to these specific few command line commands. In general if you want to run any of the command variables listed on the next few pages in your icon's Target box, or in Launch Options, you must add a '+' sign in front of them (instead of a '-') before inserting them. For example, if you want to use the "exec" command to execute a config file at startup, you will actually have to put the command into the Target/Launch Options box in the following way:

-dxlevel 70 +exec mytweaks.cfg

In the example above, when you start Half Life 2 the DirectX Hardware support is reduced to DirectX7.0, and the contents of the file 'mytweaks.cfg' will be executed.

The simple rule for using commands in the command line is that aside from the few command line-specific commands listed further above, all other command variables, such as those listed on the following pages, require a '+' sign in front of them if used in the Target box or Steam's Launch Options. Note that you must also place a single space between each separate command, and no " " (quote) marks are required around the commands.

Using Command Variable Tweaks – The Best Method

In general, the majority of the command variables you will be using will be inserted into a config file after being tested in the console. To use a command variable in the game's console, open the console and simply type the name of the command variable. This will show you the current setting for the variable as well as its default setting. If you want to change a command variable's value, simply type the name of the variable, then a space, then the value you want to assign it. Some command variables don't require a value, and can be run simply by entering their name and pressing return. You can use the cvarlist, find, help and revert commands to search for and learn more about specific commands (See Common Commands under the Command Variables list on the next page for details of these commands).

Once you've tested the effects of specific variables in the console, if you only want to change a few you can insert them directly into your game icon's Target box or Steam Launch Options box as detailed further above. However in most cases it is better to create an autoexec.cfg file and insert all your custom command variables one under the other in that file. Note that when using command variables in autoexec.cfg, you don't need to use any '-', '+' or " " signs around the command. Simply enter the command name, followed by a space, and the value you want to assign it – just as if you were entering it into the console. However if you decide to edit or insert any settings into config.cfg, you will need to use "" marks around the value assigned to any command variable. In general you should avoid editing config.cfg and use autoexec.cfg for your tweaking.

A sample autoexec.cfg file content is provided below as an example of what it should look like:

bindtoggle z cl_showfps 2

mat_dxlevel 81

sv_autosave 0

jpeg_quality 60

snd_mixahead 0.7

cl_forcepreload 1

sv_forcepreload 1

cl_smooth 0

cl_ragdoll_collide 1

r_fastzreject 1

muzzleflash_light 0

r_decals 1000

r_maxmodeldecal 25

dsp_enhance_stereo 1

mat_bloom 0

The settings above suit a medium level system without lowering image quality or realism noticeably, however do not just cut and paste this file into your own autoexec.cfg without referring to what each of these commands does, as it may not suit some people and/or may conflict with your system hardware. This is not the most optimal autoexec.cfg file to use for everyone. In fact the major reason why I don't provide generic autoexec.cfg files in my guides is that I have no way of knowing your image quality and performance preferences, not to mention precisely which hardware is on each system. There are very few commands which give extra performance without any visual quality impact. I strongly urge you to take the time to test and compile your own list of command variables, otherwise you may run into a bunch of troubles with incorrect/incompatible settings.

Troubleshooting Command Variable Issues

If you do run into any problems with cvar changes you have made, you should note that many changes you make in the console or in your autoexec.cfg file (or any other config file) may also be recorded in the config.cfg file by the game engine and hence become "permanent", even if you delete or alter other config files. You can either search through config.cfg and alter or delete the cvar there, or you can restore your backed-up version of config.cfg to undo all your changes.

If that doesn't work, you may have to go back into the console and type the command variable with the correct value to restore it back. For example, the mat_dxlevel command will change the Hardware DirectX level "permanently" until you give it a new value, so if in doubt go into the console and change the variable back there.

If on the other hand you don't think a command you've included in a config file is being implemented at all, firstly read through the above instructions thoroughly. If the instructions are followed in detail, command variables will work, simply because I have tested them and I know these methods are sound. However on the off chance that it still doesn't resolve your dilemma, enter the command in the console with your chosen value, then just type the cvar name again (with no value). It should show the new value against the cvar - if not, then the command is either not being used properly, the value you want to apply is invalid, or you may not be able to change it due to your hardware capabilities. Also note that cheat commands (denoted by (cheat) next to them on the list in the following pages) can only be enabled if the sv_cheats 1 command is first used.

In the case of the commands which can only be used in an icon's Target box, or from Steam's 'Launch Options', such as heapsize, you can open the console immediately after HL2 has started up and you should see some indications of their implementation. With Heapsize for example, once you open the console after Half Life 2 has just loaded you will see the amount of memory allocated to the game at the top of the console text.

That covers how to apply tweaks in Half Life 2. The next few pages go into the actual command variables which can be used to tweak Half Life 2.
__________________
"We are all atheists about most of the gods that humanity has ever believed in. Some of us just go one god further." - Richard Dawkins
Diplo is offline   Reply With Quote
Old 18-Jul-2005, 09:52   #3
Diplo
Senior Member
 
Join Date: Apr 2004
Location: UK
Posts: 1,474
Default

Common Commands

cl_showfps [0,1,2] - Draws a Frames Per Second (FPS) counter at the top of the screen. 0=off, 1=FPS, 2=Smoothed FPS. In general the smoothed fps counter is best for viewing framerates

cvarlist [string] - If entered by itself this command generates a list of all the command variables (cvars) in HL2. If one or more characters are also entered, cvarlist will list all commands starting with those letter(s).


help [cvar] - Provides any available help text for the specified cvar.


find [string] - Finds cvars with the specified string in their name or help text.


revert [cvar] - Reverts cvars to their default value.


differences - Shows all the cvars which are not at their default values, showing which have been changed.


exec [configfilename] - Executes all valid commands within the specified configuration file. The file must be a plain text file with the name filename.cfg and reside in the same directory as config.cfg.


clear - Clears all text from the console.


echo [string] - Outputs the specified string to the console (e.g. echo banana prints the text banana in the console).


version - Shows the current version of the game. The version number of the HL2 executable is effectively the version number for the entire game. Also shows the current build of the Source engine being used.


pause - Pauses the game.


unpause - Unpauses the game.


autosave - Saves the current game to the autosave slot. Will not work if autosave is completely disabled as per the instructions in the Conclusion section.


sv_autosave [0,1] - If set to 1, allows HL2 to automatically save your progress at level transitions. If set to 0, game will not save whenever a new level starts, but may still save periodically at certain trigger points within a level. To disable all autosaving see the Conclusion section of this guide.


save [savename] - Saves the current game under the savename specified.


load [savename] - Loads a game from the specified savename file.


reload - Reloads the most recent saved game.


restart - Restarts the game on the same level.


kill - Kills Gordon.


flush - Flushes the cache memory. Can resolve graphical anomalies such as texture glitches.


map_background [mapname] - Runs a map as the background to the main menu. To find the mapnames, use the maps command (see below).


maps [string] - Lists all maps starting with the provided string. Use maps * to list all mapnames.


screenshot - Takes a screenshot.


jpeg [filename, quality] - Takes a screenshot as a .jpg with the specified filename using the quality % specified (e.g. jpeg snapshot 50 saves a screenshot as snapshot.jpg with 50% quality). If no quality is specified the default as set by jpeg_quality will be used (see below).


jpeg_quality [percentage] - Specifies the default quality percentage for screenshots taken with the jpeg command (see above).


path - Shows the engine filesystem paths.


exit - Exits Half Life 2 and returns to the Desktop.


quit - Exits Half Life 2 and returns to the Desktop.



Binding Commands


bind [key, command] - Binds the stated command to the specified key (e.g. bind Z console binds the Z key to opening the command console).


bindtoggle [key, command] - Same as the bind command, except the assigned key can be used to both turn the command on and off (e.g. bindtoggle F cl_showfps 2 means the F key will toggle the FPS counter on or off).


unbind [key] - Removes any bindings from the specified key.


unbindall - Removes bindings from all keys.


alias [aliasname, command] - Gives a command a short name (e.g. alias taunt echo I am your new King! changes 'taunt' into a command which spits out "I am your new King" when used). Use alias as a shortcut for long or complex command strings.


key_findbinding [command] - Find the key bound to the specified command.


key_listboundkeys - Lists all the keys which currently have a binding.



Performance Commands


mat_forcemanagedtextureintohardware [0,1] - If set to 1, attempts to force texture information into your Video RAM at the start of a level, alleviating any stuttering in the game. Note, this setting was introduced with the "stutter fix" patch (See Patches Mods & Steam section for details). Also note that from feedback and in my experience this setting can reduce FPS by up to 50%. Setting this variable to 0 may improve performance on some machines.


cl_forcepreload [0,1] - If set to 1 forces all information to preload, reducing loading pauses and stuttering by not loading information on the fly.


sv_forcepreload [0,1] - If set to 1, forces server-side preloading, once again reducing loading pauses.


cl_ragdoll_collide [0,1] - If set to 1, prevents characters from merging into each other due to ragdoll effects, thereby improving realism with no real performance hit.


mat_compressedtextures [0,1] - If set to 1, uses compressed textures for optimal performance. For those with graphics cards which have higher amounts of Video RAM (e.g. 256MB) setting this to 0 will improve texture appearance at the cost of some performance.


fps_max [fps] - Limits the maximum possible framerate to the FPS specified. Has no impact on framerate performance (other than capping it). This is best set to your monitor's refresh rate for smoother FPS, due to less volatile fluctuations (e.g. fps_max 85). Setting it higher does not increase overall FPS.


mem_force_flush [0,1] - If set to 1 forces the cache to be flushed on every allocation, which is not necessarily optimal but can reduce memory-related errors.


r_fastzreject [-1,0,1] - If set to 1 activates a fast z-setting algorithm which takes advantage of hardware fast z reject for improved performance. If set to -1 detects your default hardware setting for this option. Initially this should be set to 1, and if you see any problems then set to -1.


cl_smooth [0,1] - If set to 1 attempts to smooth the view after prediction errors, however this can increase stuttering and so should usually be set to 0.


cl_smoothtime [seconds] - Time over which to smooth the view after prediction errors. If cl_smooth is enabled, experiment with values to see which gives the best results.


sv_autoladderdismount [0,1] - If set to 1, the player automatically dismounts from ladders when the end is reach. If disabled, the player must press the USE key to mount/dismount ladders and hence cannot accidentally jump/walk off a ladder. Set to taste as there is no performance impact.


sv_footsteps [0,1] - If set to 1, player footsteps can be heard, if set to 0 no footsteps are emitted from the player. Set to taste, has no performance impact, but can affect realism.


violence_ablood [0,1] - If set to 1 shows alien blood when they are hit. Disabling this can improve performance but reduce realism.


violence_agibs [0,1] - If set to 1 shows alien gore when they are hit. Disabling this can improve performance but reduce realism.


violence_hblood [0,1] - If set to 1 shows human blood when they are hit. Disabling this can improve performance but reduce realism.


violence_hgibs [0,1] - If set to 1 shows human gore when they are hit. Disabling this can improve performance but reduce realism.


[Graphics]


cl_detaildist [range] - Determines the range at which detail props are shown (e.g. grass). The higher the value, the lower your performance as more add-on details are shown. Reducing this setting can increase performance, and increasing this setting will improve image quality.


cl_detailfade [range] - Determines the range at which detail props fade into view. Increasing this value can raise performance.


cl_maxrenderable_dist [distance] - Specifies the maximum distance from the camera at which things will be rendered. The smaller the number, the less will be rendered, improving performance (cheat).


cl_ejectbrass [0,1] - If set to 1, weapons eject shells as they fire. If set to 0 they don't, which can improve performance especially during heavy combat.


cl_show_bloodspray [0,1] - If set to 1, blood sprays are emitted from bullet impacts on characters. If set to 0, no blood sprays are shown, however blood marks (decals) can still appear. Disabling this can improve performance, but reduces realism.


cl_show_splashes [0,1] - If set to 1, splashes in water are shown, if set to 0 they are disabled. Can improve performance if disabled at the cost of realism.


crosshair [0,1] - If set to 1, enables the crosshair on the screen, if set to 0 disables it. The performance difference is negligible, so set to taste.


lod_Enable [0,1] - If set to 1, allows the level of detail (lod) of objects to be gradually reduced the further they are from the player. This should be set to 1 for optimal performance, or 0 for maximum image quality.


lod_TransitionDist [range] - The distance at which the lod is reduced on objects. The higher this range, the lower your performance but the better distant objects will appear.


mat_bloom [0,1] - If set to 1, a 'bloom' lighting effect is visible on objects, softening their appearance. If set to 0 this effect is removed, but performance is increased without a noticeable drop in image quality.


mat_bumpmap [0,1] - If set to 1, enables bump mapping which makes flat 2D textures appear three dimensional. If disabled, textures will be loaded without bumpmapping and will appear far less realistic, however performance will be improved.


mat_clipz [0,1] - If set to 1, uses an optimization technique to reduce what is drawn on screen for a performance improvement. Note that some Nvidia FX card owners need to set mat_clipz 0 to fix rendering problems.


mat_diffuse [0,1] - If set to 1, uses diffuse lighting on materials. If set to 0 such lighting is removed and while performance is improved the screen is almost completely black from lack of this diffuse (ambient) lighting and hence is not recommended.


mat_drawwater [0,1] - If set to 1, all water is rendered. Setting this to 0 can remove water for a performance boost at the cost of realism (cheat).


mat_dxlevel [dxversion] - Determines the shader version for special effects applied to materials. Options include 70, 80, 81 and 90 (e.g. mat_dxlevel 81). This is similar to the -dxlevel switch in the Advanced Tweaking section on page 7. Using shader versions lower than the highest level supported by your card will improve performance at the cost of varying degrees of image quality loss (depending on the shader version used).


mat_fastnobump [0,1] - If set to 1, floor textures have all bump mapping removed and will appear flat and smooth. This can improve performance without affecting all bump mapping in the game, but will make floors appear unrealistic.


mat_filterlightmaps [0,1] - If set to 1, static lightmaps are rendered correctly. If set to 0, all areas of pre-rendered lighting will be blocky and unrealistic, but performance will be improved slightly at the cost of realism.


mat_filtertextures [0,1] - If set to 1, textures are rendered smoothly. If set to 0, textures will be blocky and unrealistic (similar to the original Doom!) but performance will be improved.


mat_fullbright [0,1] - If set to 1, lights every texture will up brightly lit up (cheat).


mat_hsv [0,1] - If set to 1, converts everything to black and white.


mat_mipmaptextures [0,1] - If set to 0 disables mipmap textures, which harshens textures greatly but can improve performance.


mat_showlowresimage [0,1] - If set to 1, loads extremely low resolution blocky textures in place of the normal ones for a significant performance boost at the cost of a great deal of realism.


mat_softwarelighting [0,1] - If set to 1, uses only software-supported lighting. Image quality is not greatly affected, but this may increase or decrease your performance depending on whether your CPU is far more powerful than your graphics card.


mat_specular [0,1] - If set to 1, uses specular lighting. If set to 0 materials will not have specular lighting applied to them for a performance boost but a slight drop in image quality.


muzzleflash_light [0,1] - If set to 1, weapons firing will emit a light along with the muzzle flash. If set to 0, a muzzle flash is still visible but no lighting is cast from it. Performance will improve in combat scenes with no noticeable drop in realism.


r_decal_cullsize [pixels] - Decals (marks from weapons etc.) higher than the specified size in pixels will be removed straight away. Raising this value can improve performance during heavy gunfire for example, at the cost of some realism depending on how high this value is raised.


r_decals [number] - Specifies the maximum number of decals possible at any one time. The higher this number, the greater the potential for getting slowdowns during large firefights as large numbers of decals are generated. Reducing this setting can improve performance in such situations.


r_drawdecals [0,1] - If set to 1, decals are drawn. If set to 0, no decals are drawn at all improving performance but greatly reducing realism (cheat).


r_drawflecks [0,1] - If set to 1, small chunks of rubble and dirt will be thrown up around bullet impact points. If set to 0, these 'flecks' will be disabled, reducing realism but improving performance.


r_drawmodeldecals [0,1] - If set to 1, decals can be drawn on models, which are pretty much everything excluding walls and floors. If set to 0 these decals will be disabled, improving performance during weapons fire for example, but reducing realism.


r_maxmodeldecal [number] - If r_drawmodeldecals is enabled, this number determines the maximum number of decals which can be drawn on a model. The higher the setting the greater the performance impact when firing at models.


r_drawparticles [0,1] - If disabled, particle effects - which includes smoke and explosions - will not be drawn. This can greatly improve performance around such effects at the cost of a great deal of realism.


r_DrawRain [0,1] - If set to 1, rain effects will be rendered, however if disabled no rain will be drawn. This improves performance in levels where there is visible rain, however realism is greatly reduced (cheat).


r_drawropes [0,1] - If set to 1, all ropes and rope-like objects (e.g. powerlines) will be drawn as normal, however disabling this setting will remove such objects, perhaps improving performance in places where they exist but reducing realism (cheat).


r_drawskybox [0,1] - If set to 0, the sky textures will be completely removed, improving performance but resulting in visual anomalies in the sky and a large reduction in realism.


r_drawtranslucentrenderables [0,1] - If set to 1, all objects which are translucent, such as the Combine energy shields, will be drawn. If set to 0, these objects will not be drawn, improving performance around them at the cost of realism (cheat).


r_dynamic [0,1] - If set to 1, enables dynamic lighting. If set to 0, disables dynamic lighting which can boost performance without a dramatic impact on realism.


r_farz [-1,0,1] - Controls the far clippling plane, which determines what is not rendered when it is determined not to be visible to the character. A value of -1 is normal, higher values can result in normally visible objects suddenly disappearing from view (cheat).


r_lod [-8 to 8] - Determines the rate at which level of detail (lod) is stripped from objects as they recede away from the player. The lower the value, the more detail remains visible on objects as they progress into the distance, reducing performance but increasing image quality.


r_maxdlights [number] - Determines the maximum number of dynamic lights visible on the screen. The larger this maximum, the more chance of slowdowns during scenes with multiple dynamic light sources. Reducing this value can improve performance in such situations.


r_modellodscale [0-1] - This setting is not the same as the Model Detail setting under the in-game options. You can use this value to fine tune model details, with values below 1 reducing the model details, improving performance at the cost of realism.


r_occlusion [0,1] - If set to 0, disables the occlusion system in the game, which can increase performance at the expense of image quality.


r_WaterDrawReflection [0,1] - If set to 0, disables all reflections on top of water. This will boost performance at the cost of realism however you may experience graphical anomalies on the water.


r_WaterDrawRefraction [0,1] - If set to 0, disables all refraction - that is images which appear distorted under the water. This will boost performance at the cost of realism, however you may experience some graphical anomalies on the water.


sv_robust_explosions [0,1] - If set to 0, explosions will be less spectacular, but this may improve performance around explosions without a significant drop in realism.


fog_enable [0,1] - If set to 0, will disable fog which can improve or reduce performance depending on whether your graphics card has issues with rendering fog.


fog_enable_water_fog [0,1] - If set to 0, removes all underwater fogging which can result in a performance boost but unrealistic water appearance.


r_waterforceexpensive [0,1] - If set to 1, the highest quality water will be used. If set to 0, performance may improve without a noticeable reduction in water quality.


[Sound]


dsp_off [0,1] - If set to 1, disables audio DSP (Digital Signal Processing) in Half Life 2. This may improve performance (cheat), but will reduce the richness of audio effects.


dsp_enhance_stereo [0,1] - If set to 1 enhances the stereo effect, making sound richer and more atmospheric for a slight performance hit.


dsp_slow_cpu [0,1] - If set to 1, reduces the quality of dsp sound effects, improving performance on systems with slower CPUs.


dsp_volume [volume] - Determines the volume of the background dsp effects. If the volume is increased, the impact of dsp enhancement will be exaggerated with no performance impact.


snd_profile [0,1] - If set to 1, shows dsp usage stats in the console.


snd_mixahead [value] - Set between 0 and 1, the higher the value the less stuttering and more synchronized sound will be, but performance may be reduced. A value of 0.5 to 0.7 will help reduce stuttering in the game. If you experience no stuttering, lower this value to gain some performance.


snd_async_fullyasync [0,1] - If set to 1, sound may go out of synch with actions but you will experience reduced loading pauses and stuttering. Usually best left disabled.
__________________
"We are all atheists about most of the gods that humanity has ever believed in. Some of us just go one god further." - Richard Dawkins
Diplo is offline   Reply With Quote
Old 18-Jul-2005, 09:52   #4
Diplo
Senior Member
 
Join Date: Apr 2004
Location: UK
Posts: 1,474
Default

Demo Commands


record [demoname] - Starts recording a demo of the current gameplay under the specified filename. The demo will be saved as demoname.dem in the \Program Files\Valve\Steam\SteamApps\[username]\half-life 2\hl2\ directory along with all its associated files.


stop - Stops recording the current demo.


demoui - Opens a small demo user interface which looks like a media player, but makes the opening and playing of demos much easier, including the capability to FF, REW and skip to specific points in the demo.


playdemo [demoname] - Plays back a pre-recorded demo of name demoname.dem.


stopdemo - Stops playback of the currently playing demo.


demopause - Pauses playback of the currently playing demo.


demoresume - Resumes playback of the currently paused demo.


listdemo [demoname] - Provides details of the specified demo file.


demo_recordcommands [0,1] - If set to 1, records any commands typed at the console into demo files.


startmovie - Starts recording movie frames, stored in the \Program Files\Valve\Steam\SteamApps\[username]\half-life 2\hl2\ directory as .tga files.


endmovie - Stops recording movie frames.


Benchmarking Commands


timedemo [demoname] - Plays the specified demo and reports performance information upon completion, including frames played, time taken, average FPS and FPS variability. Also records the information in a file called sourcebench.csv in your \Program Files\Valve\Steam\SteamApps\[username]\half-life 2\hl2\ directory.


timedemoquit [demoname] - Plays the specified demo as per the timedemo command and then exits the game to desktop.


bench_start [filename] - Starts benchmarking your current gameplay and writes information to the specified file in .csv format.


bench_end - Ends any benchmarking.


bench_showstatsdialog - Shows a dialog box displaying the most recent benchmarking results.


bench_upload - Uploads the most recent benchmarking stats to the Valve servers.


benchframe [framenumber] - Takes a snapshot of the specified frame of a timedemo.


perfvisualbenchmark - Runs a series of benchmarks on the current scene.


perfvisualbenchmark_abort - Stops the benchmarking and prints the results for various aspects of the rendering system in average FPS in the console.



View Commands


firstperson - Switches to firstperson (from Gordon's eyes) point of view, which is the default for HL2.


thirdperson - Switches to thirdperson (behind Gordon) point of view. Note in thirdperson view Gordon appears as an incomplete grey model.


centerview - Centers the character's view on the middle of the screen (only when bound to a key).


force_centerview - Centers the character's view on the middle of the screen whenever used.


fov [angle] - Specifies the character's Field of View (fov), i.e. the total angle which can be viewed at once. Default is 75, higher values create more of a "fish-eyed" view, lower angles create a zoomed view.


default_fov [angle] - Determines the default Field of View in HL2. Default is 75 (cheat).


gameui_hide - Hides any visible portions of the game user interface, e.g. the console. Primarily used prior to taking a screenshot.


hidehud [0,1] - If set to 1, hides the Heads Up Display (HUD) from view (cheat).


cl_drawhud [0,1] - If set to 1, the HUD is drawn on screen, if set to 0 the HUD is not rendered, which can improve performance (cheat).



Information & Diagnostic Commands


bug - Opens a bug reporting user interface which makes the reporting of game bugs to Valve simple, such as being able to take a screenshot and attach it to the generated report automatically.


cache_print - Shows the amount of memory used by cached information, and the total cache capacity currently used by the game.


cl_precacheinfo - Shows the files which have been precached.


cl_showpost [0,1] - Displays the player's position on the current map in X, Y and Z co-ordinates the top right corner if set to 1.


developer [0,1,2] - If set to 1 shows Developer messages in the top left corner, if set to 2 shows more detailed information.


fs_printopenfiles - Shows all files currently open.


listmodels - Lists all models currently loaded.


mat_info - Shows material system information.


mat_reloadmaterial - Reloads all materials which can take quite a while but may resolve any temporary graphical glitches.


mat_wireframe [0,1] - Displays materials in wireframe form (cheat).


mem_dump - Writes memory statistics to the file memstats.txt.


perfui - Opens a user interface which allows easy access to performance tools.


r_drawlightinfo [0,1] - Shows the source of all lights in the current scene and their associated information (cheat).


showbudget_texture [0,1] - If set to 1 displays a detailed control panel which graphs the memory usage for various types of textures.


soundinfo - Shows information about the current sound output device.


soundlist - Lists all known sounds.


snd_restart - Restarts the sound system which can take a while but may clear any temporary audio glitches.


snd_memasync - Shows sounds currently loaded and the memory used by each.


snd_show [0,1] - If set to 1 displays information about sounds loaded (cheat).


stopsound - Stops all sound effects currently playing.


stopsoundscape - Stops all soundscapes currently playing.


surfaceprop - Shows information about the surface currently under the cursor.



Cheat Commands

[The sv_cheats 1 command must be used before cheat commands can work]


sv_cheats [0,1] - Toggle. Enables the use of cheat commands in single player or on a multiplayer server if set to 1


god - Toggle. The player becomes invulnerable.


noclip - Toggle. The player can fly and move through solid objects.


notarget - Toggle. The player becomes invisible to NPCs (Non-Player Characters).


ai_disable - Disables all Artificial Intelligence (AI) for NPCs and puts them into their idle animations. Can be used to test the performance hit of AI, or to freeze NPCs.


impulse [code] - Generates objects, e.g. Impulse 101 gives the player all weapons.


buddha - Toggle. Player can take damage but won't die.


map [mapname] - Starts playing on the specified map (see maps command for mapnames).


sv_unlockedchapters [chapternumber] - Allows access to the specified chapters of the game. Chapter number are shown under New Game in the main menu (e.g. sv_unlockedchapters 3 unlocks the first three Chapters of the game).


npc_create [npctype] - Creates an NPC of the given type if that NPC is available on the current level.


npc_destroy_unselected - Destroys all the NPCs not currently specified.


npc_kill [npcname] - Kills specified NPC, or NPC currently under the cursor if none specified.


npc_speakall - Forces the current NPC to speak all their possible responses.


setpos [x y z] - Moves player to the specified co-ordinates on the current map
__________________
"We are all atheists about most of the gods that humanity has ever believed in. Some of us just go one god further." - Richard Dawkins
Diplo is offline   Reply With Quote
Old 18-Jul-2005, 10:08   #5
Neeyik
Homo ergaster
 
Join Date: Feb 2002
Location: Cumbria, UK
Posts: 1,231
Default

In future can people not do this - there is quite a difference between copying bits of somebody else's work for a quote or two, and wholesale copy&pasting; the latter is especially unfair as it removes traffic to the site in question (other than for the copying of course) and, importantly, advertising revenue. We would be particularly annoyed if somebody just copied our articles onto another site and the same applies here.

Besides, if you're at work and the site is blocked, then surely it can wait until you're at home because one wouldn't be playing games at work now, would one?
Neeyik is offline   Reply With Quote
Old 18-Jul-2005, 18:48   #6
Diplo
Senior Member
 
Join Date: Apr 2004
Location: UK
Posts: 1,474
Default

Apologies, I was just trying to help someone out. Won't happen again.
__________________
"We are all atheists about most of the gods that humanity has ever believed in. Some of us just go one god further." - Richard Dawkins
Diplo is offline   Reply With Quote
Old 18-Jul-2005, 18:55   #7
Neeyik
Homo ergaster
 
Join Date: Feb 2002
Location: Cumbria, UK
Posts: 1,231
Default

Don't worry about it - I had meant to be replying to Micky personally but forgot to quote the request.
Neeyik is offline   Reply With Quote
Old 18-Jul-2005, 19:16   #8
digitalwanderer
Dangerously Mirthful
 
Join Date: Feb 2002
Location: Winfield, IN USA
Posts: 15,314
Default

Heh, my contribution will be:

"sk_plr_dmg_pistol 1000"

Makes that lil 9mm do some SERIOUS damage. 8)
digitalwanderer is offline   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Best and Worst of Half Life 2 ****MAJOR HL2 SPOILERS**** Bouncing Zabaglione Bros. PC Games 137 04-Jan-2005 08:30
Half Life 2 Stream - shelf life? Windfire PC Games 20 29-Nov-2004 19:08
Half Life joke K.I.L.E.R General Discussion 14 10-Nov-2004 09:46
Half Life 2 delayed again? Unknown Soldier PC Games 17 24-Jan-2004 19:50


All times are GMT +1. The time now is 22:10.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.