Server setup
From AssaultCube
| | There are some things TO DO on this page: This info will be merged with the article MOTD |
The most common questions we've had regarding server setup will be answered here to supplement the basic documentation.
coloured server description
You'll need to use the control-character "\f" (line-feed) which has the ASCII-code of 12;
- on linux you should be able to create it with Ctrl + L (ingame or in an editor) or Ctrl + V and then L (on the shell)
- on windows you should be able to create it via Alt-Gr + 1 + 2 (NumKeyPad)
- you can also use Media:Control_char_formfeed.txt (use "Save Link as..." from your browser!)
- an example is provided in Media:Example_coloured_motd.txt
Colourization (this also applies for CubeScript/ingame colours) works via the control-char followed by a indication character. Apart from the special cases of "\fs" and "\fr" for saving/restoring previously set colours in the current line of text you can use the following numbers to set to the respective colour:
- 0 : green
- 1 : blue
- 2 : yellow
- 3 : red
- 4 : gray
- 5 : white
- 6 : magenta
Check source/src/rendertext.cpp to see wether your currently installed release might be more current than this page! Look inside the "draw_text" function inside the case for "\f" (obviously) - in v0.93 this is line 187ff. RandumIdiot:RandumIdiot's simplistic explanation of coloured messages.
Also take a look at the discussion
Coloured Server Title via Mac Launcher
where this link goes directly to a hopefully helpful screenshot! (see the backlog of last few posts above it too for clarification).
multiline server description
This is a matter of your operating-system really. On *nix I'd go for a shell script along the lines of:
#!/bin/sh # TS=$(date +%H:%M:%S\ %d.%m.%y) echo -e "NOW : $TS\n" # # MOTD definition - WYSIWYG :) # MOTD='^L5http://^L3assault^L5.^L1cubers^L5.^L2net^L5/ ^L2--- -- - -- --- Server Auto-^L3Disconnect^Lfs ^L2@ ^L3-1^Lf frags ... You Have Been Warned!' # # run the server: # bin_unix/linux_server -xMyPassWord -k-1 -c6 -n"^L3AC^L2SRV^L1~" -o"$SM"
Then I start that in an appropriately setup screen session :) You might be interested in Coloured_logs for viewing the generated logs colourized on your terminal :)
On Windows you should either be able to use the method suggested on the forum or try Alt-Gr + 1 + 0 for LF (linefeed).
No idea what Mac's have nowadays, they used to have their own "new line"-indication; it's "\n" on *nix, "\r\n" on Windows ... must've been "\n\r" on Apple ... is it still with Mac OS X?!?
Anyway, if LF doesn't work NL should "\n" or Alt-Gr + 1 + 3
|
Newbie Guide | Basic Strategy Tips | Server Guide | Special Movement | Weapon Tactics and Tips | Slang and Jargon Definitions | Gamemodes | Server administration | IRC | Server setup | Console commands |
| View Edit |
Categories: Guides | English | Configuration | Servers

