BF2 Tweaking

From GCWiki

Jump to: navigation, search

Contents

Hitbox Detection

Some examples of BF2 hit detection: Example1 Example 2

This is a detailed explaination for fixing this problem that I found on another forum. Enjoy.


The information below has been complied based on changes made to the usersettngs.con file. The information below can s improve hit detection for some while others may notice no change. However, I must note that you must have an optimum system with a low ping, fast internet connection. The information found in the usersettings.con file appear to be client side. Meaning that you must have a decent cpu, video card and at least 2 gigs of ram to advantage of any changes you make. It appears that the usersettings.con file was created in such a way to accommodate those with low-mid computers/connections/lag in mind. Keep that in mind before you start tweaking. This means that if you have a low-mid range computer and, you make changes to the usersettings.con you WILL NOT see much benefit when compared to those with higher end systems. Therefore, remember this before you post

The file is in your: Gamedir\mods\bf2\settings\usersettings.con

usersettings.con

rem
rem Settingsfile automatically saved by bf2
rem
SettingsManager.boolSet GSClPunkBuster 1
SettingsManager.floatSet GSDefaultLatencyCompensation 0.100000
SettingsManager.boolSet GSExtrapolateFrame 0
SettingsManager.U32Set GSExtrapolationTime 1200
SettingsManager.U32Set GSInterpolationTime 100
SettingsManager.U32Set GSPerfLogAtPlayerCount 30
SettingsManager.stringSet GSPlayerName "(my name went here)"
SettingsManager.boolSet GSShowNetGraph 0
SettingsManager.boolSet GSUseObjectCache 1

GSDefaultLatencyCompensation is the key:

This helps to match your ping to the ping of the game. For some reason GSDefaultLatencyCompensation is set to 100ms or 0.1 by default. Those who had the lowest ping (5-40) suffered the most lag as it was no where near 100ms. That's why those with pings of 70-100ms didn't have problems because they were close to the 100ms default (something I posted before). Some of you may not want to change this if all your servers come in close to 100ms.

However, if they are for example 140 you can change to 0.140 for example. I am not sure if this will work or not but the theory behind it is simple. Low ping is not the key, matching your ping to the ping of the game is key.

There is no easy remedy, either:

  1. dedicate yourself to only one server and keep the value the same in the usersettings.con
  2. always change it via "~" each time you enter a server (manually).

Here is what you do:

  1. When in-game bring up the console and type the following command.
  2. "SettingsManager.floatSet GSDefaultLatencyCompensation 0.XX"
  3. It's default is 0.1 means 100ms. Therefore press tab, look at your ping and replace the 0.1 with your ping eg:
    • If your ping is 30 then you type 0.03
    • If your ping is 140 you type 0.140
    • You get the idea. Remember when typing the command, don't include the quotes ("").

Example:

  1. Entered into BF2 session
  2. Hit the ~ key
  3. Then type SettingsManager.floatSet GSDefaultLatencyCompensation 0.04 (make sure you use the caps as needed) because my ping reads 40
  4. Play the game

SettingsManager.floatSet GSDefaultLatencyCompensation 0.100000

Should have been variable but it's not. You have to adjust this manually to what your ping is for optimum playing experience. As already noted 0.10 means 100ms ping

SettingsManager.U32Set GSExtrapolationTime 100

This has something to do with the time it takes to process what is already on the screen. But remember in order to lower it you need a fast CPU and, I'll assume you will need a high end video card along with a low ping, fast ISP for optimum results. Extrapolation: the process of constructing new data points outside a discrete set of "known data points", not sure. This appears to be client side. But this could mean location of your shot when fired (for example).

SettingsManager.U32Set GSInterpolationTime 1200

This has something to do with the time it takes to predict (what? I don't know). It appears that 1200 default is to long of a time lapse to predict which causes lag for some. Interpolation: estimation of a value between two known data points. I assume it's the prediction process between you and the server. This seems to predict certain aspects of the game like shot location for example. Some try reducing this value for better results. Be warned, you must have a system that can handle these calculations. This all appears to be client side.

Information gathered:

Hit detection improved dramatically on a high end system. Not guarantee on a low end system because the default values appear to accommodate them. Some of you who have a mid-low end system with a decent ISP shouldn't have the same problems as those who have a high end system with a very low (usually between 15-5ms ping) ISP (in theory). Again, I cannot stress this enough, it appears that changing the: SettingsManager.floatSet GSDefaultLatencyCompensation SettingsManager.U32Set GSInterpolationTime & SettingsManager.U32Set GSExtrapolationTime appears to depend on a upper hardware and ISP.

However, if you have the recommended requirements here is what I found:

  • Hit detection improved dramatically. Even if combatant is moving from side to side you still register a hit.
  • Firing the weapon now appears to be more accurate when you pause between shots in single shot mode. I am not sure if I need to further tweak those commands or not. However, I have a tendency to hit a target each and every time when I pause between shots in single shot mode.

PunkBuster Refresh Rate

Punkbuster is checking your PC every 20 sec. for cheats etc., which canmake your game lag. You can adjust the time between checks by simply opening the console ingame.

  1. Open Console
  2. type pb_sleep(space) 500 and hit enter
  3. type pb_writecfg and hit enter again

Now Punkbuster will check your pc every 500 seconds instead of every 20 seconds. Dont go higher then 500 because it wont be excepted.

Links

BF2 Tweak Guide on tweakguides.com

Personal tools