EN:Source Netsettings
From FrâG^.WIKI
There are several commands on both client and server side that control the flow of data between client and server. Only the important ones which are allowed to change (without sv_cheat 1) are covered here.
The net engine is very complex, as it has to take into account all latencies ("ping") on the network. Because the data packets usually take a few 10ms to travel between client and server, the information is always outdated the moment it arrives. This has to be corrected by the so-called interpolation, which tries to predict what has changed since the last update. The precision of this interpolation is vital to the quality of the gameplay. Errors in the prediction will lead to problems like hits not being recognized by the server.
Contents |
Client Side
cl_updaterate
This command specifies the maximum number of updates the client accepts from the server. Higher values are better, because the information the client has is then more up-to-date. Of course higher values will lead to a higher data rate, which can increase the ping (if the connection is tight). A higher ping on the other hand will make the information more out-dated again. Matching the cl_updaterate to the servers tickrate is usually optimal, unless the connection cannot handle this.
cl_cmdrate
Similar to cl_updaterate, this command specifies the maximum number of command packages the client sends to the server. Also in this case, higher values are better, because it will increase the accuracy the hits will be recognized. Again, matching the cl_updaterate to the servers tickrate is usually optimal, unless the connection cannot handle this.
rate
This command specifies the available bandwidth the engine is allowed to use (given in bytes per second). If either the incoming or outgoing data rate would exceed this value, the engine will drop some packages to keep the data rate below the limit (this is called "choke"). This value should be set slightly lower than the bandwidth of your internet connection. If you have an asynchronous connection (i.e. different upload and download speeds, like most DSL), you should keep it below the lower of the two bandwidths. Unless cl_cmd/updaterate settings are too high for your bandwidth, so the engine is forced to limit the data rate, this command does not really have any effect. In particular, all values larger than the possible data rates don't make any difference.
cl_interp
This command specifies the time in seconds to shift back the game for the interpolation. It is important for the interpolation (= lag compensation) to work that this value is not too small. In the net_graph the "lerp" value gives this amount of time. It should be colored white, else it is set too small. If you want to tune it to the optimal value start with 0.01 and increase the value in steps of 0.01 until the lerp value turns white. It should stay white even while in battle with multiple enemies. It is probably better to have it set a little higher than the absolute limit where it turns white.
Too high values do not really hurt. It will only increase the effect that you e.g. die at a place where you no longer was. That is not an actual disadvantage as you really died when you were at that place. Only the information that you died takes some extra time to get to you, so - from your point of view - you continue to live just a little longer. But this is merely a psychological disadvantage.
On the other hand setting it too low will probably lead to hits not properly recognized by the game as the interpolation cannot fully compensate some difference in the ping and so the hit boxes will not be in place where you see the model.
Server Side
sv_maxupdaterate and sv_minupdaterate
Those settings are the maximum and minimum values that are allowed for the cl_updaterate of the connected clients. Client settings outside those values will be changed without any notice to match those limits (even the values of the client CVARs are not changed).
sv_maxcmdrate and sv_mincmdrate
Similar to the sv_min/maxupdaterate, these settings are the maximum and minimum values that are allowed for the cl_cmdrate of the connected clients. Again, client settings outside those values will be changed without any notice to match those limits (also here aren't the values of the client CVARs changed).
sv_maxrate and sv_minrate
Also this settings are the maximum and minimum for the client's rate.
fps_max and host_framerate
- fps_max controls the maximum allowed frame rate of the server. For maximum quality, set fps_max to 0 to disable the limit (fps_max 1000 can be worse in some situations).
- host_framerate is a command to make the server believe running at the given frame rate. This is never what you actually want to have. It will not make your server quality better (as it doesn't change the actual fps), and it will make the game running too fast or too slow if the actual fps do not match what you set host_framerate to (which will be virtually always the case as the actual fps change). So the one and only correct option is host_framerate 0 (which is the default).
Two Notes to Server Admins
- If you have often so-called "lowraters" (i.e. players with the default netsettings 30/20/3500) on your server, you could think of forcing them to e.g. 100/100/35000 by appropriate choice of the above commands. Unfortunately this will not have the desired effect. Some players will not have a connection capable of such high rates. If you force them using those settings, they will have loss and a high ping. Both effects are much worse than having players with "low" (in fact valve-default!) values. So keep your minimum values at a moderate level, to allow players with a sub-optimal connection to play on your server.
- Even if you set e.g. sv_mincmdrate 50, some players will have actual command rates lower than 50. The actual command rate can only be as high as the client's fps. Especially in critical combat situations with many players in front, the fps will often drop below 50 if not playing on very recent hardware. This should be considered when choosing the server settings!
Diagnosis and Problems
Choke
"Choke" is a pure client problem (unless forcing the clients into bad settings by sv_min/max rate commands). it will occur if you set the maximum allowed bandwidth (-> command "rate") lower than what is required for your cl_cmd/updaterate. the idea is to protect against loss and highping, which would occur if you try to send more data than your connection can handle (and would be much worse).
Loss
"Loss" means that some packages are lost on the way from/to the server. This usually means that your connection to the server has some severe problem. It might indicate a setting of the "rate" command, that is higher than your bandwidth (so the engine sends more packages than your connection can handle), but it might also mean that your ISP has a bad connection to the server. You can check this by playing on other servers with the same tickrate and number of players.
High Ping
A high ping can have a number of causes. Unless playing with too high cl_cmd/updaterates and thus congesting your connection, there is little you can do about this. Maybe a different server or ISP can give some improvement.

