Command Line Options: Difference between revisions

From BF2 Technical Information Wiki
Jump to navigation Jump to search
(Created page with "== Introduction == Battlefield 2 supports quite a few command line options. Most of you are probably already familiar with ones such as <code>+fullscreen 1</code>. Incase some...")
 
No edit summary
 
Line 1: Line 1:
== Introduction ==
== Introduction ==
 
Battlefield 2 supports quite a few command line options. Most of you are probably already familiar with ones such as <code>+fullscreen 1</code>. Incase some of you don't know, you can set a command line option by bringing up a shortcut's properties, going to the shorcut tab, and adding any of these options to the end of the 'Target' field. Command line options can only be set on shorcuts, which is useful because it allows you to have multiple shortcuts, all with different command line options. The following is a list of known command line options.
Battlefield 2 supports quite a few command line options. Most of you are probably already familiar with ones such as <code>+fullscreen 1</code>. Incase some of you don't know, you can set a command line option by bringing up a shortcut's properties, going to the shorcut tab, and adding any of these options to the end of the 'Target' field. Command line options can only be set on shorcuts, which is useful because it allows you to have multiple shortcuts, all with different command line options. The following is a list of known command line options.


NOTE: The following options were found with the debug version of the BF2.exe, so some of these options may not work with the normal BF2.exe. The debug build can be obtained by downloading and installing the Battlefield 2 Editor. Once installed the debug build is named BF2_r.exe in your main Battlefield 2 directory. The Battlefield 2 Editor can be downloaded at [http://www.fileplanet.com/155852/download/Battlefield-2-Editor Battlefield 2 Editor] Also, case does matter when using these options.
NOTE: The following options were found with the debug version of the BF2.exe, so some of these options may not work with the normal BF2.exe. The debug build can be obtained by downloading and installing the Battlefield 2 Editor. Once installed the debug build is named BF2_r.exe in your main Battlefield 2 directory. The Battlefield 2 Editor can be downloaded at [http://www.fileplanet.com/155852/download/Battlefield-2-Editor Battlefield 2 Editor] Also, case does matter when using these options.


== Basic Options ==
== Basic Options ==
<code>'''+multi'''</code>
 
:Description: Allows you to start multiple instances of Battlefield 2 at the same time.
; <code>+multi</code>
: Description: Allows you to start multiple instances of Battlefield 2 at the same time.
Usage: <code>+multi <bool></code>
Usage: <code>+multi <bool></code>


<code>'''+joinServer'''</code>
; <code>+joinServer</code>
:Description: Joins the specified server. Accepts either a server ip or a hostname.
: Description: Joins the specified server. Accepts either a server ip or a hostname.
Usage: <code>+joinServer <string> OR <ip></code>
Usage: <code>+joinServer <string> OR <ip></code>


<code>'''+playerName'''</code>
; <code>+playerName</code>
:Description: Sets the player name.
: Description: Sets the player name.
Usage: <code>+playerName <string></code>
Usage: <code>+playerName <string></code>


<code>'''+password'''</code>
; <code>+password</code>
:Description: Used in conjunction with <code>+joinServer</code> when the server requires a password. Possibly also sets the password for a dedicated server?
: Description: Used in conjunction with <code>+joinServer</code> when the server requires a password. Possibly also sets the password for a dedicated server?
Usage: <code>+password <string></code>
Usage: <code>+password <string></code>


<code>'''+lowPriority'''</code>
; <code>+lowPriority</code>
:Description: Runs Battlefield 2 with a lower process priority(less CPU intensive, lower performance)
: Description: Runs Battlefield 2 with a lower process priority(less CPU intensive, lower performance)
Usage: <code>+lowPriority <bool></code>
Usage: <code>+lowPriority <bool></code>


<code>'''+loadLevel'''</code>
; <code>+loadLevel</code>
:Description: Loads the specified level.
: Description: Loads the specified level.
Usage: <code>+loadLevel <string></code>
Usage: <code>+loadLevel <string></code>


<code>'''+wx'''</code>
; <code>+wx</code>
:Description: When Battlefield 2 is running in windowed mode, this sets the window's horizontal position on the screen. When setting this option, keep in mind that 0 corresponds to the left of the screen, and that the window is being positioned from its left side.
: Description: When Battlefield 2 is running in windowed mode, this sets the window's horizontal position on the screen. When setting this option, keep in mind that 0 corresponds to the left of the screen, and that the window is being positioned from its left side.
Usage: <code>+wx <int></code>
Usage: <code>+wx <int></code>


<code>'''+wy'''</code>
; <code>+wy</code>
:Description: When Battlefield 2 is running in windowed mode, this sets the window's vertical position on the screen. When setting this option, keep in mind that 0 corresponds to the top of the screen, and that the window is being positioned from its top side.
: Description: When Battlefield 2 is running in windowed mode, this sets the window's vertical position on the screen. When setting this option, keep in mind that 0 corresponds to the top of the screen, and that the window is being positioned from its top side.
Usage: <code>+wy <int></code>
Usage: <code>+wy <int></code>


<code>'''+szx'''</code>
; <code>+szx</code>
:Description: When Battlefield 2 is running in windowed mode, this sets the window's horizontal size.
: Description: When Battlefield 2 is running in windowed mode, this sets the window's horizontal size.
Usage: <code>+szx <int></code>
Usage: <code>+szx <int></code>


<code>'''+szy'''</code>
; <code>+szy</code>
:Description: When Battlefield 2 is running in windowed mode, this sets the window's vertical size.
: Description: When Battlefield 2 is running in windowed mode, this sets the window's vertical size.
Usage: <code>+szy <int></code>
Usage: <code>+szy <int></code>


<code>'''+loadObfuscated'''</code>
; <code>+loadObfuscated</code>
:Description: Load obfuscated shaders. No idea what that means.
: Description: Load obfuscated shaders. No idea what that means.
Usage: <code>+loadObfuscated <bool></code>
Usage: <code>+loadObfuscated <bool></code>


<code>'''+fullscreen'''</code>
; <code>+fullscreen</code>
:Description: Toggles Battlefield 2 between windowed and full screen mode.
: Description: Toggles Battlefield 2 between windowed and full screen mode.
Usage: <code>+fullscreen <bool></code>
Usage: <code>+fullscreen <bool></code>


<code>'''+noSound'''</code>
; <code>+noSound</code>
:Description: Starts Battlefield 2 with sound disabled.
: Description: Starts Battlefield 2 with sound disabled.
Usage: <code>+noSound <bool></code>
Usage: <code>+noSound <bool></code>


<code>'''+lateLoading'''</code>
; <code>+lateLoading</code>
:Description: If set to 1, then resources (only sound at the moment) will be loaded on first use.
: Description: If set to 1, then resources (only sound at the moment) will be loaded on first use.
Usage: <code>+lateLoading <bool></code>
Usage: <code>+lateLoading <bool></code>


<code>'''+skipMips'''</code>
; <code>+skipMips</code>
:Description: Sets how many mip-levels to skip in textures.
: Description: Sets how many mip-levels to skip in textures.
Usage: <code>+skipMips <int></code>
Usage: <code>+skipMips <int></code>


<code>'''+mergeMaterials'''</code>
; <code>+mergeMaterials</code>
:Description: Concatenate materials at load time.
: Description: Concatenate materials at load time.
Usage: <code>+mergeMaterials <bool></code>
Usage: <code>+mergeMaterials <bool></code>


<code>'''+managedTextures'''</code>
; <code>+managedTextures</code>
:Description: Decides whether system memory should be used for textures.
: Description: Decides whether system memory should be used for textures.
Usage: <code>+managedTextures <bool></code>
Usage: <code>+managedTextures <bool></code>


<code>'''+debugOutput'''</code>
; <code>+debugOutput</code>
:Description: Enables or disables debug output.
: Description: Enables or disables debug output.
Usage: <code>+debugOutput <bool></code>
Usage: <code>+debugOutput <bool></code>


<code>'''+demo'''</code>
; <code>+demo</code>
:Description: Sets the con-file with demo options. Not sure what this does.
: Description: Sets the con-file with demo options. Not sure what this does.
Usage: <code>+demo <??></code>
Usage: <code>+demo <??></code>


<code>'''+pyVerbose'''</code>
; <code>+pyVerbose</code>
:Description: Display verbose Python script output. Nothing too interesting here.
: Description: Display verbose Python script output. Nothing too interesting here.
Usage: <code>+pyVerbose <bool></code>
Usage: <code>+pyVerbose <bool></code>


<code>'''+modPath'''</code>
; <code>+modPath</code>
:Description: Sets Battlefield 2's mod path. This is normally <code>mods/bf2</code>.
: Description: Sets Battlefield 2's mod path. This is normally <code>mods/bf2</code>.
Usage: <code>+modPath <string></code>
Usage: <code>+modPath <string></code>


<code>'''+ignoreAsserts'''</code>
; <code>+ignoreAsserts</code>
:Description: Ignores debug assertion errors. This can only be used in conjunction with <code>+developer 1</code> or <code>+dedicated 1</code>.
: Description: Ignores debug assertion errors. This can only be used in conjunction with <code>+developer 1</code> or <code>+dedicated 1</code>.
Usage: <code>+ignoreAsserts <bool></code>
Usage: <code>+ignoreAsserts <bool></code>


<code>'''+disableShaderCache'''</code>
; <code>+disableShaderCache</code>
:Description: Disables the shader cache. This should only be used in conjunction with <code>+developer 1</code>.
: Description: Disables the shader cache. This should only be used in conjunction with <code>+developer 1</code>.
Usage: <code>+disableShaderCache <bool></code>
Usage: <code>+disableShaderCache <bool></code>


<code>'''+dumpAllConFiles'''</code>
; <code>+dumpAllConFiles</code>
:Description: Writes the names of every .con file to <code>mods/$MOD$/allConFiles.con</code>.
: Description: Writes the names of every <code>.con</code> file to <code>mods/$MOD$/allConFiles.con</code>.
Usage: <code>+dumpAllConFiles <bool></code>
Usage: <code>+dumpAllConFiles <bool></code>


<code>'''+customConFile'''</code>
; <code>+customConFile</code>
:Description: Uses the specified .con file instead of loading all of the .con files. This file should be used to specify which con files to run, using the run command.
: Description: Uses the specified <code>.con</code> file instead of loading all of the <code>.con</code> files. This file should be used to specify which con files to run, using the <code>run</code> command.
Usage: <code>+customConFile <string></code>
Usage: <code>+customConFile <string></code>


<code>'''+help'''</code>
; <code>+help</code>
:Description: Displays command line option help, which lists all command line options and gives some descriptions.
: Description: Displays command line option help, which lists all command line options and gives some descriptions.
Usage: <code>+help</code>
Usage: <code>+help</code>


<code>'''+?'''</code>
; <code>+?</code>
:Description: Does the same thing as +help.
: Description: Does the same thing as <code>+help</code>.
Usage: <code>+?</code>
Usage: <code>+?</code>


<code>'''+fileMonitor'''</code>
; <code>+fileMonitor</code>
:Description: Enables automatic update of changed files (shaders, etc). This could prove to be very useful if it applies to .con and .py files.
: Description: Enables automatic update of changed files (shaders, etc). This could prove to be very useful if it applies to <code>.con</code> and <code>.py</code> files.
Usage: <code>+fileMonitor <bool></code>
Usage: <code>+fileMonitor <bool></code>


<code>'''+playerPassword'''</code>
; <code>+playerPassword</code>
:Description: Sets the player's password
: Description: Sets the player's password
Usage: <code>+playerPassword <string></code>
Usage: <code>+playerPassword <string></code>


<code>'''+developer'''</code>
; <code>+developer</code>
:Description: Does not auto-login, and also allows other command line options to be used in conjunction with it.
: Description: Does not auto-login, and also allows other command line options to be used in conjunction with it.
Usage: <code>+developer <bool></code>
Usage: <code>+developer <bool></code>


<code>'''+disableSwiff'''</code>
; <code>+disableSwiff</code>
:Description: Disables swiff player. Basically this disables the flash that is used at the main menu area. Swiff refers to .swf, the flash file format.
: Description: Disables swiff player. Basically this disables the flash that is used at the main menu area. Swiff refers to <code>.swf</code>, the flash file format.
Usage: <code>+disableSwiff <bool></code>
Usage: <code>+disableSwiff <bool></code>


<code>'''+debugSwiff'''</code>
; <code>+debugSwiff</code>
:Description: Enables swiff debug output. Swiff refers to .swf, the flash file format.
: Description: Enables swiff debug output. Swiff refers to <code>.swf</code>, the flash file format.
Usage: <code>+debugSwiff <bool></code>
Usage: <code>+debugSwiff <bool></code>


<code>'''+playNow'''</code>
; <code>+playNow</code>
:Description: Starts up the game and automatically uses the 'Play Now' functionality.
: Description: Starts up the game and automatically uses the 'Play Now' functionality.
Usage: <code>+playNow <bool></code>
Usage: <code>+playNow <bool></code>


<code>'''+pbPath'''</code>
; <code>+pbPath</code>
:Description: Sets the path to Punkbuster for multiple-instance configurations. This is normally <code>{install_dir}/pb</code>.
: Description: Sets the path to Punkbuster for multiple-instance configurations. This is normally <code>{install_dir}/pb</code>.
Usage: <code>+pbPath <string></code>
Usage: <code>+pbPath <string></code>


<code>'''+keepCollisionForNavMeshes'''</code>
; <code>+keepCollisionForNavMeshes</code>
:Description: Keep collision mesh lods needed to generate AI navigation meshes. Not sure what this does.
: Description: Keep collision mesh lods needed to generate AI navigation meshes. Not sure what this does.
Usage: <code>+keepCollisionForNavMeshes <bool></code>
Usage: <code>+keepCollisionForNavMeshes <bool></code>


<code>'''+restart'''</code>
; <code>+restart</code>
:Description: Used by BF2 to restart the game without showing video for example when mod switching - can also be used to start BF 2 without showing videos using your own shortcuts
: Description: Used by BF2 to restart the game without showing video for example when mod switching - can also be used to start BF 2 without showing videos using your own shortcuts
Usage: <code>+restart <bool></code>
Usage: <code>+restart <bool></code>


<code>'''+port'''</code>
; <code>+port</code>
:Description: Used for specifying a port number to connect to in conjuntion with <code>+joinServer</code>
: Description: Used for specifying a port number to connect to in conjuntion with <code>+joinServer</code>
Usage: <code>+port <integer></code>
Usage: <code>+port <integer></code>


== Dedicated Server Options ==
==Dedicated Server Options ===
<code>'''+dedicated'''</code>
 
:Description: Starts Battlefield 2 in dedicated server mode. Not needed on Linux
; <code>+dedicated</code>
: Description: Starts Battlefield 2 in dedicated server mode. Not needed on Linux
Usage: <code>+dedicated <bool></code>
Usage: <code>+dedicated <bool></code>


<code>'''+port'''</code>
; <code>+port</code>
:Description: Specifies which port the server should use.
: Description: Specifies which port the server should use.
Usage: <code>+port <int></code>
Usage: <code>+port <int></code>


<code>'''+maxPlayers'''</code>
; <code>+maxPlayers</code>
:Description: Sets max number of players for the server.
: Description: Sets max number of players for the server.
Usage: <code>+maxPlayers <int></code>
Usage: <code>+maxPlayers <int></code>


<code>'''+gameMode'''</code>
; <code>+gameMode</code>
:Description: Sets the gamemode for the server.
: Description: Sets the gamemode for the server.
Usage: <code>+gameMode <string></code>
Usage: <code>+gameMode <string></code>


<code>'''+config'''</code>
; <code>+config</code>
:Description: Sets the path to the ServerSettings.con file to use.
: Description: Sets the path to the ServerSettings.con file to use.
Usage: <code>+config <string></code>
Usage: <code>+config <string></code>


<code>'''+mapList'''</code>
; <code>+mapList</code>
:Description: Sets the path to the mapList.con file to use.
: Description: Sets the path to the mapList.con file to use.
Usage: <code>+mapList <string></code>
Usage: <code>+mapList <string></code>


<code>'''+noStatusMonitor'''</code>
; <code>+noStatusMonitor</code>
:Description: If you don't want to run bf2 inside screen you need to use this.
: Description: If you don't want to run bf2 inside screen you need to use this.
Usage: <code>+noStatusMonitor <int></code> with values 1 (or 0 the default if you don't specify this option at all)
Usage: <code>+noStatusMonitor <int></code> with values 1 (or 0 the default if you don't specify this option at all)


<code>'''+ranked'''</code>
; <code>+ranked</code>
:Description: Allows gamespy snapshot sending. This setting will do nothing unless EA has the IP of the server in their database.
: Description: Allows gamespy snapshot sending. This setting will do nothing unless EA has the IP of the server in their database.
Usage: <code>+ranked <bool></code>
Usage: <code>+ranked <bool></code>


== Advanced Options ==
== Advanced Options ==
<code>'''+hostServer'''</code>
 
:Description: Unknown at the moment. Most likely starts a local server.
; <code>+hostServer</code>
: Description: Unknown at the moment. Most likely starts a local server.
Usage: <code>+hostServer <??></code>
Usage: <code>+hostServer <??></code>


<code>'''+checkForAvailablePatch'''</code>
; <code>+checkForAvailablePatch</code>
:Description: Unknown at the moment. Most likely does what the name says. When used with the debug build, returns an error message on startup. Appears to be broken.
: Description: Unknown at the moment. Most likely does what the name says. When used with the debug build, returns an error message on startup. Appears to be broken.
Usage: <code>+checkForAvailablePatch <??></code>
Usage: <code>+checkForAvailablePatch <??></code>


<code>'''+checkForPatch'''</code>
; <code>+checkForPatch</code>
:Description: Unknown at the moment. How does this differ from <code>+checkForAvailablePatch</code>? When used with the debug build, returns an error message on startup. Appears to be broken.
: Description: Unknown at the moment. How does this differ from <code>+checkForAvailablePatch</code>? When used with the debug build, returns an error message on startup. Appears to be broken.
Usage: <code>+checkForPatch <??></code>
Usage: <code>+checkForPatch <??></code>


<code>'''+aidll'''</code>
; <code>+aidll</code>
:Description: Unknown at the moment. Perhaps disables or enables the Battlefield 2 aidll.dll?
: Description: Unknown at the moment. Perhaps disables or enables the Battlefield 2 aidll.dll?
Usage: <code>+aidll <??></code>
Usage: <code>+aidll <??></code>


<code>'''+ai'''</code>
; <code>+ai</code>
:Description: Used to Force BF2 to load AI BOTS! No matter the map, requirements, or settings. --MasterX
: Description: Used to Force BF2 to load AI BOTS! No matter the map, requirements, or settings. --MasterX
Usage: <code>+ai <0/1></code>
Usage: <code>+ai <0/1></code>


<code>'''+refresh'''</code>
; <code>+refresh</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+refresh <??></code>
Usage: <code>+refresh <??></code>


<code>'''+renderMode'''</code>
; <code>+renderMode</code>
:Description: Sets the current render mode. Possible render modes are 0-5, not sure what each one does yet.
: Description: Sets the current render mode. Possible render modes are 0-5, not sure what each one does yet.
Usage: <code>+renderMode <int></code>
Usage: <code>+renderMode <int></code>


<code>'''+rp'''</code>
; <code>+rp</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+rp <??></code>
Usage: <code>+rp <??></code>


<code>'''+deviceType'''</code>
; <code>+deviceType</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+deviceType <??></code>
Usage: <code>+deviceType <??></code>


<code>'''+deviceBehavior'''</code>
; <code>+deviceBehavior</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+deviceBehavior <??></code>
Usage: <code>+deviceBehavior <??></code>


<code>'''+skipMeshLods'''</code>
; <code>+skipMeshLods</code>
:Description: Unknown at the moment. LoD
: Description: Unknown at the moment. [http://en.wikipedia.org/wiki/Level_of_Detail LoD]
Usage: <code>+skipMeshLods <??></code>
Usage: <code>+skipMeshLods <??></code>


<code>'''+keepTemplates'''</code>
; <code>+keepTemplates</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+keepTemplates <??></code>
Usage: <code>+keepTemplates <??></code>


<code>'''+profileTextureUsage'''</code>
; <code>+profileTextureUsage</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+profileTextureUsage <??></code>
Usage: <code>+profileTextureUsage <??></code>


<code>'''+convertCollisionMeshes'''</code>
; <code>+convertCollisionMeshes</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+convertCollisionMeshes <??></code>
Usage: <code>+convertCollisionMeshes <??></code>


<code>'''+generateLightMaps'''</code>
; <code>+generateLightMaps</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+generateLightMaps <??></code>
Usage: <code>+generateLightMaps <??></code>


<code>'''+debugNetwork'''</code>
; <code>+debugNetwork</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+debugNetwork <??></code>
Usage: <code>+debugNetwork <??></code>


<code>'''+debugGhostManager'''</code>
; <code>+debugGhostManager</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+debugGhostManager <??></code>
Usage: <code>+debugGhostManager <??></code>


<code>'''+compile'''</code>
; <code>+compile</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+compile <??></code>
Usage: <code>+compile <??></code>


<code>'''+useCompiled'''</code>
; <code>+useCompiled</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+useCompiled <??></code>
Usage: <code>+useCompiled <??></code>


<code>'''+NoEffectTextureAtlas'''</code>
; <code>+NoEffectTextureAtlas</code>
:Description: Unknown at the moment.
: Description: Unknown at the moment.
Usage: <code>+NoEffectTextureAtlas <??></code>
Usage: <code>+NoEffectTextureAtlas <??></code>


<code>'''+menu'''</code>
; <code>+menu</code>
:Description: Unknown at the moment. This is used by Battlefield 2's default shortcut as <code>+menu 1</code>.
: Description: Unknown at the moment. This is used by Battlefield 2's default shortcut as <code>+menu 1</code>.
Usage: <code>+menu <bool></code>
Usage: <code>+menu <bool></code>

Latest revision as of 22:06, 26 April 2018

Introduction

Battlefield 2 supports quite a few command line options. Most of you are probably already familiar with ones such as +fullscreen 1. Incase some of you don't know, you can set a command line option by bringing up a shortcut's properties, going to the shorcut tab, and adding any of these options to the end of the 'Target' field. Command line options can only be set on shorcuts, which is useful because it allows you to have multiple shortcuts, all with different command line options. The following is a list of known command line options.

NOTE: The following options were found with the debug version of the BF2.exe, so some of these options may not work with the normal BF2.exe. The debug build can be obtained by downloading and installing the Battlefield 2 Editor. Once installed the debug build is named BF2_r.exe in your main Battlefield 2 directory. The Battlefield 2 Editor can be downloaded at Battlefield 2 Editor Also, case does matter when using these options.

Basic Options

+multi
Description: Allows you to start multiple instances of Battlefield 2 at the same time.

Usage: +multi <bool>

+joinServer
Description: Joins the specified server. Accepts either a server ip or a hostname.

Usage: +joinServer <string> OR <ip>

+playerName
Description: Sets the player name.

Usage: +playerName <string>

+password
Description: Used in conjunction with +joinServer when the server requires a password. Possibly also sets the password for a dedicated server?

Usage: +password <string>

+lowPriority
Description: Runs Battlefield 2 with a lower process priority(less CPU intensive, lower performance)

Usage: +lowPriority <bool>

+loadLevel
Description: Loads the specified level.

Usage: +loadLevel <string>

+wx
Description: When Battlefield 2 is running in windowed mode, this sets the window's horizontal position on the screen. When setting this option, keep in mind that 0 corresponds to the left of the screen, and that the window is being positioned from its left side.

Usage: +wx <int>

+wy
Description: When Battlefield 2 is running in windowed mode, this sets the window's vertical position on the screen. When setting this option, keep in mind that 0 corresponds to the top of the screen, and that the window is being positioned from its top side.

Usage: +wy <int>

+szx
Description: When Battlefield 2 is running in windowed mode, this sets the window's horizontal size.

Usage: +szx <int>

+szy
Description: When Battlefield 2 is running in windowed mode, this sets the window's vertical size.

Usage: +szy <int>

+loadObfuscated
Description: Load obfuscated shaders. No idea what that means.

Usage: +loadObfuscated <bool>

+fullscreen
Description: Toggles Battlefield 2 between windowed and full screen mode.

Usage: +fullscreen <bool>

+noSound
Description: Starts Battlefield 2 with sound disabled.

Usage: +noSound <bool>

+lateLoading
Description: If set to 1, then resources (only sound at the moment) will be loaded on first use.

Usage: +lateLoading <bool>

+skipMips
Description: Sets how many mip-levels to skip in textures.

Usage: +skipMips <int>

+mergeMaterials
Description: Concatenate materials at load time.

Usage: +mergeMaterials <bool>

+managedTextures
Description: Decides whether system memory should be used for textures.

Usage: +managedTextures <bool>

+debugOutput
Description: Enables or disables debug output.

Usage: +debugOutput <bool>

+demo
Description: Sets the con-file with demo options. Not sure what this does.

Usage: +demo <??>

+pyVerbose
Description: Display verbose Python script output. Nothing too interesting here.

Usage: +pyVerbose <bool>

+modPath
Description: Sets Battlefield 2's mod path. This is normally mods/bf2.

Usage: +modPath <string>

+ignoreAsserts
Description: Ignores debug assertion errors. This can only be used in conjunction with +developer 1 or +dedicated 1.

Usage: +ignoreAsserts <bool>

+disableShaderCache
Description: Disables the shader cache. This should only be used in conjunction with +developer 1.

Usage: +disableShaderCache <bool>

+dumpAllConFiles
Description: Writes the names of every .con file to mods/$MOD$/allConFiles.con.

Usage: +dumpAllConFiles <bool>

+customConFile
Description: Uses the specified .con file instead of loading all of the .con files. This file should be used to specify which con files to run, using the run command.

Usage: +customConFile <string>

+help
Description: Displays command line option help, which lists all command line options and gives some descriptions.

Usage: +help

+?
Description: Does the same thing as +help.

Usage: +?

+fileMonitor
Description: Enables automatic update of changed files (shaders, etc). This could prove to be very useful if it applies to .con and .py files.

Usage: +fileMonitor <bool>

+playerPassword
Description: Sets the player's password

Usage: +playerPassword <string>

+developer
Description: Does not auto-login, and also allows other command line options to be used in conjunction with it.

Usage: +developer <bool>

+disableSwiff
Description: Disables swiff player. Basically this disables the flash that is used at the main menu area. Swiff refers to .swf, the flash file format.

Usage: +disableSwiff <bool>

+debugSwiff
Description: Enables swiff debug output. Swiff refers to .swf, the flash file format.

Usage: +debugSwiff <bool>

+playNow
Description: Starts up the game and automatically uses the 'Play Now' functionality.

Usage: +playNow <bool>

+pbPath
Description: Sets the path to Punkbuster for multiple-instance configurations. This is normally {install_dir}/pb.

Usage: +pbPath <string>

+keepCollisionForNavMeshes
Description: Keep collision mesh lods needed to generate AI navigation meshes. Not sure what this does.

Usage: +keepCollisionForNavMeshes <bool>

+restart
Description: Used by BF2 to restart the game without showing video for example when mod switching - can also be used to start BF 2 without showing videos using your own shortcuts

Usage: +restart <bool>

+port
Description: Used for specifying a port number to connect to in conjuntion with +joinServer

Usage: +port <integer>

Dedicated Server Options

+dedicated
Description: Starts Battlefield 2 in dedicated server mode. Not needed on Linux

Usage: +dedicated <bool>

+port
Description: Specifies which port the server should use.

Usage: +port <int>

+maxPlayers
Description: Sets max number of players for the server.

Usage: +maxPlayers <int>

+gameMode
Description: Sets the gamemode for the server.

Usage: +gameMode <string>

+config
Description: Sets the path to the ServerSettings.con file to use.

Usage: +config <string>

+mapList
Description: Sets the path to the mapList.con file to use.

Usage: +mapList <string>

+noStatusMonitor
Description: If you don't want to run bf2 inside screen you need to use this.

Usage: +noStatusMonitor <int> with values 1 (or 0 the default if you don't specify this option at all)

+ranked
Description: Allows gamespy snapshot sending. This setting will do nothing unless EA has the IP of the server in their database.

Usage: +ranked <bool>

Advanced Options

+hostServer
Description: Unknown at the moment. Most likely starts a local server.

Usage: +hostServer <??>

+checkForAvailablePatch
Description: Unknown at the moment. Most likely does what the name says. When used with the debug build, returns an error message on startup. Appears to be broken.

Usage: +checkForAvailablePatch <??>

+checkForPatch
Description: Unknown at the moment. How does this differ from +checkForAvailablePatch? When used with the debug build, returns an error message on startup. Appears to be broken.

Usage: +checkForPatch <??>

+aidll
Description: Unknown at the moment. Perhaps disables or enables the Battlefield 2 aidll.dll?

Usage: +aidll <??>

+ai
Description: Used to Force BF2 to load AI BOTS! No matter the map, requirements, or settings. --MasterX

Usage: +ai <0/1>

+refresh
Description: Unknown at the moment.

Usage: +refresh <??>

+renderMode
Description: Sets the current render mode. Possible render modes are 0-5, not sure what each one does yet.

Usage: +renderMode <int>

+rp
Description: Unknown at the moment.

Usage: +rp <??>

+deviceType
Description: Unknown at the moment.

Usage: +deviceType <??>

+deviceBehavior
Description: Unknown at the moment.

Usage: +deviceBehavior <??>

+skipMeshLods
Description: Unknown at the moment. LoD

Usage: +skipMeshLods <??>

+keepTemplates
Description: Unknown at the moment.

Usage: +keepTemplates <??>

+profileTextureUsage
Description: Unknown at the moment.

Usage: +profileTextureUsage <??>

+convertCollisionMeshes
Description: Unknown at the moment.

Usage: +convertCollisionMeshes <??>

+generateLightMaps
Description: Unknown at the moment.

Usage: +generateLightMaps <??>

+debugNetwork
Description: Unknown at the moment.

Usage: +debugNetwork <??>

+debugGhostManager
Description: Unknown at the moment.

Usage: +debugGhostManager <??>

+compile
Description: Unknown at the moment.

Usage: +compile <??>

+useCompiled
Description: Unknown at the moment.

Usage: +useCompiled <??>

+NoEffectTextureAtlas
Description: Unknown at the moment.

Usage: +NoEffectTextureAtlas <??>

+menu
Description: Unknown at the moment. This is used by Battlefield 2's default shortcut as +menu 1.

Usage: +menu <bool>