User Tools

Site Tools


client:optional_parameters

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
client:optional_parameters [2018/03/10 06:36]
karl created
client:optional_parameters [2018/04/17 21:39] (current)
karl [-mapsize] Add pics about mapsizes
Line 1: Line 1:
 ====== Crossfire Client launch Options ====== ====== Crossfire Client launch Options ======
  
-The default Crossfire x11, gtk, gtk-v2 [[:client]] recognizes the following parameters or arguments when it starts ​:+The default Crossfire x11, gtk, gtk-v2 [[:client]] recognizes the following parameters or arguments when it starts.  
 + 
 +See also the [[man6_cfclient_6_manualpage|manpage]] and the [[gdefaults]] configuration file. 
  
 ==== -cache ==== ==== -cache ====
-      ​- Cache images for future use.+Short: ​     ​- Cache images for future use. 
 + 
 +gdefaults Entry: [[gdefaults#​cacheimages]] 1 
 ==== -nocache ==== ==== -nocache ====
-      ​- Do not cache images (default action).+Short: ​     ​- Do not cache images (default action). 
 + 
 +gdefaults Entry: [[gdefaults#​cacheimages]] 0 
 + 
 +==== -keepcache ==== 
 +Short: ​     - Keep already cached images even if server has different ones. 
 + 
 +X11 cfclient only. 
 ==== -darkness ==== ==== -darkness ====
-      ​- Enables darkness code (default)+Short: ​     ​- Enables darkness code (default) 
 + 
 +In length: Each of the three crossfire clients have their own map drawing code. \\ 
 +Variables are //​CONFIG_DARKNESS//​ , //​the_map.cells[mx][my].have_darkness//​ , //​the_map.cells[mx][my].darkness//​ and  //​CONFIG_FOGWAR//​ .  
 +  - **X11** cfclient: Function //​display_mapcell()//​ in //​client/​x11/​x11.c//​  
 +    * seems to do something ... 
 +  - **GTK-1** gcfclient: Function //​display_mapcell()//​ in //​client/​gtk/​map.c//​ just uses //​CONFIG_FOGWAR// ​    
 +    *and draws //​the_map.cells[mx][my].darkness//​ anyway ...  
 +  - **GTK-2** gcfclient2: Functions //​opengl_gen_map()//​ and //​opengl_light_space()//​ in //​client/​gtk-v2/​src/​opengl.c//​  
 +    * are using it in a larger scale with code disabled by //#if 0// . 
 + 
 +Basically: Works (partly) for x11 cfclient and gtk2 gcfclient2 in [[#​-opengl]] mode, but does not do anything supplied to the gtk-1 gcfclient . \\ 
 +In [[#-sdl]] mode, this commandline option will have no effect at all. 
 + 
 +gdefaults Entry: [[gdefaults#​darkness]] 1 
 ==== -nodarkness ==== ==== -nodarkness ====
-      ​- Disables darkness code +Short: ​     ​- Disables darkness code 
-==== -display ​<​name> ​==== + 
-      - Use <​name>​ instead if DISPLAY environment variable.+gdefaults Entry: [[gdefaults#​darkness]] 0 
 + 
 +==== -display ==== 
 +Short: ​ -display <​name> ​    - Use <​name>​ instead if DISPLAY environment variable. 
 ==== -download_all_faces ==== ==== -download_all_faces ====
-      ​- Download all needed faces before play starts+Short: ​     ​- Download all needed faces before play starts 
 + 
 +gdefaults Entry: [[gdefaults#​download_all_images]] 1 
 ==== -echo ==== ==== -echo ====
-       - Echo the bound commands+Short: ​      - Echo the bound commands 
 + 
 +gdefaults Entry: [[gdefaults#​echo_bindings]] 1 
 ==== -noecho ==== ==== -noecho ====
-       - Do not echo the bound commands (default) +Short: ​      - Do not echo the bound commands (default) 
-==== -faceset ​<​name> ​==== + 
-       ​- Use faceset <​name>​ if available+gdefaults Entry: [[gdefaults#​echo_bindings]] 0 
 + 
 +==== -faceset ==== 
 +Sort: -faceset <​name> ​       ​- Use faceset <​name>​ if available ​\\ 
 +Names : classic | standard 
 + 
 +gdefaults Entry: [[gdefaults#​faceset]] 
 + 
 +The X11 cfclient does not use <​name>​ as argument, but <​number>​ ( likely 0 and 1 for classic and standard ) . 
 ==== -fasttcpsend ==== ==== -fasttcpsend ====
-     - Send data immediately to server, may increase bandwidth+Short: ​    - Send data immediately to server, may increase bandwidth 
 + 
 +gdefaults Entry: [[gdefaults#​fasttcpsend]] 1 
 ==== -nofasttcpsend ==== ==== -nofasttcpsend ====
-     - Disables fasttcpsend+Short: ​    - Disables fasttcpsend 
 + 
 +gdefaults Entry: [[gdefaults#​fasttcpsend]] 0 
 ==== -fog ==== ==== -fog ====
-      ​- Enable fog of war code+Short: ​     ​- Enable fog of war code 
 + 
 +gdefaults Entry: [[gdefaults#​fog_of_war]] 1 
 ==== -help ==== ==== -help ====
-      ​- Display this message. +Short: ​     ​- Display this message. 
-==== -iconscale ​%% ==== + 
-      - Set icon scale percentage +==== -iconscale ==== 
-==== -mapscale ​%% ==== +Short: ​ -iconscale % %    ​- Set icon scale percentage 
-      - Set map scale percentage + 
-==== -mapsize ​xXy  ​==== +gdefaults Entry: [[gdefaults#​iconscale]] 
-      - Set the mapsize to be X by Y spaces. ​(default 11x11)+ 
 +==== -loglevel ==== 
 +Short: -loglevel <​val> ​ - Set default logging level (0 is most verbose) \\ 
 +Description:​ The client has 5 logging levels as **0-4** . In opposite to the [[:server]] \\ 
 +that has just 4 logging levels, they are less talk-active when set to a high value. \\  
 +[[gdefaults]] Entry: No \\ 
 +Default : //​common/​config.h//​ /* Default logging level. */ #define MINLOGLEVEL 0 \\ 
 +Defines: //​common/​client.h//​ , //​common/​misc.c//​ 
 +<code c> 
 +typedef enum LogLevel { 
 +  LOG_DEBUG = 0, LOG_INFO = 1, LOG_WARNING = 2, LOG_ERROR = 3, LOG_CRITICAL = 4 
 +} LogLevel; 
 +</​code>​ 
 +<code c> 
 +static const char *const LogLevelTexts[] = { 
 +    " DEBUG  ", 
 +    " ​ INFO  ", 
 +    "​WARNING ", 
 +    " ERROR  ", 
 +    "​CRITICAL",​ 
 +    "​UNKNOWN ", 
 +}; 
 +</​code>​ 
 +Functions: //​common/​misc.c//​ 
 +  * void LOG(LogLevel level, const char *origin, const char *format, ...) 
 +  * char *getLogText(const LogEntry *le) 
 +  * char *getLogTextRaw(LogLevel level, const char *origin, const char *message) 
 +  * static const char *getLogLevelText(LogLevel level) 
 +    * return LogLevelTexts[level>​LOG_CRITICAL?​LOG_CRITICAL+1:​level];​ 
 + 
 +==== -mapscale ==== 
 +Short: -mapscale % %    ​- Set map scale percentage. \\ 
 +Default: 100 \\ 
 +Range: (float) 25 - 200 \\ 
 +Syntax: -mapscale 70 | -mapscale 70% \\ 
 +gdefaults Entry: [[gdefaults#​mapscale]] \\ 
 +Description:​ Make tiles, players, items on maps appear smaller or larger. \\ 
 +Useful to chose smaller percentages when using a large [[#​-mapsize]] . 
 + 
 +Source Code files and functions : 
 +  * gtk-v2/​src/​main.c 
 +    * parse_args() 
 +  * gtk-v2/​src/​config.c 
 +    * setup_config_window() 
 + 
 +gdefaults Entry: [[gdefaults#​mapscale]] 
 + 
 +==== -mapsize ==== 
 +Short: -mapsize xXy     - Set the mapsize to be X by Y spaces. ​\\ 
 +gdefaults Entries: [[gdefaults#​map_width]] , [[gdefaults#​map_height]] \\ 
 +Default: gtk1: 11x11; gtk-2: old 15x15, new 25x25 
 + 
 +For a new installation of the GTK-1 client without any configuration files, the default ​map size of 11x11 might lead to a slightly distorted GUI. \\ 
 +''​-mapsize 9x9''​ might be a better first impression without stat bars / resistances column overlapping the bottom of the map: 
 + 
 +^ mapsize default ^ mapsize 9 x 9 ^ 
 +| {{gcfclient_mapsize_default.jpg?​350}} | {{gcfclient_mapsize_9x9.jpg?​350}} | 
 + 
 + 
 + 
 + 
 + 
 ==== -mapscroll ==== ==== -mapscroll ====
-      - Enable mapscrolling by bitmap operations+Short: ​Enable mapscrolling by bitmap operations ​\\ 
 +Used only in [[#​-sdl|SDL]] map display mode. \\ 
 +Clients that understand this option : x11 //​cfclient//​ and gtk-1 //​gcfclient//​. The gtk-v2 client throws the [[#-help]] message and exits. \\ 
 +Purpose: UNKNOWN \\ 
 +        /* Mark all tiles as "​need_update"​ that are overlapped by a big face  
 +         * from outside the view area. */  
 +Default : TRUE ( apparently ) \\ 
 + 
 +Client Menu entry : UNKNOWN \\ 
 +Bugs : x11/x11.c: Fix display_mapscroll() to handle scrolling by greater than 1 tile at a time. Fixes bug #1564584. \\ 
 +Implemented : x11/x11.c: Implement map scrolling by using XCopyArea(). Add config options -mapscroll/​-nomapscroll to enable/​disable this. //​2005-08-31//​ 
 + 
 +Defines: common/​client.h  
 +  * #define CONFIG_MAPSCROLL ​   29      /* Use bitmap operations for map scrolling */ 
 +  * #define CONFIG_NUMS ​    ​32 ​     /* This should always be the last value in the list */ 
 +Functions :  
 +  * init_client_vars in //​comon.init.c//​ , calls want_config[CONFIG_MAPSCROLL] = TRUE; 
 +  * display_mapscroll in //​gtk/​map.c//​ , returns either 0 or sdl_mapscroll,​ called by //​mapdata_scroll//​ in //​common/​mapdata.c//​ 
 +  * sdl_mapscroll in //​gtk/​sdl.c//​ , returns always '​1'​ , called by //​display_mapscroll//​  
 + 
 +gdefaults Entry: [[gdefaults#​mapscroll]] 1 
 ==== -nomapscroll ==== ==== -nomapscroll ====
-      - Disable mapscrolling by bitmap operations+Short: ​Disable mapscrolling by bitmap operations 
 + 
 +Function //​common/​mapdata.c//​ mapdata_scroll says: ''/​* Emulate map scrolling by redrawing all tiles. */''​ 
 + 
 +gdefaults Entry:​[[gdefaults#​mapscroll]] 0 
 + 
 +==== -noautorepeat ==== 
 +Short: ​ - Auto repeat on directional keys is ignored. 
 + 
 +X11 cfclient only. 
 + 
 +==== -opengl ==== 
 +Short: ​     - Use opengl drawing code 
 + 
 +gdefaults Entry: [[gdefaults#​displaymode]] 2 
 + 
 +Only available for the GTK-2 client. 
 + 
 + 
 +Though the OpenGL drawing mode apparently works even without the GLX extension switched on for the XServer, \\ 
 +the older GTK-2 clients will crash at startup if the GLX extension would be not available:​ 
 +<code bash> 
 +# gcfclient2-1.10.0 -opengl 
 +Xlib:  extension "​GLX"​ missing on display ":​0.0"​. 
 +Segmentation fault 
 +</​code>​ 
 + 
 +The newer GTK-2 clients will work still, if the necessary libraries ''​libGL.so.1''​ , ''​libGLU.so.1''​ and ''​libglut.so.3''​ are available on the system: 
 +<code bash> 
 +# crossfire-client-gtk2-1.70.0 -opengl 
 +[  INFO  ] (gtk-v2::​init_glx_opengl) Direct rendering is not available! 
 +[  INFO  ] (gtk-v2::​opengl_common) Maximum texture size is 2048 
 +[  INFO  ] (gtk-v2::​init_image_cache_data) Init Image Cache 
 +</​code>​ 
 + 
 +When OpenGL had not been available at [[client compiling]] time, then the client will fall back to Pixmap mode, and prints to stderr 
 +<code bash> 
 +# crossfire-client-gtk2-1.70.0 -opengl 
 +[WARNING ] (main.c::​init_windows) client not compiled with opengl support. ​ Ignoring -opengl 
 +</​code>​ 
 + 
 + 
 +==== -pixmap ==== 
 +Short: ​     - Use pixmap drawing code 
 + 
 +gdefaults Entry: [[gdefaults#​displaymode]] 0 
 + 
 +Only available for the GTK-2 client. 
 ==== -popups ==== ==== -popups ====
-      ​- Use pop up windows for input (default)+Short: ​     ​- Use pop up windows for input <del>(default)</​del>​ \\ 
 +Result: Many messages, that normally occur in the info message pane, now are shown in separate popping up windows; like book entries and the login. \\ 
 +Reality: The [[#-help]] message claims, that popup would be the default, but that is apparently not true. \\ 
 +The default is set to **0** inside the source code \\ 
 +in function //​init_client_vars()//​ in file //​common/​init.c//​ as variable ''​want_config[CONFIG_POPUPS] = FALSE;''​ since version 1.10.0 .\\ 
 +See also ChangeLog entry : [[changelog_0_92_1_70_0#​Popups not the default anymore]] 
 +  
 +gdefaults Entry: [[gdefaults#​popups]] 1 
 + 
 +The GTK-v1 gcfclient when configured to partly use GTK-2 features by the ''​-–enable-cfgtk2''​ configure option, had a bug in the 1.9.1, 1.10.0 and 1.11.0 versions, that made new players impossible to log-on to a crossfire [[:server]] , because a log-in required the popup-login-GUI to function. 
 + 
 +See also  
 +  * ChangeLog [[changelog_0_92_1_70_0#​Keyboard input impossible or confusing]] 
 +  * ChangeLog [[changelog_0_92_1_70_0#​Popups @ v.1.12.0 client GTK1 mixed with GTK2 can not login]] 
 +  * known_client_issues [[:​known_client_issues#​Keyboard input impossible or confusing]] 
 +  * bugs [[bugs#​Pressing a keyboard key activates the command-line]]  
 + 
 ==== -nopopups ==== ==== -nopopups ====
-      ​- Don't use pop up windows for input +Short: ​     ​- Don't use pop up windows for input 
-==== -port <​number> ​==== + 
-      - Use port <​number>​ instead of the standard port number +gdefaults Entry: [[gdefaults#​popups]] 0 
-==== -resists ​<val> ==== + 
-      - Control look of resistances.  ​+==== -port ==== 
 +Short: -port <​number> ​      - Use port <​number>​ instead of the standard port number 
 + 
 +gdefaults Entry: [[gdefaults#​port]] 13327 
 + 
 +==== -pngfile ==== 
 +Short: -pngfile ​<name - Use <​name>​ for source of images 
 + 
 +X11 cfclient only. 
 + 
 +==== -resists ​==== 
 +Short: -resists <​val> ​     - Control look of resistances.  ​ 
 + 
 +gdefaults Entry: [[gdefaults#​resistances]] 
 + 
 +GTK-1 client gcfclient only. 
 + 
 +==== -scrolllines ==== 
 +Short: -scrolllines <​number> ​   - number of lines for scrollback \\ 
 +Default: #define INFOLINES 36 in //​client/​x11/​x11.c//​ 
 + 
 +X11 cfclient only. \\ 
 +This default value of 36 is much too small when identifying many books at once. 
 ==== -sdl ==== ==== -sdl ====
-      ​- Use sdl for drawing png (may not work on all hardware +Short: ​     ​- Use sdl for drawing png (may not work on all hardware 
-==== -server ​<​name> ​==== + 
-      - Connect to <​name>​ instead of localhost.+gdefaults Entry: [[gdefaults#​displaymode]] 1 
 + 
 +==== -server ==== 
 +Short: -server <​name> ​      - Connect to <​name>​ instead of localhost. 
 + 
 +gdefaults Entry: [[gdefaults#​server]] 
 ==== -showicon ==== ==== -showicon ====
-      ​- Print status icons in inventory window+Short: ​     ​- Print status icons in inventory window 
 + 
 +gdefaults Entry: [[gdefaults#​showicon]] 1 
 ==== -smooth ==== ==== -smooth ====
-      ​- Enable smooth+Short: ​     ​- Enable smooth 
 + 
 +gdefaults Entry: [[gdefaults#​smoothing]] 1 
 + 
 +If one likes it ... Wolfsburg harbour quays and Stoneville north-east ... \\ 
 +{{smooth-dmode0-wolfsburg_beach.jpg}} {{smooth_stoneville_countryside2.jpg}}
 ==== -nosmooth ==== ==== -nosmooth ====
-      ​- Disable smooth+Short: ​     ​- Disable smooth 
 + 
 +gdefaults Entry: [[gdefaults#​smoothing]] 0 
 ==== -sound ==== ==== -sound ====
-      ​- Enable sound output (default).+Short: ​     ​- Enable sound output (default). ​\\ 
 +Description:​ The crossfiire client uses an external sound server binary, \\ 
 +launched through the //​init_sounds()//​ function. \\ 
 +The sound serer is the only external program launched by the client. \\ 
 +The code is in the function //​raiseChild()//​ found in //​client/​common/​misc.c//​ . \\ 
 +The LOG function prints to standard error : 
 +>>>​[ ​ INFO  ] (common::​raiseChild) Raising /​usr/​local/​bin/​cfsndserv with flags 7 
 + 
 +gdefaults Entry: [[gdefaults#​sound]] 1 
 ==== -nosound ==== ==== -nosound ====
-      ​- Disable sound output. +Short: ​     ​- Disable ​[[:​client:​sound:​sound_howto|sound]] output. ​\\ 
-==== -sound_server ​<​path> ​====  +Description:​ The client uses an external soundserver binary, usually the cfsndserv . This sound server gets raised by the function //​init_sounds()//​ in the source file //​client/​gtk-v2/​src/​sound.c//​ . \\ 
-      - Executable to use to play sounds.+The function would return early if ''​if (!want_config[CONFIG_SOUND]) return -1;''​ . 
 + 
 +Comment in the source code : 
 +<code c> 
 +    /* Easy trick - global nosound is set in the arg processing - if set, just 
 +     * return -1 - this way, the calling function only needs to check the value 
 +     * of init_sounds,​ and not worry about checking nosound. 
 +     */ 
 +</​code>​ 
 +Benefits: The cfsndserv binary blocks the audio device for other users. \\ 
 +It is therefore likely desirable to disable the usage of that child process, \\ 
 +when there are other sound programs running in parallel.  
 + 
 +gdefaults Entry: [[gdefaults#​sound]] 0 
 + 
 +==== -sound_server ====  
 +Short: -sound_server <​path> ​- Executable to use to play sounds. 
 + 
 +gdefaults Entry: [[gdefaults#​sound_server]] 
 ==== -splash ==== ==== -splash ====
-      ​- Display the splash screen (startup logo) (default)+Short: ​     ​- Display the splash screen (startup logo) (default) 
 + 
 +gdefaults Entry: [[gdefaults#​nosplash]] 0 
 ==== -nosplash ==== ==== -nosplash ====
-      ​- Don't display the splash screen ​+Short: ​     ​- Don't display the splash screen ​ 
 + 
 +gdefaults Entry: [[gdefaults#​nosplash]] 1 
 ==== -split ==== ==== -split ====
-      ​- Use split windows.+Short: ​     ​- Use split windows. 
 + 
 +gdefaults Entry: [[gdefaults#​split]] 
 ==== -splitinfo ==== ==== -splitinfo ====
-      ​- Use two information windows, segregated by information type.+Short: ​     ​- Use two information windows, segregated by information type. 
 + 
 +gdefaults Entry: [[gdefaults#​splitinfo]] 
 + 
 +==== -sync ==== 
 +Short: ​      - Synchronize on display 
 + 
 +X11 cfclient only. 
 ==== -timemapredraw ==== ==== -timemapredraw ====
-      ​- Print out timing information for map generation+Short: ​     ​- Print out timing information for map generation 
 ==== -triminfowindow ==== ==== -triminfowindow ====
-      ​- Trims size of information window(s)+Short: ​     ​- Trims size of information window(s) 
 ==== -notriminfowindow ==== ==== -notriminfowindow ====
-      ​- Do not trims size of information window(s) (default)+Short: ​     ​- Do not trims size of information window(s) (default) 
 ==== -updatekeycodes ​ ====  ==== -updatekeycodes ​ ==== 
-      ​- Update the saved bindings for this keyboard.+Short: ​     ​- Update the saved bindings for this keyboard.
  
client/optional_parameters.1520685412.txt.gz · Last modified: 2018/03/10 06:36 by karl