File: commandline.html

package info (click to toggle)
assaultcube-data 1.0.4%2Brepack1-1
  • links: PTS, VCS
  • area: non-free
  • in suites: squeeze
  • size: 60,024 kB
  • ctags: 15,165
  • sloc: cpp: 34,920; ansic: 20,515; xml: 3,864; sh: 3,408; objc: 975; cs: 350; makefile: 146
file content (623 lines) | stat: -rw-r--r-- 23,180 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" >
<html lang="en" xml:lang="en" xmlns:h="http://www.w3.org/1999/xhtml" xmlns="http://www.w3.org/1999/xhtml">
<head>
    <title>Command-line arguments </title>
    <meta http-equiv="content-type" content="application/xhtml+xml;charset=utf-8" />
    <link rel="shortcut icon" href="pics/favicon.ico" />
    <link rel="stylesheet" href="styles/cubedoc.css" />
</head>
<body>
    <div id="main">
        <div id="logo">
            <img src="pics/head.gif" alt="AssaultCube logo" />
        </div>
        <div id="title">
            <h1>
                AssaultCube: Command-line arguments
            </h1>
        </div>
        <div id="content">
            <h1>
                Command-line arguments
            </h1>
            <p>
                When launching AssaultCube, irrespective of operating system, a small script is used.
				These script files can be modified with "switches" to allow different
                settings to occur on startup.
				<br clear="none" /><b>Note:</b> Some of these options can be changed in-game
                through the menus without the need to manually edit the script file.
            </p>
			<h3>Contents:</h3>
			<ul>
				<li>
					HowTo: <a href="#launcher">Editing the AssaultCube launcher</a>
				</li>
				<li>
					<a href="#clientswitch">Client switches</a>
				</li>
				<li>
					<a href="#serverswitch">Server switches</a>
				</li>
			</ul>
            <h2 id="launcher">
                HowTo: Editing the AssaultCube launcher
            </h2>

			<table>
				<tr>
                    <td width="50" rowspan="1" colspan="1">
                        <img src="pics/vista.png" alt="Windows" />
                    </td>
                    <td rowspan="1" colspan="1">
                        <b>Microsoft Windows</b>
                        <br clear="none" />
						<p>
							In the AssaultCube folder, there is a file named "<i>assaultcube.bat</i>". Right
							click this and open it with "notepad" to edit the clients launcher.
							Also, after using the server wizard, in this folder will be "<i>server_autoconfigured.bat</i>".
							Right click this and open it with "notepad" to edit the servers launcher.
						</p>
						<p>
							All switches are placed after the phrase: <span class="code">bin_win32\ac_client.exe</span>
							<br clear="none" />
							If you're editing the client, you'll need to add it before the phrase: <span class="code">
							%1 %2 %3 %4 %5</span>
						</p>
						<p>
							Remember to save once you're finished!
						</p>
                    </td>
                </tr>

				<tr>
                    <td width="50" rowspan="1" colspan="1">
                        <img src="pics/linux.png" alt="Linux" />
                    </td>
                    <td rowspan="1" colspan="1">
                        <b>Linux</b>
                        <br clear="none" />
						<p>
							In the AssaultCube folder, there is a file named "<i>assaultcube.sh</i>". Open it
							with your favourite text editor, such as Gedit, Nano, etc. to edit the clients launcher.
							<br clear="none" />
							Also, after using the server wizard, in this folder will be "<i>server_autogenerated.sh</i>".
							Open it with your favourite text editor to edit the servers launcher.
						</p>
						<p>
							All switches for the client must be put inside the quote marks on this line: <span
							class="code">CUBE_OPTIONS="--home=${HOME}/.assaultcube --init"</span>
						</p>
						<p>
							All switches for the server must be placed after the phrase: <span class="code">./server.sh</span>.
						</p>
			            <p>
							Remember to save once you're finished!
						</p>
					</td>
				</tr>

				<tr>
                    <td width="50" rowspan="1" colspan="1">
                        <img src="pics/apple.png" alt="Apple Mac OS X" />
                    </td>
                    <td rowspan="1" colspan="1">
                        <b>Apple Mac OS X</b>
                        <br clear="none" />
						<p>
							After starting the AssaultCube launcher, under the "main" tab of the AssaultCube
							launcher is an "Advanced options" bar. <br clear="none" />
							You can type all the switches you need for the client into there.<br clear="none" />
							Also, under the "server" tab of the AssaultCube launcher is an "Advanced options"
							bar. You can type all the switches you need for the server into there.<br clear="none" />
						</p>
					</td>
				</tr>
			</table>

            <h2 id="clientswitch">Client switches</h2>
            <p>
				These variables are specifically for the clients launcher, not the server.
				Switches are case-sensitive!
			</p>
			<table>
				<tr>
					<td width="120" style="text-align: center;">
						<span class="codecommandline">-w</span>X
					</td>
					<td>
						Sets desired screen width to X, default is <span class="code">-w1024</span>.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-h</span>Y
					</td>
					<td>
						Sets desired screen height to Y, default is <span class="code">-h768</span>.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-t</span>
					</td>
					<td>
						Runs AssaultCube in windowed mode (fullscreen off). Using -t1 you can explicitly force fullscreen mode.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-z</span>N
					</td>
					<td>
						Sets the z-buffer precision to N bits. This should be at least 24
						or you may experience depth problems.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-b</span>N
					</td>
					<td>
						Sets the screen to N bits per pixel.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-s</span>N
					</td>
					<td>
						Sets the stencil buffer precision to N bits. This should be 8 to enable
						shadowing effects, or 0 to turn it off (the default).
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-a</span>N
					</td>
					<td>
						Sets FSAA (Full Scene AntiAliasing) to N samples (i.e. -a4 is 4xFSAA).
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-v</span>N
					</td>
					<td>
						Enables vsync if N is greater 0.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-m</span>M
					</td>
					<td>
						Sets the client to update itself against masterserver M.
						M is the base url of the master server and has to end in a / and without a
						http:// prefix, the default is masterserver.cubers.net/cgi-bin/AssaultCube.pl/
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">--init</span>
					</td>
					<td>
						Executes the init script before starting the graphics
						and sound subsystems (recommended). By default the script <i>config/init.cfg</i>
						is used, but you can override this setting by using <i>--init=yourfile.cfg</i>
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span id="mods" class="codecommandline">--mod=</span>PATH
					</td>
					<td>
						Adds the specified path to the list of directories
						that are searched when loading resources. Use this to add your own mods in a clean
						way without placing files into the main directory.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">--home=</span>PATH
					</td>
					<td>
						Specifies the home directory for the user profile, AssaultCube will write
						custom settings and files to this directory (recommended).
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-T</span>
					</td>
					<td>
						Add timestamp to every console log line.
         </td>
				</tr>

			</table>

            <h2 id="serverswitch">Server switches</h2>
            <p>
				These variables are specifically for the servers launcher, not the client.
				Switches are case-sensitive.
			</p>
			<table>
				<tr>
					<td style="text-align: center;vertical-align: top;" width="120">
						<span class="codecommandline">-d</span>
					</td>
					<td>
						This starts an AssaultCube client binary as a dedicated server. The
						default is a non-dedicated server with only a single client in graphical mode.
						See the <a href="server.html" shape="rect">Server Section</a>.
						You don't need this parameter, if you're using the server binary.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-u</span>N
					</td>
					<td>
						Sets the server upstream bandwidth (per player) to N bytes per
						second. only set this parameter if you know what you are doing, specifying a wrong
						value is worse than not specifying it at all.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span id="serverdesc" class="codecommandline">-n</span>S
					</td>
					<td>
						Sets the server description, for people pinging the server. This usually does not need to
						be set if you have a descriptive domain name already, but if you set it, keep it short
						as it may otherwise be truncated, i.e. -nBobsInstagibServer
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-n1</span>S
					</td>
					<td>
						Sets a server description prefix.
					</td>
				</tr>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-n2</span>S
					</td>
					<td>
						Sets a server description suffix.
					</td>
				</tr>
				<tr>
					<td></td>
					<td>
						To enable the admin to temporarily change the server description, a server description prefix
						and/or suffix needs to be set. If the admin executes the command <span class="code">/serverdesc DESC</span>,
						the server description will be changed to "prefixDESCsuffix".
						At the end of the game, the default server description (set by
						<span class="code"><a href="#serverdesc">-n</a></span>) is restored automatically.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-i</span>IP
					</td>
					<td>
						Sets the server ip to IP. This option is only useful
						for people running servers on machines with multiple network interfaces.
						Only use this switch if you really know, what you are doing.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-f</span>PORT
					</td>
					<td>
						Sets the server base port to PORT. An AC server always uses 2 UDP ports: PORT & PORT+1.
						The default ports are 28763 and 28764. You need to use different ports, if you want to
						run several servers on the same machine (with one IP address). For example, use
						<span class="code">-f28765</span> for a second server.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-N</span>ID
					</td>
					<td>
						Sets the log identity to ID. By default, the log identity is 'IP[port]'. On linux systems,
						the log identity is used for the syslog to identify server log entries. On windows and
						apple systems, the log identity is used to create the server logfile filename.
         </td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-F</span>n
					</td>
					<td>
						Sets the syslog facility to n. Values from 0 to 7 are allowed to use the facilities
						local0..local7. By default, local6 is used. For further information, check the
						documentation of your installed syslog deamon.
         </td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-T</span>
					</td>
					<td>
						Add timestamps to every line of the console and file logs.
         </td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-LF</span>n
					</td>
					<td>
						Sets the logging level for file logs to level <i>n</i>. On linux systems, this switch can be used to enable (additional) file logging.<br clear="none" />
						The following levels can be selected:
						<table>
						<tr><td>0</td>
						<td>DEBUG: logs all messages</td></tr>
						<tr><td>1</td>
						<td>VERBOSE: logs all messages of level VERBOSE and above (same as console log, when using the -V switch)</td></tr>
						<tr><td>2</td>
						<td>INFO: logs all messages of level INFO and above (same as console without -V switch), default on windows or mac systems</td></tr>
						<tr><td>3</td>
						<td>WARNING: log only messages of level WARNING and above</td></tr>
						<tr><td>4</td>
						<td>ERROR: log only messages of level ERROR</td></tr>
						<tr><td>5 (or above)</td>
						<td>do not log to file (default on linux systems)</td></tr>
						</table>
         </td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-LS</span>n
					</td>
					<td>
						Sets the logging level for syslog logging to level <i>n</i>. This switch is ignored on non-linux systems.<br clear="none" />
						The following levels can be selected:
						<table>
						<tr><td>0</td>
						<td>DEBUG: logs all messages</td></tr>
						<tr><td>1</td>
						<td>VERBOSE: logs all messages of level VERBOSE and above (same as console log, when using the -V switch)</td></tr>
						<tr><td>2</td>
						<td>INFO: logs all messages of level INFO and above (same as console without -V switch), default</td></tr>
						<tr><td>3</td>
						<td>WARNING: log only messages of level WARNING and above</td></tr>
						<tr><td>4</td>
						<td>ERROR: log only messages of level ERROR</td></tr>
						<tr><td>5 (or above)</td>
						<td>do not log to syslog</td></tr>
						</table>
         </td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-m</span>M
					</td>
					<td>
						Sets the server to register itself against masterserver M.
						M is the base url of the master server and has to end in a / and without a http:// prefix,
						the default is masterserver.cubers.net/cgi-bin/AssaultCube.pl/.
						If you want your server to be private and not report to the masterserver, use -mlocalhost.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-p</span>PASS
					</td>
					<td>
						Sets the server password to PASS. Only clients
						that use the command "/connect <i>IP PORT PASS</i>" will be able to connect.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-c</span>N
					</td>
					<td>
						Sets the maximum number of players that can play on
						this server to N (default 6). If more players try to connect they will get a "server
						full" message.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-x</span>M
					</td>
					<td>
						Sets the <a href="server.html#serveradmin" shape="rect">
						admin</a> password. If you don't want your commandline to contain the password, or if you need
						more than one admin password, use the file "config/serverpwd.cfg".
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-X</span>f
					</td>
					<td>
						Sets the admin password file. The default is <span class="code">-Xconfig/serverpwd.cfg</span>
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-r</span>C
					</td>
					<td>
						Sets the <a href="server.html#maprotation" shape="rect">
						maprotation</a> file. Example: <span class="code">-rconfig/maprot.cfg</span>
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-B</span>f
					</td>
					<td>
						Sets the blacklist file. The default is
						<span class="code">-Bconfig/serverblacklist.cfg</span>
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-K</span>f
					</td>
					<td>
						Sets the nickname blacklist file. The default is
						<span class="code">-Kconfig/nicknameblacklist.cfg</span>
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-I</span>f
					</td>
					<td>
						Sets the serverinfo text filename prefix. The default is
						<span class="code">-Iconfig/serverinfo</span>.
						The server adds <tt>"_en.txt"</tt> to the prefix to
						complete the filename.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-o</span>N
					</td>
					<td>
						Sets the server's "message of the day" (MOTD).
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-k</span>N
					</td>
					<td>
						Sets the kick threshold. If a players score drops
						below it, he will be kicked automatically (default: -5).
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-y</span>N
					</td>
					<td>
						Sets the ban threshold. If a players score drops
						below it, he will be banned automatically (default: -6).
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-P</span>M
					</td>
					<td>
						Sets the required role to call specific votes. The two possible player roles are 'player' and 'admin'.
						'M' is a string of characters to set vote role requirements per vote type. A lower case character
						enables the vote call for normal players, an upper case character sets the vote call to require an
						admin. If a character does not appear in the string, the default setting is used.<br clear="none" />
						The following votes can be adjusted:
						<table>
						<tr><td>k</td>
						<td>kick players</td></tr>
						<tr><td>b</td>
						<td>ban players (and remove bans)</td></tr>
						<tr><td>m</td>
						<td>change mastermode (open/private)</td></tr>
						<tr><td>f</td>
						<td>force a player to the other team</td></tr>
						<tr><td>a</td>
						<td>enable/disable autoteam</td></tr>
						<tr><td>s</td>
						<td>shuffle the teams</td></tr>
						<tr><td>r</td>
						<td>record a demo of the next game</td></tr>
						<tr><td>c</td>
						<td>clear all demos on server</td></tr>
						<tr><td>d</td>
						<td>change server description</td></tr>
						<tr><td>x</td>
						<td>vote for maps, that are not present on the server</td></tr>
						<tr><td>p</td>
						<td>vote for a gamemode that is not supported by the map</td></tr>
						</table>
						For example: -PbmAX enables ban & mastermode to be voted by normal players but
						only admins can change autoteam or vote for nonexistent maps.
						The default settings are: "fkBMasRCDxP".
         </td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-A</span>map
					</td>
					<td>
						Restricts voting for the map to admins. This switch can be used several times.
         </td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-D</span>
					</td>
					<td>
						Enables permanent demo recording. Every game will
						be recorded. The recorded demos will be held in RAM. By default, up to 5 demos will be kept.
						The oldest demo will be deleted automatically if necessary, to allow recording of further demos.
						To change the default of 5 demos in RAM, you can add the number of demos to the parameter,
						e.g. <span class="code">-D5</span>
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-W</span>f
					</td>
					<td>
						Sets a path (and optional filename prefix) to write all recorded demos to. The example
            <span class="code">-Wserverdemos/mydemo</span> would save all demos to the directory
            'serverdemos' and prefix the filenames with 'mydemo'. The filename will contain the (optional)
            prefix, the (encoded) time, game mode and map. To set a path without filename prefix, use
            <span class="code">-Wpath/</span>. A prefix without path can be set by <span class="code">
            -Wprefix</span>. The server owner has to take precautions that the demo files don't fill up the
            filesystem - especially, if permanent demo recording is also enabled (switch '-D').
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-SW</span>
					</td>
					<td>
						Starts the server as windows service and sets the
						name of the windows service that should be used. Works only for the server binary
						is started directly from the windows service manager.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-C</span>f
					</td>
					<td>
						Reads commandline arguments from a file. For example,
						<span class="code">-Cconfig/servercmdline.txt</span> will read arguments from that file.
            Only one parameter per line is allowed. Empty lines, and any text after '//' will be ignored.
						The file is only read once at server startup; changing the file's content will not affect a running server.
						See config/servercmdline.txt for additional info. No file is read by default.
					</td>
				</tr>
				<tr>
					<td style="text-align: center;vertical-align: top">
						<span class="codecommandline">-V</span>
					</td>
					<td>
						Sets the server to verbose mode. This enables additional
						log messages to be printed, including the server configuration files (after parsing). Using this
						switch twice will also enable logging of DEBUG messages. Be careful:
						the logfile will contain all content from serverpwd.cfg.
					</td>
				</tr>
			</table>
       </div>
        <div id="footer">
            Rabid Viper Productions 2008/10/19
        </div>
    </div>
</body>
</html>