Difference between revisions of "Command-Line Reference"

From FreeSpace Wiki
Jump to: navigation, search
(-fov)
(-mod)
Line 295: Line 295:
 
# This flag is also used by FRED. So if there is special mod info, (like backgrounds maps, ship models or whatever), it must be typed, (''Fred2_Open_r.exe -MOD whatever''), or FRED won't be able to use it. No Launcher MOD tab available for this use. <br>   
 
# This flag is also used by FRED. So if there is special mod info, (like backgrounds maps, ship models or whatever), it must be typed, (''Fred2_Open_r.exe -MOD whatever''), or FRED won't be able to use it. No Launcher MOD tab available for this use. <br>   
 
# Be careful while typing the directory names in the flag argument or inside mod.ini files. The program doesn't check if the typed directories exist. If they do not exist, they are just ignored. No warnings, no errors, no messages at all.
 
# Be careful while typing the directory names in the flag argument or inside mod.ini files. The program doesn't check if the typed directories exist. If they do not exist, they are just ignored. No warnings, no errors, no messages at all.
 +
 +
 +
:'''VERY IMPORTANT INFO ABOUT PRIORITY AND TEXTURE FILES'''
 +
 +
:FS2_Open can use several file formats in textures: PCX, DDS, JPG and TGA (the last two need the flag [[Command-Line_Reference#-jpgtga|-jpgtga]]). '''Always update every texture keeping its format'''. For example if you update the old ''TextureOfMyFighter.tga'', do not save it as ''TextureOfMyFighter.dds'' in a higher priority place, because there is a chance of the game loading the old one despite of all.
 +
 +
:The reason to do this is that, at least in FS2_Open v3.6.9. and previous versions, loading process (including priorities) is applied firstly for a kind of textures (TGAs), then for another kind (JPGs), and so on. The exact order of this global texture type priority may change in the future but nevertheless there is always going to be a fixed loading order between them. This behaviour can lead to situation where your new, updated and higher priority placed texture is not read because the format of the older one. (An example of this situation can be found in [http://scp.indiegames.us/mantis/view.php?id=1123 this false Mantis Bug 1123]).
 +
 +
:The reason of this behaviour relays in the way the game looks for files. Without this way of coding, the number of file searches would hugely increase, so mission loading times would be much higher.
  
 
====-fov====
 
====-fov====

Revision as of 18:00, 27 October 2006

Contents

Launcher Flags

The following command-line options can be chosen from the launcher.

Graphics

-spec

Enables specular mapping. Only polygons mapped with textures for which a shinemap exists will recieve specular mapping; no attempt is made to generate spec maps where they do not exist. Specular maps are specified with the base map name plus "-shine" (i.e. TCov3A-shine.pcx).

-env

Enables environment mapping. Environment mapping intensity will be determined from the intensity of specular maps. At the time of this writing (build 3.6.9 RC7), environment mapping only works when the video mode is OpenGL. See Video setup.

-glow

Enables glowmapping. Only polygons mapped with textures for which a glowmap exists will be glowmapped. Glow maps are specified with the base map name plus "-glow" (i.e. TCov4A-glow.pcx)

-jpgtga

Enables the use of TGA and JPG file formats for image files. If a ship is showing up partially invisible, select this option.

-pcx32

WARNING - HIGH MEMORY USAGE

Enables PCX files to be loaded into 32-bit memory. This will not imporove the rendering of any ships in-game, and is usually more of a burden on performance than is worthwhile. Use at your own risk. Removed from launcher options after 3.6.7.

-cell

Enables cell shading. This will make graphics appear more "cartoonish". For use with media in mv_cell.vp. Not considered a standard enhancement.

-mipmap

Enables mipmapping.

-nomotiondebris

Disables motion debris.

-2d_poof

Applies nebula poofs in 2d, effectively preventing them from forming intersections with ships.

-noscalevid

Disables scaling of video clips.

-missile_lighting

Applys lighting to missiles.

-rlm

Obsolete Argument

Enables more accurate lighting model for OpenGL mode. Always on in current builds, so this command-line option has been removed.


Game Speed

-img2dds

Converts all images to DDS (compressed) format. Decreases memory usage but potentially reduces image quality.

-no_vsync

Disables vertical sync.

-cache_bitmaps

Caches bitmaps between missions, which will ideally reduce the load-time from one mission to another.


HUD

-dualscanlines

Adds a second pair of scanning lines to the target window when scanning an object.

-targetinfo

Displays target info, such as name and class, beside the targeted object.

-orbradar

Enables 3D radar (the Orb). 3D radar will replace the standard 2D version.

-ballistic_gauge

Adds an ammo gauge to the HUD when armed with a ballistic weapon.

-rearm_timer

Displays time remaining until rearm and repair from a support ship is complete.


Gameplay

-smart_shields

Enables "smart" shield recharging. Shield recharge is distributed to the most damaged shield quadrant instead of being distributed equally across the entire shield and be wasted when a quadrant is full.

-ship_choice_3d

Use ship and weapon models in ship selection and weapon loadout. Completely disables the standard ANI interface on those screens.

-3dwarp

Use full geometry for the subspace warp effect.

-warp_flash

Enable a flash at warp in and warp out.

-UseNewAI

Tells the game to use new AI routines. This argument alters mission balance and is not considered a standard feature.

-tbp

Enable feature set for The Babylon Project

-wcsaga

Enable feature set for The Wing Commander Saga


Audio

-snd_preload

Preload mission sounds. Useful in preventing game stuttering when sounds are played for the first time.

-nosound

Disables all sounds.

-nomusic

Disables music only.


Multiplayer

-standalone

Creates a standalone server.

-startgame

Once you launch and choose a pilot within the game, you will immediately have begun to host a game. This can be used in conjunction with several options to customize the game you create: -closed, -restricted, -password, -gamename, -allowabove, and -allowbelow. -startgame has no effect when -standalone is used.

See related: -closed -restricted -password -gamename -allowabove -allowbelow

-closed

Hosts a new game in a closed state, where no one can join until the in-game "Close" button is cleared. This only works when used in conjunction with -startgame. Cannot be used in conjunction with -restricted or -password.

See related: -startgame -restricted -password

-restricted

Hosts a new game in a restricted state. The host is presented with option to accept or deny each client's request to join the game. This only works when used in conjunction with -startgame. Cannot be used in conjunction with -closed or -password.

See related: -startgame -closed -password

-multilog

Creates a log file with a summary of packets sent and received in multiplayer games. The file is saved as \data\multi.log within the active mod folder - or with main data folder if no mod is active.

-clientdamage

This feature is not available in current builds.

-mpnoreturn

Disables return to the flight deck screen after a mission completes.


Troubleshooting

-fixbugs

Obsolete Argument - Removed in builds after 3.6.7

Originally used to disable certain crashing behavior as a stop-gap measure. This feature is not available in current builds.

-nocrash

Obsolete Argument - Removed in builds after 3.6.7

Originally used to disable certain crashing behavior as a stop-gap measure. This feature is not available in current builds.

-oldfire

This feature is not available in current builds.

-nohtl

WARNING - VERY SLOW

Reverts to software rendering mode. Does this work any more?

-no_set_gamma

Disables the gamma settings in the options screen.

-nomovies

Disables all video playback.

-noparseerrors

Disables some parsing warnings and makes other parse errors non-fatal. Do not rely on this when creating new tables, the errors are there for a reason.

-safeloading

Loads missions the old way. Typically safer, but slower.

-query_speech

Determines if the current build includes text-to-speech.

-d3d_bad_tsys

Enable inefficient texture system.

-novbo

Disables OpenGL VBO.

-noibx

Disables IBX caching of model geometry data. This will dramatically increase load times, but will help troubleshoot a model if one is working incorrectly.

-loadallweps

Load all weapons, even those not used.


Experimental

-alpha_env

Enables alpha environment mapping. OpenGL only. Environment mapping intensity will be determined from the alpha channel of specular maps.

-decals

Enables damage decals.

-ingame_join

Enables ingame joining in multiplayer. FIXME: Host option?

-tga16

Obsolete Argument - Removed in builds after 3.6.7

Originally used to converts TGA images to 16-bits in order to reduce memory footprint (at the expense of image quality), superseded by -img2dds.


Development Tools

-fps

Displays current frames per second.

-pos

Displays current position coordinates of camera.

-window

Runs the game in a window. No check to make sure that resolution is no higher than your desktop resolution, so be careful.

-timerbar

Displays a timing bar across the top of the screen. Timebar format varies by build.

-stats

Shows total and free physical memory, virtual memory and system pagefile.

-coords

Shows coordinates of the mouse cursor.

-show_mem_usage

Shows detailed RAM usage in HUD.

The meaning of the info displayed in the upper right corner is:

DYN = dynamic memory, basically anything that's been allocated by the vm_* memory functions. This does NOT indicate total memory usage but does account for most of it.

POF = model memory, how much memory is being used by models (does not include textures)

C-BMP, BMP = bmpman memory, how much is used by the textures/images that are loaded. C-BMP means that you are using -cache_bitmaps and it will try to keep textures in memory between level loads and as the new level is loading it will keep what it needs and unload what it doesn't. Can greatly increase level loading speed, but does so at the cost of memory between level loads. This does not increase overall memory usage though, only during the loading screen. BMP means that it is not cached and all textures are unloaded from memory at the start of level load and all needed textures are then loaded from the disk again.

S-RAM = sound memory, how much is used by the sounds loaded in memory at the time. This counts static sounds only (from sounds.tbl, etc.) and not streaming sounds (music, voices, briefing stuff, etc).

V-RAM = approximate memory usage of video textures. This is not mean that your card has this much memory and can report higher numbers that your card actually has memory. For OpenGL it also includes some of the geometry data, but this number does not reflect the total memory that your video card is using. It only reports how much data the game has purposefully loaded into API memory (meaning it could be in system memory, video card memory, or AGP memory).


(It only works with debug builds, not with release builds).

-pofspew

What does this do?

-tablecrcs

What does this do?

-missioncrcs

What does this do?

-dis_collisions

Disables all collisions.

-dis_weapons

Disables weapons rendering.

-output_sexps

Outputs SEXPs to sexps.html.

-output_scripting

Outputs scripting to scripting.html.

-nograb

Unix only. Disables focus grabbing in a window.

Other

The following options are not available as checkboxes in the launcher. Many require parameters, which follow the flag seperated by a space. The prototype for use in this case is "-option argument"

Graphics

-ambient_factor

This must be entered into the "Custom flags" field. This is a multiplier applied to the intensity of ambient lighting. Ambient light is lighting applied to all parts of a ship. FS2's standard value is 120. Try 75 for a good and realistic looking value. However, that is relative.

-spec_exp

This must be used with the -spec command line parameter and must be entered into the "Custom flags" field. Adjusts the size of the shiny spot on ships. Higher number mean smaller spots. Default is 16, however 11 is recommended. However, that is relative.

-spec_point

This must be used with the -spec command line parameter and must be entered into the "Custom flags" field. Adjusts how much laser weapons contribute to specular highlights. Higher number mean greater contributions. Default is 1.0, however 0.6 is recommended. However, that is relative.

-spec_static

This must be used with the -spec command line parameter and must be entered into the "Custom flags" field. Adjusts how much suns contribute to specular highlights. Higher numbers mean a greater contribution. Default is 1.0, however is 0.8 recommended. However, that is relative.

-spec_tube

This must be used with the -spec command line parameter and must be entered into the "Custom flags" field. Adjusts how much Beam Weapons contribute to specular highlights. Higher numbers mean a greater contribution. Default is 1.0, however 0.4 is recommended. However, that is relative.

-clipdist

Changes the distance from the viewpoint for the near-clipping plane.

Takes one argument decimal specifying the distance to the near-clipping plane.


Gameplay

-mod

Specifies in which folders inside Freespace2 directory, the game looks for all the game data (models, missions, textures, tables, ...). Retail version only looks inside Freespace2/data/ structure and Freespace2/vp archives.

This flag allows installing several different mods that modify retail behaviour, and switching between them without needing to erase files or having undesired cross effects. Each mod should be installed in its own folder.

It takes one argument string: the chain of names of the used directories. Comma (,) must be used as separator. In this way, -mod dir1,dir2,dir3,...,dirx causes the game to use the following directory precedence:

  1. Freespace2/dir1/
  2. Freespace2/dir2/
  3. Freespace2/dir3/
  4. ... (the rest of the typed directories) ...
  5. Freespace2/dirx/
  6. Freespace2/
Please note. Freespace Open doesn't like spaces in directories (in the full path) so do not install the game within Program Files/Freespace2 or Games/Freespace 2 and, of course, do not use spaces within mod directories (dir1 is OK but dir 1 isn't).

This flag can be indirectly set, (and it is normally set), through Launcher MOD tab and mod.ini file. Within this Launcher tab you can select one directory, (let's call it moddir), so the flag is at least set to -mod moddir. If Freespace2/moddir/mod.ini exists, (its format must be plain text), it will be read and, inside it, the following section and lines can be used to modify the -mod flag too:

[multimod]
PrimaryList = Pri1,Pri2,...(the rest of desired directories)...,Prix;
SecondaryList = Sec1,Sec2,...(the rest of desired directories)...,Secx;

(Please note the ending semicolon (;) in each list line). With these lines the following flag would be built:

-mod Pri1,Pri2,...,Prix,moddir,Sec1,Sec2,...,Secx

If primary or secondary folders aren't used, their respective line can be erased or it can be typed as xxxxxxList = ;.

PLEASE NOTE: Launcher v 5.4, or later, must be used. Earlier versions had some bugs that would cause the previous explanation about mod.ini fail.
The most common use of mod.ini and SecondaryList is sharing resources between mods. And the best example is the enhaced media vps from SCP crew. Most of the people install them in a folder called mediavps inside Freespace2. In this way when running retail FS2 they do not interfere with this original game version that doesn't use this -mod flag feature. When using FS2_Open but without mods, you just need to select mediavps in Launcher MOD tab to use them. And if you want to enjoy that enhacements while playing any 'real' mod, you just need to put a mod.ini file inside its moddir with at least a SecondaryList = mediavps; line.

Inside each directory, data precedence is the following:

  1. Individual files located in Current_dir/data/ subdir structure.
  2. Files located inside vp archives. (These vp archives are 'similar' to zip archives, they just contain other files and folders. Moreover, files have to be stored using the same data/ structure used outside it).
    Vp archives are read in alphabetical order so aaa.vp files have higher priority than aab.vp files and so on.

The highest priority file overrides the rest of them. In this way, if you have a Mission.fs2 inside Freespace2/Pri1/data/missions/ it doesn't matter how this Mission.fs2 is inside Freespace2/Pri1/aaa.vp, Freespace2/Pri1/aab.vp, ... or Freespace2/data/missions/. This data precedence allows the user to quickly replace old files by corrected or enhaced ones adding them in a higher priority place.

As derived from explanation, the exact names for directories or vp archives are actually irrelevant. It only matters the directory order inside -mod flag argument and the alphabetical order for vp archives inside each used directory.

Additional notes
  1. This flag is also used by FRED. So if there is special mod info, (like backgrounds maps, ship models or whatever), it must be typed, (Fred2_Open_r.exe -MOD whatever), or FRED won't be able to use it. No Launcher MOD tab available for this use.
  2. Be careful while typing the directory names in the flag argument or inside mod.ini files. The program doesn't check if the typed directories exist. If they do not exist, they are just ignored. No warnings, no errors, no messages at all.


VERY IMPORTANT INFO ABOUT PRIORITY AND TEXTURE FILES
FS2_Open can use several file formats in textures: PCX, DDS, JPG and TGA (the last two need the flag -jpgtga). Always update every texture keeping its format. For example if you update the old TextureOfMyFighter.tga, do not save it as TextureOfMyFighter.dds in a higher priority place, because there is a chance of the game loading the old one despite of all.
The reason to do this is that, at least in FS2_Open v3.6.9. and previous versions, loading process (including priorities) is applied firstly for a kind of textures (TGAs), then for another kind (JPGs), and so on. The exact order of this global texture type priority may change in the future but nevertheless there is always going to be a fixed loading order between them. This behaviour can lead to situation where your new, updated and higher priority placed texture is not read because the format of the older one. (An example of this situation can be found in this false Mantis Bug 1123).
The reason of this behaviour relays in the way the game looks for files. Without this way of coding, the number of file searches would hugely increase, so mission loading times would be much higher.

-fov

Specifies the Field of View for the player eyepoint.

Takes one argument decimal specifying the angle of the viewing cone in radians, from 0 to 2*pi

You can set the cone of view making things look bigger/smaller. The problem with this is that if you choose a small FOV, you will have a squashed look on the edges of your screen - stretched edges with a too high FOV. It is recommended to change the FOV as FS2 normally has some perspective distortion at the screen edges (FOV too high). Set the FOV to something like 0.39 - it will fix the distortion problem, and (as a nice side effect) will make everything look bigger and more realistic scale-wise. The default is 0.75, if you go higher, you'll get the fish-eye effect. Feel free to experiment. This must be entered into the "Custom flags" field

Because of an active bug, FOV can misalign target boxes, effects, etc. Please check Mantis bug 083 statusif you are going to change the default value. Even with the default value, (no flag), there are small distortions.


Multiplayer

-gamename

Specifies the name of the game to be created by the host. This only works when used in conjunction with -startgame.

Takes one argument string, the name to be assigned to the game being created.

This argument does nothing when used with -standalone. To set the name for a standalone server, see Standalone Servers.

See related:   -startgame   Standalone Servers

-password

Specifies the password for a stand-alone server. This only works when used in conjunction with -startgame. Cannot be used in conjunction with -closed or -restricted.

Takes one argument string, the required password for the game being created.

See related: -startgame -closed -restricted

-allowabove

Specifies a player's minimum rank for joining a game. This only works when used in conjunction with -startgame.

Takes one argument integer, the points ranking above which a player must be to enter the game.

See related: -startgame

-allowbelow

Specifies a player's maximum rank for joining a game on a stand-alone server. This only works when used in conjunction with -startgame.

Takes one argument integer, the points ranking below which a player must be to enter the game.

See related: -startgame

-port

Specifies the port on which to host a game or serve a stand-alone game.

Takes one argument integer, the port on which the host will listen for clients.

-connect

What does this do?

-timeout

What does this do?