BattleTech: FireStorm - MW4.exe command line reference
======================================================

Usage:  MW4.exe [options]

Options may appear in any order and are case-insensitive. An option that takes
a value must be followed by a single space and then the value, for example:

    MW4.exe -tmfds 4 -tmon 1,2,3,4 -tbaud 115200

Values outside the documented range are ignored and the default is kept.


DISPLAY AND VIDEO
-----------------
  -window                    Run in a window instead of fullscreen.
  -fullscreen                Force fullscreen. Overrides -window.
  -tmfds <0-4>               MFD output mode:
                               0 = no MFDs
                               1 = original 1280x480 span (5 channels + radar)
                               2 = black and white (3 channels + 1 dual)
                               3 = colour (3 channels + 2 dual)
                               4 = split dual 640x480 - drives two independent
                                   MFD monitors, so no span hardware is needed
  -tmon <m>,<r>,<f1>,<f2>    Hard-assign display devices in the order
                             main, radar, MFD1, MFD2. Values are 1-based; a
                             value of 0 leaves that slot auto-detected.
                             Separators may be ',' '/' or ':'.
                             MFD1 and MFD2 only apply with -tmfds 4.

                             These are DirectDraw device numbers. They are NOT
                             the numbers shown in Windows Display Settings, and
                             on many machines the two do not match. Do not read
                             them off the Settings screen.

                             To find the right values: launch the game once,
                             then open gos-displays.txt next to MW4.exe and read
                             the 'Desktop arrangement, left to right' list. It
                             gives each monitor's position, size and device
                             number. Add 1 to the device number for -tmon.
                             Example: -tmon 1,2,4,3 swaps the two MFD panels.
  -tident [seconds]          Identify the displays, then exit. Each monitor is
                             filled with a colour and the number to use for it
                             in -tmon. Write the numbers down, then set -tmon in
                             the order main,radar,MFD1,MFD2.
                             This is the reliable way to map the monitors: the
                             numbers Windows Display Settings shows cannot be
                             read by any program, so they cannot be trusted to
                             match. Default 20 seconds; accepts 3 to 120.
                             No display mode is changed and the game does not
                             start - it exits when the time is up.
  -tcoop <0-5>               How the radar/MFD panels claim their displays.
                             0 = legacy single call (as shipped; works on XP
                                 and under dgVoodoo2, fails on Windows 10).
                             1 = drop SETFOCUSWINDOW, let DirectDraw create
                                 the device window.
                             2 = SETFOCUSWINDOW first, then CREATEDEVICEWINDOW.
                             3 = SETFOCUSWINDOW first, then EXCLUSIVE only,
                                 matching what the main display already does.
                             4 = EXCLUSIVE|FULLSCREEN only. The main display
                                 has already set the focus window, so the
                                 panels never contend for it.
                             5 = as 4, plus ALLOWREBOOT.
                             Results are reported in gos-displays.txt.
  -tmr <0-3>                 Cameraship Map/Armor screen diagnostics.
                             0 = normal.
                             1 = wait for the background blit to finish before
                                 drawing the overlays.
                             2 = skip the background image entirely.
                             3 = as 2, plus a solid magenta test rectangle.
                             Use when that screen shows its background but no
                             overlay graphics or text.
  -mechview <1|2>            Show the rotating mech view. 1 = on the radar
  -mv <1|2>                  screen, 2 = on the main screen. Default: off.
  -3dt                       Draw the MFD target as a live 3D model instead of
                             the pre-rendered 2D bitmaps.
  -capdev <0-7>              Select which device screen captures come from:
                               0 main, 1 radar, 2 mission review, 3 hudchat,
                               4 nav, 5 weapon, 6 target, 7 armor


AUDIO AND PLASMA DISPLAY
------------------------
  -nosound                   Disable all sound output.
  -noplasma                  Disable the COM2 plasma score display.
  -pctime <seconds>          Plasma display clear time. Minimum 3.


POD HARDWARE AND ARCADE (CTCL)
------------------------------
  -ctcltype <1-3>            CTCL role for this machine:
  -ctcl <1-3>                  1 = console, 2 = game pod, 3 = cameraship.
                             Default when absent: console.
                             A cameraship MUST use 3. With 2 its Map/Armor
                             screen still opens and paints its background, but
                             draws no overlays at all, which looks like a video
                             card fault. The role in use is reported in
                             gos-displays.txt as 'CTCL type ='.
  -dragon                    Disable CTCL entirely and run standalone.
  -coop                      Co-operative arcade mode. Implies 1 coin per game
                             and the game-pod role.
  -#coop <coins>             Co-op with an explicit coin count. A negative
                             value selects the cameraship role instead.
  -trio <0|1>                RIO cockpit board protocol. 0 = original board,
                             1 = newer protocol (different framing and acks).
  -tbaud <9600-921600>       Force the COM1 baud rate for the RIO board. Use
                             for replica boards with a high-speed UART. The
                             wire protocol is unchanged; only the rate differs.
  -useorgjoy                 Use the original joystick axis mapping.
  -ojoy                      Same as -useorgjoy.
  -usetockeys                Enable TOC keys. They are disabled by default.
  -tocadt <seconds>          TOC auto-detect timeout. Minimum 5.
  -auxadt <seconds>          AUX auto-detect timeout. Minimum 3.
  -usecam                    Force camera mode. Implied by the cameraship role.
  -suicide                   Allow self-destruct at any time.
  -jpd                       Enable JPD input handling.


ZOOM AND FIELD OF VIEW
----------------------
  -zmfova <0.01-0.5>         Zoom field-of-view, stage A.
  -zmfovb <0.01-0.5>         Zoom field-of-view, stage B. A and B are swapped
                             automatically so that A is the wider of the two.
  -zmmrgn <0.01-0.49>        Zoom left/right margin, as a fraction of width.
  -zmtime <0, or 0.05-3.0>   Zoom transition time in seconds. 0 = instant.


MULTIPLAYER AND NETWORK
-----------------------
  -serve                     Automatically host a server game on startup.
  -lobby                     Indicates the game was started from a lobby.
  -game <file>               Load the named game/mission file.
  -gamename <name>           Name advertised for the hosted game.
  -playername <name>         Player name to use.
  -password <password>       Password for the hosted or joined game.
  -advertiseport <port>      Port used to advertise the server.
  -ipx                       Use IPX in the server browser.
  -nodplay                   Disable DirectPlay networking.
  -directplayprotocol        Force use of the DirectPlay protocol.
  -secure                    Enable secure networking for the game session.
  -set_internet              Configure network settings for internet play.
  -set_lan                   Configure network settings for LAN play.
  -win32dedicated            Run as a Win32 dedicated server. Disables sound
                             and rendering and uses the dedicated server UI.
  -allowmultiple             Allow more than one instance of the game to run.
  -oldmpui                   Use the older multiplayer user interface.


LOGGING AND DIAGNOSTICS
-----------------------
  -zlogstyle <value>         ZLog output style.
  -zlogflush <value>         ZLog flush behaviour.
  -zlogbuffer <size>         ZLog buffer size.
  -zlogname <filename>       ZLog output file name.
  -olog                      Write the legacy .log match report instead of the
                             newer .rpt format.
  -fps                       Write a per-second frame pacing report to
                             gos-fps.txt next to the executable: average fps,
                             5% low, worst frame in ms, and a count of frames
                             taking over twice the average (hitches). A summary
                             written at exit gives the whole-session 1% and
                             0.1% lows. Useful for confirming smooth pacing on
                             the MFD modes. Off unless this switch is given.
  -gamestats                 Save game statistics.
  -help                      Show this reference and exit without starting.


DEVELOPMENT AND TEST BUILDS
---------------------------
The following are only active in LAB (Debug, Armor and Profile) builds. In a
Release build they are accepted and ignored.

  -build                     Rebuild the resource packages at startup.
  -norun                     Do not run the game after building.
  -demo                      Demo mode.
  -rekey                     Re-key resources.
  -bloat                     Enable bloat diagnostics.
  -reportnotresourced        Report assets that are not in a resource package.
  -armorlevel <0-4>          Assertion/armor checking level.
  -leak <n>                  Memory trace level.
  -diskfirst                 Prefer loose files on disk over packaged data.
  -testclasses               Run internal class self-tests.
  -aistats                   Enable AI statistics collection.
  -bspmap                    Save BSP map differences.
  -showscripterrors          Display script errors as they occur.
  -mrtest                    Mission review test mode.
  -prtest                    Print report test mode.
  -nowrc                     Disable weapon range checking.
  -regs                      Debug builds only: enable script regions.
  -spew                      Debug builds only: enable script spews.


OTHER
-----
  -nocd                      Skip the CD check. (The CD check is already
                             disabled unconditionally in this build.)
  -noeula                    Skip the end user licence agreement screen.
  -noautoconfig              Skip automatic video and sound configuration.


RECOGNISED BUT INACTIVE
-----------------------
  -join                      Parsed for compatibility but has no effect; the
                             code that consumed it is commented out.
  -noabzug                   Parsed only in a disabled code path.


RELATED CONFIGURATION
---------------------
Most persistent settings live in options.ini next to MW4.exe rather than on the
command line. See OPTIONS-INI.md in the source repository for a full reference.
Arcade pod assignments live in c:\ctcl.ini.
