AssaultCube Documentation
NOTE: You're currently viewing a development (SVN) version of AssaultCube's documentation.

To view the documentation from the current version of the game instead, click here.

CubeScript

CubeScript is the scripting language of AssaultCube and it is similar to scripting languages of other games, except that its a bit more powerful because it is almost a full programming language.

CubeScript consists of the command itself, followed by any number of arguments separated by whitespace. You can:

It is recommended to read examples of this in your ./config/ folder to understand them better. The documentation below contains a reference of ALL of the CubeScript commands at your disposal. Have fun!

CubeScript

This section describes identifiers that are closely related to the CubeScript language.

! A
Performs a negation.
ArgumentDescriptionValues
Aargument
!= A B
Determines if two values are not equal.
ArgumentDescriptionValues
Afirst value
Bsecond value

Return value: the inequality, 1 (not equal) or 0 (equal)

!=f A B
Determines if the first floating-point value is not equal to the second floating-point value.
ArgumentDescriptionValues
Athe first value
Bthe second value

Return value: (true)1||0(false)

&& A B
logical AND.
ArgumentDescriptionValues
Afirst value
Bsecond value

Example: echo (&& 1 1)Output: 1

Example: echo (&& 1 0)Output: 0

Return value: A AND B

* A B
Performs a multiplication.
ArgumentDescriptionValues
Athe multiplicand
Bthe multiplier

Return value: the product

*= A B
Multiplies an alias by a value.
ArgumentDescriptionValues
Athe alias to be multiplied
Bthe multiplier
Example: *= foo 1337
*=f A B
Multiplies an alias by a floating-point value.
ArgumentDescriptionValues
Athe alias to be multiplied
Bthe multiplier
Example: *=f foo 13.37
*f A B
Performs a floating point multiplication.
ArgumentDescriptionValues
Athe multiplicand
Bthe multiplier

Return value: the product

+ A B
Performs an addition.
ArgumentDescriptionValues
Athe first summand
Bthe second summand
Example: echo the sum of x and y is (+ $x $y)

Return value: the sum

++ A
Increments an alias by 1.
ArgumentDescriptionValues
Athe alias name

Example: i = 0; ++ i; echo $iOutput: 1

see also: --, ++f, --f
++f A
Increments an alias by 1.
ArgumentDescriptionValues
Athe alias name

Example: i = 2.14; ++f i; echo $iOutput: 3.14

see also: --f, ++, --
+= A B
Adds a value to an alias.
ArgumentDescriptionValues
Athe alias to add to
Bvalue to be added
Example: += foo 1337
+=f A B
Adds a floating-point value to an alias.
ArgumentDescriptionValues
Athe alias to add to
Bvalue to be added
Example: +=f foo 13.37
+f A B
Adds up two floating-point numbers.
ArgumentDescriptionValues
Athe first summandfloat
Bthe second summandfloat

Return value: the sum

- A B
Performs a subtraction.
ArgumentDescriptionValues
Athe minuend
Bthe subtrahend

Return value: the difference

-- A
Decrements an alias by 1.
ArgumentDescriptionValues
Athe alias name

Example: i = 0; -- i; echo $iOutput: -1

see also: ++, --f, ++f
--f A
Decrements an alias by 1.
ArgumentDescriptionValues
Athe alias name

Example: i = 4.14; --f i; echo $iOutput: 3.14

see also: ++f, --, ++
-= A B
Subtracts a value from an alias.
ArgumentDescriptionValues
Athe alias to subtract from
Bvalue to be subtracted
Example: -= foo 1337
-=f A B
Subtracts a floating-point value from an alias.
ArgumentDescriptionValues
Athe alias to subtract from
Bvalue to be subtracted
Example: -=f foo 13.37
-f A B
Subtracts two floating-point numbers.
ArgumentDescriptionValues
Athe minuendfloat
Bthe subtrahendfloat

Return value: the difference

< A B
Determines if a value is smaller than a second value.
ArgumentDescriptionValues
Athe first value
Bthe second value

Return value: the comparison, 1 (smaller) or 0 (not smaller)

<= A B
Determines if a values is less than or equal than a second value.
ArgumentDescriptionValues
Athe first value
Bthe second value
<=f A B
Compares if a particular floating-point value is less than or equal to another floating-point value.
ArgumentDescriptionValues
AThe first value.
BThe second value.

Return value: (true)1||0(false)

<f A B
Compares if a particular floating-point value is smaller than another floating-point value.
ArgumentDescriptionValues
AThe first value.
BThe second value.

Return value: (true)1||0(false)

= A B
Determines if two values are equal.
ArgumentDescriptionValues
Afirst value
Bsecond value

Example: echo there are only (concatword (= 1 1) (= 1 0)) types of people in the worldOutput: there are only 10 types of people in the world

Return value: the equality, 1 (equal) or 0 (not equal)

=f A B
Compares if a particular floating-point value is equal to another floating-point value.
ArgumentDescriptionValues
AThe first value.
BThe second value.

Return value: (true)1||0(false)

> A B
Determines if a value is bigger than a second value.
ArgumentDescriptionValues
Athe first value
Bthe second value

Return value: the comparison, 1 (bigger) or 0 (not bigger)

>= A B
Determines if a values is greater than or equal than a second value.
ArgumentDescriptionValues
Athe first value
Bthe second value
>=f A B
Determines if the first floating-point value is greater than or equal to the second floating-point value.
ArgumentDescriptionValues
Athe first value
Bthe second value

Return value: (true)1||0(false)

>f A B
Determines if the first floating-point value is greater than the second floating-point value.
ArgumentDescriptionValues
Athe first value
Bthe second value

Return value: (true)1||0(false)

This will append the passed 2nd argument to any existing content of the alias named in the 1st argument. Several popular aliases have predefined shortcuts using this scriptalias: addOnQuit, addOnLoadOnce, addOnLoadAlways. Check config/scripts.cfg for possible omissions in that list.

Example: foo = "one" add2alias foo two echo foo Output: one twoThis will output the string and override any other actions that might've been defined.

see also: add2bind, add2list
Adds a block of code, if it does not already exist, to a keybind.
ArgumentDescriptionValues
Kthe key to add to
Cthe code to add
see also: add2alias, add2list
Appends a new element to a list.
ArgumentDescriptionValues
Athe alias (list) to add to
Ethe new element to add

Example: tmp_list = []; add2list tmp_list Hello; add2list tmp_list world!; echo $tmp_listOutput: Hello world!

see also: add2alias, add2bind
Injects CubeScript punctuation.
ArgumentDescriptionValues
Sa string
Ntype IDmin 0/max 5/default 0

Example: echo (addpunct hello)Output: "hello"

Example: echo (addpunct hello 1)Output: [hello]

Example: echo (addpunct hello 2)Output: (hello)

Example: echo (addpunct hello 3)Output: $hello

Example: echo (addpunct "" 4)

Example: echo (addpunct "" 5)Output: %

Example: test = (concat echo (addpunct fov 3)); testOutput: 90.0

alias N A
Binds a name to commands.
ArgumentDescriptionValues
Nthe name of the aliasstring, must not contain '$'
Athe commandsstring

Example: alias myalias [ echo "hello world"; alias myalias [ echo "I already said hello" ] ]It is possible to re-bind an alias, even during its evaluation.

Example: test = [ echo "successful" ]There is also the shorthand version of defining an alias via the "="-sign.

Initializes a group of aliases using checkinit.
ArgumentDescriptionValues
Lthe list of aliases to check for
Bthe block of code to ensure the aliases contain (optional)
at S N
Grabs a word out of a string.
ArgumentDescriptionValues
Sthe string
Nthe index of the word

Example: echo (at "zero one two three" 2)output: two

Return value: the word from the specified idex

Aborts a loop created with a 'loop', 'looplist' or 'while' command.

Example: loop i 10 [ if (= $i 4) [ break ]; echo $i]output: 0 1 2 3

see also: continue, loop, while
Breaks out of a parsestring loop.
Important: This command should only be used within the 3rd argument (the cubescript to execute) of parsestring.
see also: parsestring
c N
Adds color to a string.
ArgumentDescriptionValues
Ncolor id0 min, 9 max

Example: echo (c 3)Hello (c 0)world!Output: a red "Hello" and a green "world!"

see also: cncolumncolor
ceil F
Upper value of a float number
ArgumentDescriptionValues
FThe float number to get the ceil from

Return value: The ceil value (integer)

Defines an alias only if it does not already exist.
ArgumentDescriptionValues
Aalias name
Valias value
Uses check2init on a list of aliases.
ArgumentDescriptionValues
Llist of alias names
Valias value
Determines if the argument given is an existing alias or not.
ArgumentDescriptionValues
Athe alias to check for

Example: hello = ""; echo (checkalias hello)Output: 1

Example: echo (checkalias oMgThIsAlIaSpRoLlYdOeSnTeXiSt)Output: 0

see also: checkinit, aliasinit
Ensures the initialization of an alias.
ArgumentDescriptionValues
Athe alias to check for
Bthe block of code to ensure that the alias contains (optional)

Example: checkinit mapstartalwaysOutput: if alias mapstartalways does not exist, this command initializes it.

Example: checkinit mapstartalways [ echo New map, good luck! ]Output: if alias mapstartalways does not exist, it is initialized, and if the block of code "[ echo New map, good luck! ]" does not exist within the aliases contents, this command adds it.

concat S ...
Concatenates multiple strings with spaces inbetween.
ArgumentDescriptionValues
Sthe first string
...collection of strings to concatenate

Example: alias a "hello"; echo (concat $a "world")output: hello world

Return value: The newly created string

concatword S ...
Concatenates multiple strings.
ArgumentDescriptionValues
Sthe first string
...collection of strings to concatenate
The newly created string is saved to the alias 's'.

Example: alias a "Cube"; echo (concatword $a "Script")output: CubeScript

Return value: The newly created string

const N A
Set an alias as a constant.
ArgumentDescriptionValues
Nthe name of the aliasstring, must not contain '$'
Athe value (optional)string
A constant cannot be redefined : its value cannot be changed.
To get rid of a constant, use delalias

Example: myalias = myvalue; const myalias;Set "myalias" value to "myvalue" then "lock" it as a constant.

Example: const myalias myvalue;You can directly set a value for your alias when you define it as a constant.

Example: const myalias myvalue; myalias = anothervalue;Assigning a value to a const will throw you an error. Output: myalias is already defined as a constant

Skip current loop iteration.

Example: loop i 5 [ if (= $i 2) [ continue ]; echo $i]output: 0 1 3 4

see also: break, loop, while
Converts a list of strings to lowercase or uppercase characters.
ArgumentDescriptionValues
N0 - use lowercase, 1 - use uppercasemin 0/max 1
...a list of strings
This command can handle up to 23 string arguments.

Example: echo (convertcase 0 ZERO ONE TWO THREE)Output: zero one two three

Example: echo (convertcase 1 zero one two three)Output: ZERO ONE TWO THREE

see also: tolower, toupper
Returns the current number of players.
The return value includes the local player "(you)", and works in both singleplayer and multiplayer scenarios.
div A B
Performs an integer division.
ArgumentDescriptionValues
Athe dividend
Bthe divisor

Return value: the quotient (integer)

div= A B
Divides an alias by a value.
ArgumentDescriptionValues
Athe alias to be divided
Bthe divisor
Example: div= foo 1337
div=f A B
Divides an alias by a floating-point value.
ArgumentDescriptionValues
Athe alias to be divided
Bthe divisor
Example: div=f foo 13.37
divf A B
Performs a division with floating-point precision.
ArgumentDescriptionValues
Athe dividend
Bthe divisor

Return value: the quotient (floating-point)

Executes the specified string as CubeScript.
ArgumentDescriptionValues
Sthe string to execute

Example: execute (concat echo (addpunct fov 3))Example output: 90.0

find client number (cn)
ArgumentDescriptionValues
NNAME
Returns the name of a key via a specified code.
ArgumentDescriptionValues
Iinteger
Returns -255 if the key does not exist.
See /config/keymap.cfg for a full list of valid key codes.

Example: echo (findkey 8)Output: BACKSPACE

Example: echo (findkey 280)Output: PAGEUP

see also: keybind, findkeycode
Returns the integer code of a key.
ArgumentDescriptionValues
Kthe name of the key
Returns -255 if the key does not exist.
See /config/keymap.cfg for a full list of valid key names.

Example: echo (findkeycode BACKSPACE)Output: 8

Example: echo (findkeycode PAGEUP)Output: 280

see also: keybind, findkey
Searches a list for a specified value.
ArgumentDescriptionValues
Lthe list
Ithe item to find

Return value: the index of the item in the list

find player name
ArgumentDescriptionValues
CCLIENTNUM
Floor value of a float number
ArgumentDescriptionValues
FThe float number to get the floor from

Return value: The floor value (integer)

Forcibly sets a list of aliases to a specified value.
ArgumentDescriptionValues
Llist of alias names
Valias value

Example: alias1 = 0; alias2 = 0; alias3 = 0; alias4 = 0; alias 5 = 0Can be written as:

Example: forceinit [alias1 alias2 alias3 alias4 alias5] 0

format F V
ArgumentDescriptionValues
Fformatuse %1..%9 for the values
Vvalue(s)

Example: echo (format "%1 bottles of %2 on the %3, %1 bottles of %2!" 99 beer wall)output: 99 bottles of beer on the wall, 99 bottles of beer!

return the value of the alias
ArgumentDescriptionValues
Nalias name
see also: storesets
Returns the highest valid client number available.
if cond true false
Controls the script flow based on a boolean expression.
ArgumentDescriptionValues
condthe condition0 (false) or anything else (true)
truethe body to execute if the condition is true
falsethe body to execute if the condition is false

Example: if (> $x 10) [ echo x is bigger than 10 ] [ echo x too small ]

returns whether or not there is an identifier by that name
ArgumentDescriptionValues
Nidentifier name
Determines if the argument given is a constant or not.
ArgumentDescriptionValues
Athe alias to check for

Example: const hello ""; echo (isconst hello)Output: 1

Example: hello = value; echo (isconst hello)Output: 0

see also: const
Returns the contents of a keybind.
ArgumentDescriptionValues
Kname of key
see also: findkey, findkeycode
l0 W V
leading zeros for the number V to make it W chars wide. It may look like 10 - which might be considered a mnemonic - but it's lowercase-L and 0!
ArgumentDescriptionValues
WWIDTH
VVALUE

Example: echo (l0 5 1000)Output: 01000

Example: echo (l0 3 1000)Output: 1000

Returns the average of a list of numbers.
ArgumentDescriptionValues
Lthe list of numberssupports ints and floats

Example: echo (listaverage "2 5 5")Output: 4.0

returns the element count of the given list.
ArgumentDescriptionValues
Lthe list
loop V N body
Loops the specified body.
ArgumentDescriptionValues
Vthe alias used as counter
Nthe amount of loops
bodythe body to execute on each iteration
This command sets the alias you choose, as first argument, from 0 to N-1 for every iteration.

Example: loop i 10 [ echo $i ]

see also: break, continue, while
looplist V N body
Browses a list and executes a body for each element
ArgumentDescriptionValues
Vthe list to browse
Nthe alias containing the current element value.
bodythe body to execute on each iteration

Example: looplist "zero one two three" number [ echo $number ]

see also: break, continue, loop
mod A B
Performs a modulo operation.
ArgumentDescriptionValues
Athe dividend
Bthe divisor

Return value: the modulo value

modf A B
Performs a floating-point modulo operation.
ArgumentDescriptionValues
Athe dividend
Bthe divisor

Example: echo (modf 7.5 12.5)Output: 7.5

Example: echo (modf 17.5 12.5)Output: 5.0

Return value: the modulo value

The number of arguments passed to the current alias
Description ValuesRangeDefault
numargs0..250
parsestring S A C B
Loops through every character in the given string and executes the given block of cubescript on each iteration.
ArgumentDescriptionValues
Sstringstring to parse
Astringname of alias to use as iterator
Cstringcubescript to execute on each iteration
Binteger (optional)non-zero to force backwards parse
Important: A secondary iterator alias (prefixed with a double underscore "__") is automatically created before each iteration that contains the character position data.

Example: parsestring "Hello world" iter [echo $iter]Uses echo on every character in the string: "Hello world"

Example: parsestring "Hello world" iter [echo (concatword "Char #" $__iter ": " $iter)]Uses echo on every character in the string: "Hello world" --- Also outputs the position of each character in the string.

Example: backwardsstring = []; parsestring "This will look interesting backwards." iter [backwardsstring = (concatword $backwardsstring $iter); if (= $__iter 0) [echo $backwardsstring]] 1Outputs: ".sdrawkcab gnitseretni kool lliw sihT"

Example: parsestring "abcdefghijklmnopqrstuvwxyz" iter [if (> $__iter 4) breakparse [echo $iter]]Example usage of the breakparse command. Uses echo on characters a through e, then breaks out of the parse.

Controls whether aliases defined afterwards will be saved (1) or not (0). This option is useful to keep saved.cfg free from unneeded clutter.
ArgumentDescriptionValues
Bcontrol option1...persistent, 0...not persistent

Example: persistidents 0; foo = [ echo "bar"]foo will not be saved and has to be redefined when restarting AC.

Example: persistidents 1; bar = [ echo "foo"]bar will be saved and persistent across sessions.

pop A
Resets a previously pushed alias to it's original value.
ArgumentDescriptionValues
Aalias

Example: pop p; echo $pOutput: 1

see also: push
powf A B
Returns A raised to the power of B (floating-point)
ArgumentDescriptionValues
Athe mantissa
Bthe exponent

Return value: A raised to the power of B

push N A
Temporarily redefines the value of an alias.
ArgumentDescriptionValues
Nalias name
Aaction

Example: p = 1; push p 2; echo $pOutput: 2

see also: pop
Resets all current "sleep".
Sets the result value of a CubeScript block.
ArgumentDescriptionValues
Rthe result
see also: execute, return
Sets the result value of a CubeScript block.
ArgumentDescriptionValues
Rthe result
see also: execute, result
rnd A
Random value
ArgumentDescriptionValues
AThe upper limit of the random value

Return value: The random value, larger or equal 0 and smaller than A

Round the given float
ArgumentDescriptionValues
FThe float number to round

Return value: The rounded integer, The precision is 1 unit

sleep N C P
Executes a command after specified time period.
ArgumentDescriptionValues
Nthe amount of milliseconds
Cthe command to execute
Pignore map change (optionnal)

Example: sleep 1000 [ echo foo ]Prints 'foo' to the screen after 1 second.

Generates an alias (list) of the current values for the given aliases/CVARs.
ArgumentDescriptionValues
Lthe list of aliases/CVARs
Athe alias to store them in

Example: storesets "sensitivity hudgun fov" tmpExample result: stores "3.000 1 120" into alias "tmp".

see also: getalias
strcmp A B
Determines if two strings are equal.
ArgumentDescriptionValues
Athe first string
Bthe second string

Example: if (strcmp yes yes) [echo the two strings are equal] [echo the two strings are not equal]Output: the two strings are equal

Return value: the equality, 1 (equal) or 0 (unequal)

see also: strstr
Returns the length (in characters, including whitespace) of string S.
ArgumentDescriptionValues
SSTRING

Example: echo (strlen "Hello world!")Output: 12

see also: substr
strpos H S N
Returns the position of a substring into another
ArgumentDescriptionValues
Hhaystack string
Sneedle string
NThe occurence of 'needle' to find (optionnal)
Character indexes and occurence number begin at 0.

Example: echo (strpos "hello world" "world") 6

Example: echo (strpos "hello world" "l") 2

Example: echo (strpos "hello world" "l" 2) 9

Return value: The N'th position of 'needle' into 'haystack' (-1 if 'needle' isn't found;)

strreplace S T N
Returns a string, with a portion of it replaced with a new sub-string.
ArgumentDescriptionValues
Sthe original string to modify
Tthe target sub-string to replace
Nthe new sub-string to replace the target

Example: echo (strreplace "Hello cruel world" cruel "")Output: Hello world

see also: strins, strpos, substr
strstr A B
Determines if string B was found in string A.
ArgumentDescriptionValues
Athe first string
Bthe second string

Example: if (strstr "Hello world!" Hello) [echo found Hello in Hello world!] [echo did not find Hello in Hello world!]Output: found Hello in Hello world!

Return value: the truth value, 0 (false), 1 (true)

see also: strcmp
substr S A L
Copies a substring out of the original.
ArgumentDescriptionValues
Sthe original string
Astart position
Lsubstring length (optionnal)
Character indexes begins at 0. If "start position" is negative, the reference is the end of the string.

Example: echo (substr abcdefgh 2 5) cdefg

Example: echo (substr abcdefgh -3 2) fg

Example: echo (substr abcdefgh 2) cdefgh

Return value: the substring

switch I C
Takes an integer argument to determine what block of code to execute.
ArgumentDescriptionValues
Iinteger
Ca variable number of 'case' arguments...
This command can only handle up to 23 'cases'. (because of cubescript's 24 argument limit)

Example: switch 2 [echo case 0] [echo case 1] [echo case 2] [echo case 3] [echo case 4]Output: case 2

Tests a character argument for various things.
ArgumentDescriptionValues
Cthe character to test
Ntype of test to runmin 0/max 7/default 0
See the following c++ functions for more information about the usage of this command:
isalpha(), isalnum(), isdigit(), islower(), isprint(), ispunct(), isupper(), and isspace()

Example: echo (testchar 1)Output: 1 // It is a 0-9 digit

Example: echo (testchar a 1)Output: 1 // It is a a-z or A-Z character

Example: echo (testchar z 2)Output: 1 // It is a a-z or A-Z character or 0-9 digit

Example: echo (testchar b 3)Output: 1 // It is a lowercase a-z character

Example: echo (testchar B 4)Output: 1 // It is a uppercase A-Z character

Example: echo (testchar , 5)Output: 1 // It is a printable character

Example: echo (testchar . 6)Output: 1 // It is a punctuation character

Example: echo (testchar " " 7)Output: 1 // It is a whitespace character

Converts a string to all lowercase characters.
ArgumentDescriptionValues
Sa string

Example: echo (tolower HELLO)Output: hello

see also: toupper, convertcase
Converts a string to all uppercase characters.
ArgumentDescriptionValues
Sa string

Example: echo (toupper hello)Output: HELLO

see also: tolower, convertcase
Removes all unnecessary leading and trailing whitespace characters from the given string.
ArgumentDescriptionValues
Sstringstring to modify

Example: echo (trimAllUnnecessaryWhitespace " H e ll o w o r l d ")Outputs: "H e ll o w o r l d"

Removes all whitespace characters from the given string.
ArgumentDescriptionValues
Sstringstring to modify

Example: echo (trimAllWhitespace " H e ll o w o r l d ")Outputs: Helloworld

while cond body
Loops the specified body while the condition evaluates to true.
ArgumentDescriptionValues
condthe conditionthe code evaluated before each iteration
bodythe body to execute on each iteration
This command sets the alias "i" from 0 to N-1 for every iteration. Note that the condition here has to have [], otherwise it would only be evaluated once.

Example: alias i 0; while [ (< $i 10) ] [ echo $i; alias i (+ $i 1) ]

see also: break, continue, loop
|| A B
logical OR.
ArgumentDescriptionValues
Afirst value
Bsecond value

Example: echo (|| 1 0)output: 1

Example: echo (|| 0 0)output: 0

Return value: A OR B

General

This section describes general identifiers.

Adds a server to the list of server to query in the server list menu.
ArgumentDescriptionValues
Sthe address of the server (hostname or IP)
Pthe port
Enables or disables the ability of hudecho to output text to the heads up display.
Token Description ValuesRangeDefault
N0 off, 1 on0..11
see also: hudecho
Fires the current weapon.
default: left mouse button
Determines if the current played map should be automatically downloaded if it is not available locally.
Token Description ValuesRangeDefault
Benable auto map download0..11
Automatically get new map revisions from the server.
Token Description ValuesRangeDefault
N0: no, 1: yes0..10
Toggle for taking an automatic screenshot during intermission.
Token Description ValuesRangeDefault
B0=Off, 1=On0..11
Moves the player backward.
default keys: S and Down Arrow
bind K A
Binds a key to a command.
ArgumentDescriptionValues
Kthe key to bindstring
Athe commandstring, usually an alias
To find out what key names and their default bindings are, look at config/keymap.cfg, then add bind commands to your autoexec.cfg.
Toggles getting descriptive text from CGZ or DMO files in menudirlist.
Token Description ValuesRangeDefault
B0..11
see also: menudirlist
Swaps your player to the enemy team.
Take a "clean" screenshot with no HUD items.
Your current HUD configuration is stored into a buffer, and is re-enabled afterwards.
see also: screenshot
Sets the correction value for clockfix.
Token Description ValuesRangeDefault
Vcorrection value990000..10100001000000
Engine source-code snippet (main.cpp): if(clockfix) millis = int(millis*(double(clockerror)/1000000));
see also: clockfix
Enables correction of the system clock.
Token Description ValuesRangeDefault
Benable correction0..10
see also: clockerror
Indicates if a connection to a server exists.
Token Description ValuesRangeDefault
Bthe connection state1 (connected), 0 (disconnected)0..10
representation of date
format: Www Mmm dd hh:mm:ss yyyy
Use timestamp to create your own formatting.

Example: echo (datestring) "Sat Jun 7 17:08:35 2008"

Enable triangle debug.
Token Description ValuesRangeDefault
Btriangle debug0..10
Prints details while connecting triangles of 3d models.
Dump all command arguments to STDOUT
ArgumentDescriptionValues
......
echo L
Outputs text to the console.
ArgumentDescriptionValues
LList of strings
see also: hudecho
Similar to bind, but is only active while editing, where it overrides the regular bind for the specified key.
ArgumentDescriptionValues
Kthe key to bindstring
Athe commandstring, usually an alias
see also: bind, specbind
exec C
Executes all commands in a specified config file.
ArgumentDescriptionValues
Cthe config file
Moves the player forward.
default keys: W and Up Arrow
Holds the current game mode. READ ONLY

Example: echo $gamemodeOutput: 5

see also: mode
Returns a list of values describing the current engine (rendering) state.
It will only be filled after the first frame was drawn.
The list is: FPS LOD WQD WVT EVT
FPS = Frames Per Second
LOD = Level Of Detail
WQD = World QuaD Count
WVT = World VerTex Count
EVT = Extra VerTex Count (HUD & menu)

Example: echo (getEngineState)

Returns the current game mode.
ArgumentDescriptionValues
N0 = full mode name, 1 = mode acronymmin 0/max 1/default 0

Example: echo (getmode)Example output: capture the flag

Example: echo (getmode 1)Example output: CTF

Returns the file extension of the client's current screenshottype setting.

Example: echo (getscrext)Example output: .jpg

Outputs text to the console and heads up display.
ArgumentDescriptionValues
LList of strings
see also: allowhudechos, echo
Sets mouse to "flight sim" mode.
ArgumentDescriptionValues
Bsets invmouse0 (off), else (on)
Sets the JPEG screenshot image quality.
Token Description ValuesRangeDefault
NCompression level10..10070
The image quality is set by it's compression level, a value of 10 sets maximum compression and a small file size but results in a bad quality image
while a value of 100 results in a large file but gives the best quality image.
Triggers a jump.
default keys: space and right mouse.
keymap K N A
Sets up the keymap for the specified key.
ArgumentDescriptionValues
Kthe key to map
Nthe name for the key
Athe default action
You should never have to use this command manually, use "bind" instead.
see also: bind
Sets the language for which a translated server MOTD will be fetched, if the server has one for this language.
Token Description ValuesRangeDefault
Lthe language code..
This is always a two-letter language code as defined in the ISO 639 standard, three-letter codes are currently not allowed.
If lang is not set, or if the server does not have a matching MOTD file, it will fall back to English.
Note: this does not affect the client language, which is derived from the system settings (e.g. on many *nix systems, it may be changed via the "LANG" environment variable).

Example: en, de, fr, ...

Moves the player left.
default keys: A and Left Arrow
save an image of the entire radar-overview of the map.
Limits the FPS (frames per second) of AssaultCube's video output.
Token Description ValuesRangeDefault
Vmaximum FPS0 disables maxfps25 or 0..1000200
Sets the maximum value the display will roll on strafing.
Token Description ValuesRangeDefault
Nthe roll value0..200
Gets the maximum number of supported textures when performing multitexturing.
Description ValuesRangeDefault
max. number of textures1..00
megabind K D E C B O
Binds a key to many different actions depending on the current game state.
ArgumentDescriptionValues
Kthe key to bindstring
Dbody of code to execute if watching a demoa body of code
Ebody of code to execute if editing or in coop-edit modea body of code
Cbody of code to execute if connected to a servera body of code
Bbody of code to execute if in a bot modea body of code
Obody of code to execute if none of the other arguments have been meta body of code
This command requires 6 arguments, no less. Use an empty set of brackets [] for any of the arguments that you want to "do nothing".

Example: megabind F9 [echo Demo!] [echo Editing or coop!] [echo Connected!] [echo Bots!] [echo Other!]

see also: bind, onrelease
create a menu listing of files from a path and perform an action on them when clicked.
ArgumentDescriptionValues
use this inside menu definitions, almost always as the only command of that menu.
compare the usage inside config/menus.cfg

Example: menudirlist "packages/maps" "cgz" "map $arg1"will create a list of maps and load them when clicked

Returns the number of milliseconds since engine start.

Example: echo (millis)

Return value: the milliseconds

Minimal level of detail.
Token Description ValuesRangeDefault
V25..25060
Toggles use of acronyms instead of full modenames in the serverbrowser.
Token Description ValuesRangeDefault
B0..10
Enables output of processed network packets.
Token Description ValuesRangeDefault
Benable network debugging0..10
This variable only has an effect if the client binary is compiled in debug mode.
Hold the current number of lines on the console.
Executes a command on the release of a key/button.
ArgumentDescriptionValues
Athe command
This command must be placed in an action in a bind or in an alias in a bind.

Example: bind CTRL [ echo "key pressed"; onrelease [ echo "key released" ] ]

see also: bind, megabind
Toggles physics interpolation.
Token Description ValuesRangeDefault
B0..11
Sets the PNG screenshot file compression.
Token Description ValuesRangeDefault
NCompression level0..99
A value of 9 sets maximum data compression and a smaller file size while a value of 0 results in a large file image, quality is always the same since PNG its a loosless format.
Gets an integer representing the game protocol. READ ONLY
As example, the protocol of version 1.1.0.4 is represented as value 1132.
Quits the game without asking.
registers a track as music - the first three tracks have special meaning. Track #1 is for "flag grab" the second and third are used as "last minute" tracks.
ArgumentDescriptionValues
Mmusic file
Resets all binds back to their default values.
This command executes the file /config/resetbinds.cfg which will bind all keys to the values specified in that file, thus resetting the binds to their default values.
Determines if all settings should be reset when the game quits.
Token Description ValuesRangeDefault
Benable reset0..10
It is recommended to quit the game immediately after enabling this setting. Note that the reset happens only once as the value of this variable is reset as well.
see also: quit
Clears the list of secured maps.
see also: securemap
Moves the player right.
default keys: D and Right Arrow
run N
Executes a config file within /config/
ArgumentDescriptionValues
Nthe file name (without extension)
Takes a screenshot.
Screenshots are saved to "screenshots/[date]_[time]_[map]_[mode].[ext]", where [ext] is the image type selected.

default key: F12

see also: cleanshot
Scales screenshots by the given factor before saving. 1 = original size, 0.5 = half size, etc.
Token Description ValuesRangeDefault
SScale0.1..11
Toggle format of screenshot image. Your choice is for BMP (0), JPEG (1) or PNG (2).
Token Description ValuesRangeDefault
T0=BMP, 1=JPEG, 2=PNG0..21
see also: getscrext
Adds a map to the list of secured maps.
ArgumentDescriptionValues
Sthe name of the map
Secured maps can not be overwritten by the commands sendmap and getmap.
Sets the mouse sensitivity.
ArgumentDescriptionValues
Sthe sensitivityfloating-point
Determines the valid distance when extrapolating a players position.
Token Description ValuesRangeDefault
Vdistance0..168
Determines the speed when extrapolating a players position.
Token Description ValuesRangeDefault
Vmovement speed0..10075
Plays all hardcoded sounds in order.
Similar to bind, but is only active while spectating, where it overrides the regular bind for the specified key.
ArgumentDescriptionValues
Kthe key to bindstring
Athe commandstring, usually an alias
see also: bind, editbind
seconds since the epoch (00:00:00 UTC on January 1, 1970)

Example: echo (systime)

Determines how fast network throttling accelerates.
Token Description ValuesRangeDefault
Vacceleration0..322
Determines how fast network throttling decelerates.
Token Description ValuesRangeDefault
Vdeceleration0..322
Determines the interval of re-evaluating network throttling.
Token Description ValuesRangeDefault
Vintervalseconds0..305
a list of values for current time
format: YYYY mm dd HH MM SS

Example: echo (timestamp) "2008 08 08 08 08 08"

Example: echo (timestamp) "2063 04 05 12 00 00"

Example: echo (at (timestamp) 0) (at (timestamp) 2) (at (timestamp) 1) "2063 05 04"

the current time in (H)H:MM:SS format

Example: echo (timestring) "12:34:56"

Example: echo (timestring) "1:02:03"

Toggles the console.
Swaps vertices of model triangles.
Token Description ValuesRangeDefault
V0..11
Contacts the masterserver and adds any new servers to the server list.
ArgumentDescriptionValues
Bforce update0 (delayed), 1 (immediate)
The servers are written to the config/servers.cfg file. This menu can be reached through the Multiplayer menu.
Gets an integer representing the game version. READ ONLY
As example, version 1.0 is represented as value 1000.
writes current configuration to config/saved.cfg - automatic on quit

Gameplay

This section describes gameplay related identifiers.

If defined, this will be executed every time you press a key.
ArgumentDescriptionValues
Iinteger key code

Example: checkinit KEYPRESS [echo You pressed key: (findkey $arg1)]

see also: KEYRELEASE, findkey
If defined, this will be executed every time you release a key.
ArgumentDescriptionValues
Iinteger key code

Example: checkinit KEYRELEASE [echo You released key: (findkey $arg1)]

Deletes a list of aliases (from saved.cfg) on quit.
Token Description ValuesRangeDefault
Lthe list of aliases to delete..

Example: addListOnQuit "a b c"Deletes aliases a, b, and c from existance and saved.cfg upon quit.

see also: addOnQuit
Execute a command or block of code on quit.
Token Description ValuesRangeDefault
Athe command or block of code to execute..
see also: addListOnQuit
addbot T S N
add a bot for a given team with a given skill calling him a given name.
ArgumentDescriptionValues
TteamRVSF or CLA
Sskillbest, good, medium, worse OR bad
Nnamename for the bot
This command only works for single player modes.

Example: addbot RVSF medium RobbieWill add a bot named Robbie with a medium skill level to the RVSF team.

addnbot C T S
will add a given count of bots for the given team with the given skill and select random names for them.
ArgumentDescriptionValues
Ccounthow many bots to add
TteamRVSF or CLA
Sskillbest, good, medium, worse OR bad
This command only works for single player modes.
The name of the bots will be selected randomly.

Example: addnbot 2 CLA badWill add 2 bots with a bad skill level to the CLA team.

Adds a packages source server where to download custom content from.
ArgumentDescriptionValues
SThe server address. Trailing slash not needed.
Only add servers you trust.
The list of servers is saved into config/pcksources.cfg on game quit.

Example: addpckserver http://packages.ac-akimbo.net

If defined, this will be executed after saved.cfg is loaded.
Enables or disables automatic switching to the akimbo upon pickup.
Token Description ValuesRangeDefault
Nenable or disable0..11
see also: akimboendaction
Sets the behavior of weapon switching upon akimbo expiration.
ArgumentDescriptionValues
0 (switch to knife)
1 (stay with pistol)
2 (switch to grenades)
3 (switch to primary)
If no ammunition is detected for the target weapon, it will fallback to the previous weapon until it finds a weapon with ammunition to use.
see also: akimboautoswitch
Returns 1 if the local player is alive.

Example: echo (alive)Output: 1

Determines if the game should try to download missing packages such as textures or mapmodels on the fly.
Token Description ValuesRangeDefault
VNote: This is turned on by default.0..11
Indicates if the weapons should be reloaded automatically.
Token Description ValuesRangeDefault
Bthe autoreload stateon (1), off (0)0..11
Move from active team to spectator during match.
changes the skill level for the given bot.
ArgumentDescriptionValues
Nbotnamethe name of the bot
Sbotskillbest, good, medium, worse OR bad

Example: botskill Robbie bestChanges the previous bot skill level of the bot named Robbie to a 'best' skill level.

changes the skill level for all bots.
ArgumentDescriptionValues
Sbotskillbest, good, medium, worse OR bad

Example: botskillall worseChanges the previous bot skill level for all bots to a 'worse' skill level.

Enables or disables the ability of the bots to fire their weapons
ArgumentDescriptionValues
Tshooting bots?0||1

Example: botsshoot 0Bots won't shoot.

ArgumentDescriptionValues
Ddeltahow many players to shift +/-
Smoothly changes your gamespeed to the specified value.
ArgumentDescriptionValues
Sthe gamespeed to change to
Mmilliseconds between gamespeed changes

Example: changespeed 1000 30Every 30 milliseconds your gamespeed is changed by 1 until it reaches its goal of gamespeed 1000.

Determines if you have any ammunition available for the specified weapon. (uses magcontent and magreserve)
ArgumentDescriptionValues
Nthe weapon number
Clear list of ignored players.
ArgumentDescriptionValues
Aclient number, or -1 to clear the whole list
Omit the client number to clear the whole list.
Clear list of muted players.
ArgumentDescriptionValues
Aclient number, or -1 to clear the whole list
Omit the client number to clear the whole list.
complete C P E
ArgumentDescriptionValues
Ccommandany command or alias
Ppathpath to search
Eextensionextension to match
The completion will work on the first word of your console input.

Example: complete demo "demos" dmoIf you enter "/demo " and press TAB you will cycle through all available demos.

Example: alias mapcomplete [complete $arg1 "packages/maps" cgz]helper alias for quickly adding complete-definitions for all gamemodes - see config/script.cfg (below "Auto-Completions")

connect N O P
Connects to a server.
ArgumentDescriptionValues
Nthe address of the server (hostname or IP) (optional)
Othe port (optional)
Pthe server password (optional)
If the server name is omitted, the client will try to connect to an available server in the LAN. If the port is omitted or set to 0, the default port will be used.

Example: connect 127.0.0.1 555 myServerPassword

Connects to a server and tries to claim admin state.
ArgumentDescriptionValues
Nthe address of the server (hostname or IP) (optional)
Othe port (optional)
Pthe admin password
This command will connect to a server just like the command 'connect' and try to claim admin state. If the specified password is correct, the admin will be able to connect even if he is locked out by ban, private master mode or taken client slots. If successfully connected, bans assigned to the admin's host will be removed automatically. If all client slots are taken a random client will be kicked to let the admin in.
If the server name ist omitted, the client will try to connect to an available server in the LAN. If the port is omitted or set to 0, the default port will be used.

Example: connectadmin 127.0.0.1 777 myAdminPasswordconnect as admin on port 777 of localhost

Example: connectadmin "" 0 myAdminPasswordwill try to connect to a LAN server on the default port as admin with the given password of "myAdminPassword".

Returns the server's current autoteam state.
Returns the current map being played.
ArgumentDescriptionValues
Iclean0, 1
If you pass it a non-zero value, the result will be path-less.

Example: echo playing: (curmap) vote for: (curmap 1)output: playing maps/ac_complex vote for: ac_complex

see also: curmode, map, mode
Current map revision number.
Description ValuesRangeDefault
-1..01
Returns the server's current mastermode state.
Returns the mode number for the current game.
see also: curmap, map, mode
Checks the current game mode for certain attributes.
ArgumentDescriptionValues
Aattribute name
Possible attributes are: team, arena, flag and bot.
Returns the weapon-index the local player currently has selected as primary.
This is not the same as curweapon - which could be a grenade or the knife.
Returns 1 if the local player has admin privileges, 0 otherwise.
Returns information on the current server - if you're connected to one.
ArgumentDescriptionValues
Iinfo0, 1, 2, 3, 4, 5, 6, 7, 8
If I is 0 (omitted or any other value than the ones below) you will get a string with 'IP PORT'
If I is 1,2 or 3 you will get the IP, HostName or port respectively.
If I is 4 you get a string representing the current state of the peer - usually this should be 'connected'.
FIXME:TODO: 5=SERVERNAME, 6,7=description, 8=serverbrowser-line -- these are to be handled with caution, sometimes empty, #8 will be outdated w/o serverbrowser open.

Example: echo [I am (curserver 4) to (curserver 2)]Output: I am connected to ctf-only.assault-servers.net

Example: last_server = "" remember_server = [ if (strcmp (curserver 4) "connected") [ last_server = (curserver 0) echo "I'm remembering:" $last_server ] [ echo "you are not 'connected' - you" (concatword "are '" (curserver 4) "' !") ] ] bind PRINT [ if (strcmp $last_server "") [ remember_server ] [ say (concat "^L2I was just ^Lfon^L3" $last_server) last_server = "" ] ]This will either remember or retrieve the last server you pressed the PrintScreen-key on.

Returns an integer indicating what team a client is currently on.
ArgumentDescriptionValues
Cclient number (optional)returns the specified client's team instead
Returns 0 for CLA, 1 for RVSF.
Returns 2 for CLA-spectator, 3 for RVSF-spectator.
Returns 4 for spectator.
By default this command returns what team *you* (player1) are currently on.
see also: team, forceteam, skin
Returns the weapon-index the local player is currently holding.
demo S
Plays a recorded demo.
ArgumentDescriptionValues
Sthe demo name
Playback is interpolated for the player whose perspective you view.
see also: setmr, rewind
Leaves a server.
Downloads and loads the specified map from an available packages source server.
ArgumentDescriptionValues
Sthe name of the map
see also: getmap, sendmap
Draws a shooting line in the direction of all available bots.
ArgumentDescriptionValues
this command does not take any argumentsnone
This is a debugging command and only works for single player modes.
drawzone X1 X2 Y1 Y2 C
Draws a zone marker with the specified color and dimensions on the minimap/radar. This is primarily intended for the survival mode.
ArgumentDescriptionValues
X1X-coordinate - top-left corner
X2X-coordinate - bottom-right corner
Y1Y-coordinate - top-left corner
Y2Y-coordinate - bottom-right corner
Ca color for the zone, in hexadecimal notationdefault: 0x00FF00 (green)
You can draw a few zones at a time. They will be reset (i.e. removed) once a new game starts.
Note that the coordinates must be specified as integers, not as floating-point values.
see also: resetzones, survival
Drops the enemy flag.
Maximum time span between player animation and the playback of the footstep sound
Token Description ValuesRangeDefault
Ttime span5..400015
If the footstep sound would be played immediately when entering the radius of the other player, it would not be synchronous to the player model animation.
Indicates if the footsteps sound should be played
Token Description ValuesRangeDefault
Benable footsteps1 (true), 0 (false)0..11
Sets the gamespeed in percent.
Token Description ValuesRangeDefault
Nthe game speed10..1000100
This does not work in multiplayer. For entertainment purposes only :)
see also: changespeed
Returns the time (in milliseconds) of the currently played game. READ ONLY

Example: showtime = [ if (> $lastgametimeupdate 0) [ gmr = (- $gametimemaximum (+ $gametimecurrent (- (millis) $lastgametimeupdate))) gsr = (div $gmr 1000) gts = (mod $gsr 60) if (< $gts 10) [ gts = (concatword 0 $gts) ] [ ] gtm = (div $gsr 60) if (< $gtm 10) [ gtm = (concatword 0 $gtm) ] [ ] echo (concatword $gtm : $gts) remaining ] [ echo gametime not updated yet ] ]

Returns the maximum time (in milliseconds) of the currently played game. READ ONLY
Returns the time (in milliseconds) when the last map was loaded.
Returns the current game mode number.
getdemo X P
ArgumentDescriptionValues
Xnumber in list
Psubpath (optional)
see also: listdemos
getmap S C
Retrieves the last map that was sent to the server using 'sendmap'.
ArgumentDescriptionValues
Sthe name of the map
Ccubescript to execute once map is installed (optional)
If the command is passed an argument, different than the map being played, the game tries to download the specified map from an available packages source server.
see also: sendmap, dlmap
Toggles between your primary weapon and grenades. (must be binded to a key)
see also: sndtoggle, knftoggle
Switches to grenades. (if available) (must be binded to a key)
see also: primary, secondary, melee
Determines if the local player (you) are currently carrying a primary weapon.
Returns 0 (false) or 1 (true).

Example: add2bind MOUSE1 [ if (hasprimary) [ echo you attacked with a primary weapon ] ]Everytime you press the left mouse button, assuming you are carrying your primary weapon, the above echo will be executed.

Token Description ValuesRangeDefault
B0..10
Plays a sound upon every successful hit if enabled.
Token Description ValuesRangeDefault
Boff OR on0 (disabled), 1 (server), 2 (local)0..20
If hitsound is set to 2, the sound will be played instantly rather than after server acknowledgment.
Enables or disables the processing of the bots artificial intelligence
ArgumentDescriptionValues
Toff OR on0||1

Example: idlebots 1Will make the bots stand still.

Example: idlebots 0Will enable the bots to move and shoot.

Ignore a player.
ArgumentDescriptionValues
Aclient number
You won't see any further game chat or hear any more voice com messages from that player.
Ignores all clients currently on the server. (only works in multiplayer)
Ignores all clients on the enemy team.
Ignores all clients on the specified team.
ArgumentDescriptionValues
Tthe team to ignore0 or 1 || cla or rvsf
Determines if the local player is standing in water or submerged.
ArgumentDescriptionValues
Tcheck if submerged instead?min 0/max 1/default 0

Example: if (inWater) [echo in water] [echo not in water]Example output: in water

Example: if (inWater 1) [echo submerged] [echo not submerged]Example output: not submerged

Makes an input perform a certain command.
ArgumentDescriptionValues
Iinput
Ccommand
Pprompt
Determines if the client number given is a valid client (player).
ArgumentDescriptionValues
Cclient number

Example: echo (isclient 0)Example output: 1

Example: echo (isclient 32)Example output: 0

Kicks all bots out of the current game.
ArgumentDescriptionValues
this command does not take any argumentsnone
Kicks the bot with the given name out of the current game.
ArgumentDescriptionValues
Nbotnamename of the bot to kick.

Example: kickbot RobbieWill make the bot named "Robbie" dissapear from the current game.

Toggles between your primary weapon and your knife. (must be binded to a key)
see also: sndtoggle, gndtoggle
Returns the last time (in milliseconds) the gametime was updated. READ ONLY
Returns the name of the last player you aimed at.
Returns nothing "" if you have not yet aimed at a player.
Get the game demos listing from the server we are currently connected.
see also: getdemo
Print a list of all players that you are currently ignoring.
Print a list of all players that you have muted.
Loads a crosshair for argument T.
ArgumentDescriptionValues
Iimage
Ttypeall, scope, teammate, knife, pistol, carbine, shotgun, smg, sniper, ar, cpistol, grenades, akimbo

Example: loadcrosshair red_dot.pngLoads the red_dot.png crosshair for all weapons.

Example: loadcrosshair red_dot.png allSame as above. Loads the red_dot.png crosshair for all weapons.

Example: loadcrosshair red_dot.png knifeLoads the red_dot.png crosshair for your knife only.

Example: loadcrosshair red_dot.png arLoads the red_dot.png crosshair for your assault rifle only.

Example: loadcrosshair red_dot.png scopeLoads the red_dot.png crosshair for your sniper rifle scope only.

Indicates if the footsteps sound for the local player should be played
Token Description ValuesRangeDefault
Benable footsteps1 (true), 0 (false)0..11
Returns contents of current magazine.
ArgumentDescriptionValues
Nthe weapon number
A knife will always return 1.
Weapons that aren't available will return -1.
Returns contents of magazine reserve.
ArgumentDescriptionValues
Nthe weapon number
map M
Loads up a map in the gamemode set previously by the 'mode' command.
ArgumentDescriptionValues
MName of the map to loadstring
If connected to a multiplayer server, it votes to load the map (others will have to type "map M" as well to agree with loading this map). To vote for a map with a specific mode, set the mode before you issue the map command.
A map given as "blah" refers to "packages/maps/blah.cgz", "mypackage/blah" refers to "packages/mypackage/blah.cgz". At every map load, "config/default_map_settings.cfg" is loaded which sets up all texture definitions, etc. Everything defined there can be overridden per package or per map by creating a "mapname.cfg" which contains whatever you want to do differently from the default.
When the map finishes it will load the next map when one is defined, otherwise it reloads the current map. You can define what map follows a particular map by making an alias like (in the map script): alias nextmap_blah1 blah2 (loads "blah2" after "blah1").
returns the mapname
outputs the mapsize.
If this alias exists it will be run every time the game starts a new map.

Example: mapstartalways = [ echo "------------------------------" ] This will output the string and override any other actions that might've been defined.

Example: addOnLoadAlways [ echo "------------------------------" ] This will output the string after any previously defined actions have run.

If this alias exists it will be run when the game starts a new map, then it is deleted.

Example: mapstartonce = [ echo "------------------------------" ] This will output the string and override any other actions that might've been defined.

Example: addOnLoadOnce [ echo "------------------------------" ] This will output the string after any previously defined actions have run.

Token Description ValuesRangeDefault
V1..322
Token Description ValuesRangeDefault
V1..321
me ...
Action chat message.
ArgumentDescriptionValues
......
Switches to your knife. (must be binded to a key)
Returns the remaining minutes of the currently played game. READ ONLY
modconnect A B C
Connect to a modded server.
ArgumentDescriptionValues
AIP
Bport
Cpassword
The modified server needs to use the original client-server protocol. The protocol version number will be the negated value of an unmodded server.
Connect to a modded server and claim admin.
ArgumentDescriptionValues
AIP
Bport
Cadmin password
The modified server needs to use the original client-server protocol. The protocol version number will be the negated value of an unmodded server.
Returns the mode number for a specified mode acronym.
ArgumentDescriptionValues
Mthe mode acronym
Returns -1 if not found.

Example: echo (modenum ctf)Output: 5

Example: echo (modenum btosok)Output: 21

Connect to a modified LAN server.
The modified server needs to use the original client-server protocol. The protocol version number will be the negated value of an unmodded server.
change name of directory used for bounce model number N
These setting should be loaded from config/autoexec.cfg, but they work on-the-fly too.
If the model fails to load you will end up with nothing being displayed; use delalias to get back to default

Example: modmdlbounce0 = misc/my_gib1This will make the gib 1 model use the data inside packages/models/misc/my_gib1

Example: modmdlbounce1 = misc/my_gib2This will make the gib 2 model use the data inside packages/models/misc/my_gib2

Example: modmdlbounce2 = misc/my_gib3This will make the gib 3 model use the data inside packages/models/misc/my_gib3

Example: modmdlbounce3 = weapons/grenade2/staticThis will make the grenade static model use the data inside packages/models/weapons/grenade2/static

change name of directory used for pickup model number N
These setting should be loaded from config/autoexec.cfg, but they work on-the-fly too.
If the model fails to load you will end up with nothing being displayed; use delalias to get back to default

Example: modmdlpickup3 = health2This will make the health pickup model use the data inside packages/models/pickups/health2

Example: modmdlpickup1 = my_ammoboxThis will make the ammobox pickup model use the data inside packages/models/pickups/my_ammobox

change name of directory used for weapon model (viewable/world) number N
change name of directory used for weapon model (hudgun) number N
These setting should be loaded from config/autoexec.cfg, but they work on-the-fly too.
If the model fails to load you will end up with nothing being displayed; use delalias to get back to default

Example: modmdlweap4 = my_subgun This will make the subgun hudgun model use the data inside packages/models/weapon/my_subgun

Mute a player
ArgumentDescriptionValues
Aclient number
You won't hear any further voice com messages from that player.
name N
Sets the nick name for the local player.
ArgumentDescriptionValues
Nthe name
Returns the primary weapon on next respawn.
ArgumentDescriptionValues
Aweapon idvalue
adds a command to complete nicknames on
your own nick will be ignored

Example: nickgreet = [ say (concat "Hello," (concatword $arg1 "!")) ]; nickcomplete nickgreetwith this you can enter "/nickgreet " and cycle via TAB to the nickname you want to greet.

see also: complete
onAttack weapon
If defined, this will be executed each time you shot a bullet, throw a grenade or use your knife.
ArgumentDescriptionValues
weaponThe weapon that was used
If this alias exists it will be run every time a vote is called.
If this alias exists it will be run every time a vote is changed.
see also: onCallVote, onVoteEnd
onConnect player
If defined, this will be executed when you or another player join(s) a server.
ArgumentDescriptionValues
playerThe client number of the player who connectedinteger (-1 for local player)
onDisconnect player
If defined, this will be executed when you or another player disconnect(s) from a server.
ArgumentDescriptionValues
playerThe client number of the player who disconnectedinteger (-1 for local player)
onFlag action actor flag
If defined, this will be executed each time a flag action occurs.
ArgumentDescriptionValues
actionThe action that occuredinteger (0 = stolen, 1 = dropped, 2 = lost, 3 = returned, 4 = scored, 5 = ktfscore, 6 = failed to score, 7 = reset)
actorThe client number of the actorinteger
flagThe flag owner teaminteger (0 = CLA, 1 = RVSF)
onHit actor target damage gun gib
If it's defined, this alias will be executed each time a damage is done.
ArgumentDescriptionValues
actorThe client number of the actorinteger
targetThe client number of the targetinteger
damageThe damage doneinteger
gunThe number of the gun usedinteger
gibIs it a gib or a normal fraginteger (0 or 1)
onKill actor target gun gib
If it exists, this alias will be executing when any player get killed, receiving a few arguments :
ArgumentDescriptionValues
actorThe client number of the actorinteger
targetThe client number of the targetinteger
gunThe number of the gun usedinteger
gibIs it a gib or a normal fraginteger (0 or 1)
If this alias exists, it will be automatically executed on the last minute remaining mark.
onNameChange player new name
If defined, this will be executed when you or another player change(s) his name.
ArgumentDescriptionValues
playerThe client number of the player who connectedinteger
new nameThe new name of the clientstring
The alias is executed before the name is effectively changed, so you can still get the previous name of the client from this alias.
onPickup item q
If defined, this will be executed each time you pick up an item.
ArgumentDescriptionValues
itemThe item that was picked upinteger (0 = pistol clips, 1 = ammo box, 2 = grenade, 3 = health, 4 = helmet, 5 = armour, 6 = akimbo)
qThe quantity that was received
If defined, this will be executed each time you reload a weapon.
ArgumentDescriptionValues
Bwas autoreload?0 (false), 1 (true)
onSpawn player
If defined, this will be executed each time a player spawns.
ArgumentDescriptionValues
playerThe client number of the player who spawnedinteger
If this alias exists it will be run every time a vote passes or fails.
If defined, this will be executed each time you switch to a different weapon.
ArgumentDescriptionValues
wThe weapon ID that you switched to
Determines if the game should be paused.
Token Description ValuesRangeDefault
Bpause game0..10
pm C L
Sends a private message to a specified client.
ArgumentDescriptionValues
CClient number
LList of strings
see also: say, quickanswer
Returns the weapon-index the local player was previously holding.
Switches to your current primary weapon. (must be binded to a key)
see also: secondary, melee, grenades
Returns the score statistics for the player with the given clientnumber.
ArgumentDescriptionValues
Cclient0..N

Example: echo (pstat_score 0) Output: 0 5 3 43 1 1 unarmedThe output is a list of FLAGS, FRAGS, DEATHS, POINTS, TEAM, TEAMKILLS, and NAME.

Returns the shot statistics for the player with the given clientnumber.
ArgumentDescriptionValues
Cclient0..N
The list is:
knife/atk dmg pistol/atk dmg carbine/atk dmg shotgun/atk dmg smg/atk dmg sniper/atk dmg assault/atk dmg cpistol/atk dmg nade/atk dmg akimbo/atk dmg

Example: echo (pstat_weap 0) Output: 0 0 0 0 0 0 0 0 0 0 1 240 15 312 0 0 3 112 0 0The output is a list of tuples for all weapons, SHOTS-FIRED and DAMAGE-DEALT for each.

Easily respond the the last client who sent you a private message.
see also: pm
Disconnects then reconnects you to the current server.
ArgumentDescriptionValues
Pthe server password (optional)
Reloads the weapon.
ArgumentDescriptionValues
Avalue
Resets the list of packages source servers where to download custom content from.
The list of servers is saved into config/pcksources.cfg on game quit.
Reset all drawn zones.
see also: drawzone, survival
Rewind the current demo to S seconds ago.
ArgumentDescriptionValues
Sthe number of seconds to rewind
Note: you can use a negative value to forward.
see also: demo, setmr
say S...
Outputs text to other players.
ArgumentDescriptionValues
S...the text
If the text begins with a percent character (%), only team mates will receive the message.
Puts a prompt on screen.
ArgumentDescriptionValues
S...the text to display in the prompt (optional)
This puts a prompt on screen that you can type into, and will capture all keystrokes until you press return (or ESC to cancel). If what you typed started with a "/", the rest of it will be executed as a command, otherwise its something you "say" to all players.

default keys:

T - opens empty prompt

` - opens a command prompt /

TAB - autocompletes commands/variables/aliases

UP - browse command history forwards

DOWN - browse command history backwards

Determines the FOV when scoping.
Token Description ValuesRangeDefault
V5..6050
see also: fov
Switches to your secondary weapon. (must be binded to a key)
see also: primary, melee, grenades
ArgumentDescriptionValues
Cclientnumwhich player to follow
Go to a predefined number of minutes before the end of the game while watching a demo.
ArgumentDescriptionValues
Mthe minutes remaining to skip to
see also: demo, rewind
will display a scope for the sniper-rifle. used in the zoom-script (config/scripts.cfg [l. 92ff "alias zoom"]
ArgumentDescriptionValues
Yscope on?0||1
shifts your selected weapon by a given delta. By default the mouse-wheel shifts one up or down according to your scroll direction.
ArgumentDescriptionValues
Ddelta-N..-1,+1..N

default keys:

MOUSE4 - cycle one up

MOUSE5 - cycle one down

Determines if the mini-map should be shown on screen.
Token Description ValuesRangeDefault
Bshow mini-map0..10
change wether to have a see-through map overview (0), or render it on a black backdrop (1) or a combination of both (2)
Token Description ValuesRangeDefault
Bbackdrop-style0..20
Transparency of the black map backdrop (in percent) rendered if showmapbackdrop is set to 2.
Token Description ValuesRangeDefault
Ttransparency0..10075
see also: showmapbackdrop
Shows or hides the scores.

default key: TAB

Determines if scores should be shown on death.
Token Description ValuesRangeDefault
V0..11
skin N
Determines the skin of the current player.
ArgumentDescriptionValues
Nskin idvalue
See the player model folder for the according skin-id.
Choose skin when playing for team CLA.
ArgumentDescriptionValues
Nskin id
Choose skin when playing for team RVSF.
ArgumentDescriptionValues
Nskin id
Toggles between your primary weapon and your secondary weapon. (must be binded to a key)
see also: knftoggle, gndtoggle
Sorts the available packages source servers by ascendant ping. The fastest to reach is then used by default.
Toggles spectator mode.
Sets the desired spectating mode.
ArgumentDescriptionValues
Mthe mode2 (1st-person), 3 (3rd-person), 4 (3rd-person transparent), 5 (free flying), 6 (overview)

default key: SPACE - switch spectator mode

If this alias exists it will be run when the game reaches intermission.

Example: start_intermission = [ echo "INTERMISSION - STATISTICS TIME" loop p 255 [ pn = (findpn $p) if (strcmp $pn "") [ ] [ echo (concatword Player $p ":") (pstat_score $p) ":" (pstat_weap $p) ] ] echo "------------------------------" ] This will output the full statistics line for all players.

Stops any demo recording or playback.
Kills your player. You will lose 1 frag point and receive 1 death point when using this command.
Prepares a round of bot survival mode on the specified map.
ArgumentDescriptionValues
Mthe map to use
Dthe difficulty (optional)0 = easy, 1 = intermediate, 2 = hard, 3 = impossible
All official maps are compatible with survival, if you want to play survival on a custom map, prior edits/additions to the script are necessary, such as adding a zone for that specific map.
team S
Sets the team for the local player.
ArgumentDescriptionValues
Sthe team nameeither CLA or RVSF or SPECTATOR

Example: team CLA

cycles through all available spectator modes. Follow-1stPerson, Follow-3rdPerson, Follow-3rdPerson-transparent and Fly.

default key: SPACE - cycle spectator modes

Unignores all clients currently on the server. (only works in multiplayer)
ArgumentDescriptionValues
Ssoundmust be a registered voicecom-sound
Ttext

default key: V - opens the voicecom menu, use number keys for your choice

Enables or disables voicecom audio.
ArgumentDescriptionValues
0 (off)
1 (always play voicecom audio)
2 (only play voicecom audio from you and your teammates)
vote V
agree or disagree to the currently running vote
ArgumentDescriptionValues
Vvote value1 (yes) OR 2 (no)

default keys:

F1 - votes YES

F2 - votes NO

votemap I M
Sets the next gamemode then calls a vote for a map.
ArgumentDescriptionValues
Imode id
Mmap name
Determines if there is a vote pending or not.

Example: echo $votependingOutput: if there is currently a vote pending, returns 1, else returns 0.

Returns 1 when the current game is being played from a demo, else 0.

Example: echo I am (at [not now] (watchingdemo)) watching a demo. "so, are you?"

Return value: truth value

Changes the weapon.
ArgumentDescriptionValues
Nthe weapon number0 (knife), 1 (pistol), 2 (shotgun), 3 (sub), 4 (sniper), 5 (assault), 6 (grenades)
get the IP address of a given clientnumber - only admins get shown the last octet
ArgumentDescriptionValues
Cclientnum
Determines if bot waypoints should be selected/placed using the crosshair or by the nearest location to your player.
Token Description ValuesRangeDefault
VNote: This is turned on by default.0..11

Game modes

coop M
Starts a map with the mode "Co-op edit"
ArgumentDescriptionValues
MThe name of the map you wish to edit
See the co-op edit section in page 4 of the map editing guide for more information.

Example: coop ac_newmap

ctf M T
Starts a map with the mode "Capture the Flag"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 15 minutes if T is 0 or not specified)1..60

Example: ctf ac_mines

dm M T
Starts a map with the mode "Deathmatch"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 10 minutes if T is 0 or not specified)1..60

Example: dm ac_complex

ArgumentDescriptionValues
Mmodeinteger
Ddescriptionstring
htf M T
Starts a map with the mode "Hunt the Flag"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 15 minutes if T is 0 or not specified)1..60

Example: htf ac_mines

ktf M T
Starts a map with the mode "Keep the Flag"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 10 minutes if T is 0 or not specified)1..60

Example: ktf ac_mines

lms M T
Starts a map with the mode "Last Man Standing"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 10 minutes if T is 0 or not specified)1..60

Example: lms ac_complex

lss M T
Starts a map with the mode "Last Swiss Standing"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 10 minutes if T is 0 or not specified)1..60

Example: lss ac_complex

mode N
Sets the gameplay mode to N for the next map loaded.
ArgumentDescriptionValues
NTeam Deathmatch0
Co-op edit1
Deathmatch2
Survivor3
Team survivor4
Capture the Flag5
Pistol frenzy6
Bot team deathmatch7
Bot deathmatch8
Last swiss standing9
One shot, One kill10
Team One shot, One kill11
Bot One shot, One kill12
Hunt the Flag13
Team keep the flag14
Keep the flag15
You will need to define mode before loading the map or it will stay as the last mode played.
There are many aliases for you to use instead of remembering the numeric mapping.

Example: mode 7; map ac_complex; echo "Bot Team Deathmatch on ac_complex"

Example: mode 8; map ac_mines 4; echo "Bot Deathmatch on ac_mines for 4 minutes"

Example: mode 5; map ac_shine; echo "CTF @ ac_shine"

see also: map, gamemode, tdm, coop, dm, ts, ctf, pf, lss, osok, tosok, htf, tktf, ktf, Gamemodes
osok M T
Starts a map with the mode "One shot, One kill"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 10 minutes if T is 0 or not specified)1..60

Example: osok ac_complex

pf M T
Starts a map with the mode "Pistol Frenzy"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 10 minutes if T is 0 or not specified)1..60

Example: pf ac_complex

tdm M T
Starts a map with the mode "Team Deathmatch"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 15 minutes if T is 0 or not specified)1..60

Example: tdm ac_complex

tktf M T
Starts a map with the mode "Team Keep the Flag"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 15 minutes if T is 0 or not specified)1..60

Example: tktf ac_mines

tosok M T
Starts a map with the mode "Team One Shot, One Kill"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 15 minutes if T is 0 or not specified)1..60

Example: tosok ac_complex

ts M T
Starts a map with the mode "Team Survivor"
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 15 minutes if T is 0 or not specified)1..60

Example: ts ac_complex

vip M T
Starts a map with the mode "Hunt the Flag". Some players prefer the name "VIP" for this mode.
ArgumentDescriptionValues
MThe name of the map you wish to play
TThe time limit, in minutes (default 15 minutes if T is 0 or not specified)1..60

Example: vip ac_mines

Visuals

This section describes identifiers to configure the visuals.

Sets the size/resolution of the dynamic shadow data.
Token Description ValuesRangeDefault
the size0..32
Sets the size for the icon shown above a player using comunications voices.
Token Description ValuesRangeDefault
VIcon size0..100050
Sets the time available for interpolation between model animations.
Token Description ValuesRangeDefault
Nthe amount of milliseconds for the interpolation0..1000100
Token Description ValuesRangeDefault
V0..10
Token Description ValuesRangeDefault
V0..11
Turn on and off the display of blood.
Token Description ValuesRangeDefault
VEnable/Disable blood0..11
Sets the amount of time in milliseconds that blood is displayed on the ground.
Token Description ValuesRangeDefault
VBlood display time0..3000010000
Turns on/off the display of bullet holes
Token Description ValuesRangeDefault
VEnable/Disable bullet holes0..11
Specifies how long (in milliseconds) to display bullet holes.
Token Description ValuesRangeDefault
VBullethole display time0..3000010000
Smoothly changes your gamma to the specified value.
ArgumentDescriptionValues
Gthe gamma to change to
Mmilliseconds between gamma changes

Example: changegamma 300 30Every 30 milliseconds your gamma is changed by 1 until it reaches its goal of gamma 300.

see also: gamma, changespeed
Sets the bits per pixel value.
Token Description ValuesRangeDefault
bits per pixel0..320
show the blood-spat overlay when receiving damage?
Token Description ValuesRangeDefault
Ndamagescreen0 (false), 1 (true)0..11
if overlay of blood-spat, at what blending (transparency) level?
Token Description ValuesRangeDefault
Ndamagescreen transparency1..10045
if overlay of blood-spat, use which factor?
Token Description ValuesRangeDefault
Ndamagescreen factor1..1007
if overlay of blood-spat, at what speed does it fade?
Token Description ValuesRangeDefault
Ndamagescreen fade0..1000125
Token Description ValuesRangeDefault
V0..10
Displays local player's current x,y,z position in map, showstats 1 must be enabled.
Token Description ValuesRangeDefault
Vdisplay current position0..10
Token Description ValuesRangeDefault
V0..20
Token Description ValuesRangeDefault
V0..10
Token Description ValuesRangeDefault
V0..10
Sets the bits for the depth buffer.
Token Description ValuesRangeDefault
depth pixels0..320
Token Description ValuesRangeDefault
V..0.005f
Enables or disables the per official map dynamic gamma system.

Example: dyngamma = 0Output: disables the system

Example: dyngamma = 1Output: enables the system

see also: gamma, setgamma
Determines whether dynamic shadows and lights are rendered, provided just incase they slow your fps down too much.
Token Description ValuesRangeDefault
Rthe radius of a dynamic light0..3216
With radius you can specify the radius of a dynamic light, smaller to maybe gain some speed (0 is off entirely), or bigger to see the effect of dynamic shadows more dramatically (try shooting it past some pillars that have a dark area on the other side... or use the "gamespeed" variable).
Sets the alpha value (transparency) for dynamic shadows.
Token Description ValuesRangeDefault
the alpha value0..10040
Token Description ValuesRangeDefault
V0..30001000
Token Description ValuesRangeDefault
V0..10
Sets the display size of the dynamic shadows.
Token Description ValuesRangeDefault
the size4..85
font NAME PATH A B C D E F
Loads a font texture to use as text within AssaultCube.
ArgumentDescriptionValues
NAMEThe font name.
PATHThe path to the font texture.
AThe default width.
BThe default height.
COffset (co-ordinate X).
DOffset (co-ordinate Y).
EOffset (width).
FOffset (height).
fontchar A B C D
Specify a region of an image to be used as a font character
ArgumentDescriptionValues
AX co-ordinates (from top-left corner).
BY co-ordinates (from top-left corner).
CWidth.
DHeight.
fov N
Sets the field of view (fov).
Token Description ValuesRangeDefault
Nthe FOV value75..12090
Sets the field of view (fov) based on the rules of AC v0.93
ArgumentDescriptionValues
AFOV degree
This command is supplied for backward compatibility.
(descripton unavailable)
ArgumentDescriptionValues
Amin
Bmax
set the frag message corresponding to a weapon (appearing on the hud or in server logs)
ArgumentDescriptionValues
Gthe integer of the gun 0 = knife, etc.
Mthe message you want to appearex : sniped
This command can be read by both client and server, but the server can't read the cfg if it contains anything else than fragmessage or gibmessage calls.

Example: fragmessage 5 sniped // set "sniped" message for frags with sniper. It will display "you sniped unarmed" on the hud when you frag unarmed with sniper. In server logs you will get "[127.0.0.1] killer sniped unarmed".

Sets the level of fullscreen antialiasing (FSAA).
Token Description ValuesRangeDefault
fsaa0..160
Sets the level of brightness to use when using the command "/fullbright 1".
Token Description ValuesRangeDefault
VLight intensity level0..255176
Enables or disables fullscreen.
Token Description ValuesRangeDefault
fullscreen0..11
Not supported on Windows and Mac.
Sets the hardware gamma value.
Token Description ValuesRangeDefault
Nthe gamma value30..300100
May not work if your card/driver doesn't support it.
see also: changegamma
gib B
Enables or disables the gib animation entirely.
Token Description ValuesRangeDefault
Boff OR on0 (false), 1 (true)0..11
set the gib message corresponding to a weapon (appearing on the hud or in server logs)
This command is identical to fragmessage (above)
Sets the number of gibs to display when performing a "messy" kill (grenade, knife, sniper headshot).
Token Description ValuesRangeDefault
Nnumber of gibs0..10006
Larger values are more spectacular, but can slow down less powerful machines. Reducing gibttl may help in this case.
see also: gibttl, gibspeed
Adjusts gib/gibnum/gibspeed/gibttl variables collectively.
ArgumentDescriptionValues
0 - Off
1 - Default/Normal values
2 - Good
3 - Messy
4 - Unrealistic
Sets the velocity at which gibs will fly from a victim.
Token Description ValuesRangeDefault
Nvelocity1..10030
see also: gibnum, gibttl
Sets the time for gibs to live (in milliseconds), after which they will disappear.
Token Description ValuesRangeDefault
Ntime to live0..150005000
see also: gibnum, gibspeed
checks for the searchstring in all loaded extensions
ArgumentDescriptionValues
Eextension

Example: if (glext shadow_funcs) [echo you have shadow functionality] [echo no shadows for you]

Defines the health level at or below which a heartbeat sound will be played. A value of 0 (which is the default) disables this feature.
Token Description ValuesRangeDefault
Hhealth value0..990
Controls whether textures with a scale higher than 1.0 will be scaled down while loading to increase performance (0) or stay at higher resolution (1).
Token Description ValuesRangeDefault
Sscale down?0..11
see also: texture
The maximum texture size (in pixels) supported by the graphics hardware.
Token Description ValuesRangeDefault
Vmax. hardware texture size1..00
Allows to finetune the amount of "error" the mipmapper/stripifier allow themselves for changing lightlevels.
Token Description ValuesRangeDefault
Ethe error value, 1 being the best quality1..1008
If this variable is changed this during play, a "recalc" is needed to see the effect.
see also: recalc
change at what position to truncate the map title string
Token Description ValuesRangeDefault
Nchars0..25546
The maximum texture (if less than hwtexsize) that will actually be used by the engine, larger textures will be scaled down. 0 removes this limit.
Token Description ValuesRangeDefault
Vmax. texture size0..40960
see also: hwtexsize
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..11
Scales all particles.
Token Description ValuesRangeDefault
Pthe scale percentage20..500100
Token Description ValuesRangeDefault
V..-3.0f
Token Description ValuesRangeDefault
V..-3.0f
make dead players instantly pop out of existence, instead of falling over and sinking into the ground.
Token Description ValuesRangeDefault
BBOOL0..10
Token Description ValuesRangeDefault
V0..1003
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V6..108
Resets the OpenGL rendering settings
Sets if dynamic shadows should be saved to disk.
Token Description ValuesRangeDefault
auto save0..11
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..3000010000
Whether a special monospace font should be used to render the text on the scoreboard.
Token Description ValuesRangeDefault
Mnormal (0) or monospace (1)0..10
Sets the screen height.
Token Description ValuesRangeDefault
the screen height0..76810000
Sets the screen width.
Token Description ValuesRangeDefault
the screen width0..102410000
Changes the screen resolution
ArgumentDescriptionValues
Wwidth
Hheight
Changes the current font.
ArgumentDescriptionValues
NFont namename of the font
Sets the current map's default dynamic gamma.
ArgumentDescriptionValues
Gthe gamma value
The setting will take affect automatically if dyngamma is enabled, upon future loads of that map. This command only works on official maps!
Rather than manually loading each official map and setting it's default gamma with this command, the entire list can be initialized via your autoexec.cfg like so:

Example: checkinit afterinit [ofc_gamma_list = [175 225 150 120 ...]] Sets your custom gamma values for the per official map dynamic gamma system. If you are going to use this method, you MUST include values for every existing official map. The list must be alphabetical and be the exact length of the number of currrent official maps. Hint: use "echo $defaultmaps" and "echo (listlen $defaultmaps)".

see also: dyngamma, gamma
Token Description ValuesRangeDefault
V1..00
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..1000075
Token Description ValuesRangeDefault
V0..11
Specifies the Field Of View when in spectating/ghost mode.
Token Description ValuesRangeDefault
VSpectate FOV size5..120110
Token Description ValuesRangeDefault
V0..320
Sets the transparency/opacity level of stencil shadows.
Token Description ValuesRangeDefault
VAlpha level0..10040
Sets the team display mode.
Token Description ValuesRangeDefault
Nthe team display mode0 (none), 1 (color vests), 2 (color skins)0..21
In mode 0 team display is disabled In mode 1 players will be rendered with a colored vest to make the teams distinguishable. In mode 2 almost the whole suit of the players will be colored. These display modes are only applied in team gameodes.
Reduces the size of all texture by the selected factor:
Token Description ValuesRangeDefault
Sscale selection-1..30
Token Description ValuesRangeDefault
V0..11
Enables or disables vsync.
Token Description ValuesRangeDefault
vsync-1..1-1
-1 uses the default settings obtained from the system. 0 disables, 1 enables vsync.
Turns on/off the reflections in the water surface.
Token Description ValuesRangeDefault
Venable/disable water reflections0..11
Turns on/off water refractions.
Token Description ValuesRangeDefault
Venable/disable water refractions0..10
Determines the subdivision of the water surface in maps.
Token Description ValuesRangeDefault
Nthe subdivisioin value1..644
Must be a power of 2: 4 is the default, 8 is recommended for people on slow machines, 2 is nice for fast machines, and 1 is quite OTT. See "waterlevel" (edit reference) on how to add water to your own levels.

Heads-Up Display

This section describes the identifiers to configure the head-up display (HUD).

Time in milliseconds before the abovehead icon dissapears.
Token Description ValuesRangeDefault
Vabovehead icon display time1..100002000
Sets the number of text lines on an alternate F11 history display.
Token Description ValuesRangeDefault
V0..1000
see also: consize, fullconsize
Recreates the minimap for the current map.
see also: minimapres
Sets the display mode for the HUD clock.
Token Description ValuesRangeDefault
Ddisplay mode0..20
The clock shows game-time, it is either off (0) or counts backward (1) or forward (2).
colour of CN column in scoreboard
ArgumentDescriptionValues
0 (green)
1 (blue)
2 (yellow)
3 (red)
4 (gray)
5 (white, default)
6 (dark brown)
7 (dark red)
8 (purple)
9 (orange)
Sets how many seconds before the console text rolls (disappears) up the screen.
Token Description ValuesRangeDefault
Vtime before the text rolls up0..6020
Sets how many lines of text the console displays.
Token Description ValuesRangeDefault
V0..1006
Allows to browse through the console history by offsetting the console output.
ArgumentDescriptionValues
Nthe offset

default keys:

- on the keypad - scrolls into the history (conskip 1)

+ on the keypad - resets the history (conskip -1000)

Turns on or off crosshair effects.
Token Description ValuesRangeDefault
BTurns the effects on (1) or off (0)0..11
When on, the crosshair will go grey when the weapon is reloading, orange when health is 50 or red when is 25.
Sets the size of your crosshair.
Token Description ValuesRangeDefault
Nthe crosshair size0..5015
The crosshair is turned off entirely if the size is set to 0.
Turns on/off display of team warning crosshair.
Token Description ValuesRangeDefault
Venable/disable warning crosshair0..11
Set the level of transparency of the damage indicator, 0 = is fully transparent, 100 = totaly solid.
Token Description ValuesRangeDefault
Vdamage indicator alpha value1..10050
Sets the separation of the arrows in the damage indicator.
Token Description ValuesRangeDefault
Vdamage indicator separation size0..10000500
Sets the size of the damage indicator.
Token Description ValuesRangeDefault
Vdamage indicator icon size0..10000200
Sets how long the damage indicator stays on screen.
Token Description ValuesRangeDefault
Vdamage indicator display time1..100001000
Stores your current HUD configuration in a buffer and disables it entirely.
see also: cleanshot, enablehud
Restores your HUD configuration after using disablehud.
see also: cleanshot, disablehud
Sets the number of text lines on the F11 history display.
Token Description ValuesRangeDefault
V0..10040
see also: consize, altconsize
Hide big images in menus.
Token Description ValuesRangeDefault
N0: show, 1: hide0..10
Turns on/off the radar compass
Token Description ValuesRangeDefault
Venable/disable radar compass0..10
Turns on or off the display of console text.
Token Description ValuesRangeDefault
Venable/disable console text0..10
Turns on or off the display of flag icons.
Token Description ValuesRangeDefault
Venable/disable flag icons0..10
Turns on/off the damage indicator
Token Description ValuesRangeDefault
Venable/disable damage indicator0..10
Turns on or off the display of equipement icons.
Token Description ValuesRangeDefault
Venable/disable equipement icons0..10
Turns on or off the display of messages at the bottom of the screen.
Token Description ValuesRangeDefault
Venable/disable messages0..10
Turns on or off the display of the on-screen radar.
Token Description ValuesRangeDefault
Venable/disable radar0..10
Turns on or off the display of spectator staus.
Token Description ValuesRangeDefault
Venable/disable spectator status0..10
Turns on or off the display of local player team icons.
Token Description ValuesRangeDefault
Venable/disable team icons0..10
Turns on or off the display of vote icons.
Token Description ValuesRangeDefault
Venable/disable vote info0..20
Executes the specified command in the command line history.
ArgumentDescriptionValues
Nthe N'th command from the history
For example, binding "history 1" to a key allows you to quickly repeat the last command typed in (useful for placing many identical entities etc.)
Shows extra gameplay messages on certain events if connected to a server.
ArgumentDescriptionValues
0 (off)
1 (show extra messages in the console)
2 (show extra messages in the console and on the HUD)
3 (SPAM extra messages in the console and on the HUD)
Turns on or off the display of the current selected gun.
Token Description ValuesRangeDefault
Vshow/hide guns 3D models0..11
Sets the total number of text lines from the console to store as history.
Token Description ValuesRangeDefault
V10..1000200
Sets how many typed console commands to store.
Token Description ValuesRangeDefault
NTotal of stored commands0..100001000
This value sets how many command lines to store in memory, everytime a command is entered it gets store so it can be recalled using the "/" key along with the arrow keys to scroll back and forth through the list.
.
Token Description ValuesRangeDefault
V0..10001000
Sets the resolution for the minimap.
Token Description ValuesRangeDefault
Nthe resolution7..109
see also: clearminimap
Token Description ValuesRangeDefault
V0..10
Shows ammo statistics like version 1.0
Token Description ValuesRangeDefault
N0: new, 1: old0..10
Show the client number column on the scoreboard first?
Token Description ValuesRangeDefault
Ncn column order0 (false), 1 (true)0..10
Sets the icon size of the players shown in the radar and the minimap.
Token Description ValuesRangeDefault
Vsize of icons inside radar4..6412
change at what height you are floating in the radar-view
Token Description ValuesRangeDefault
Hheight5..500150
Token Description ValuesRangeDefault
V0..1000100
Token Description ValuesRangeDefault
V0..100040
Token Description ValuesRangeDefault
V1..102
Token Description ValuesRangeDefault
V0..10
Choose whether the players hand carrying the weapon appears as right or left handed.
Token Description ValuesRangeDefault
N0: lefty, 1: righty0..11
Sets the order priority for the column cn on the scoreboard.
Token Description ValuesRangeDefault
Vlow priority: left, high priority: right0..1006
Sets the order priority for the column deaths or disables it on the scoreboard.
Token Description ValuesRangeDefault
V-1: disable, low priority: left, high priority: right-1..1002
Sets the order priority for the column flags on the scoreboard.
Token Description ValuesRangeDefault
Vlow priority: left, high priority: right0..1000
Sets the order priority for the column frags on the scoreboard.
Token Description ValuesRangeDefault
Vlow priority: left, high priority: right0..1001
Sets the order priority for the column pj/ping or disables it on the scoreboard.
Token Description ValuesRangeDefault
V-1: disable, low priority: left, high priority: right-1..1005
Sets the order priority for the column name on the scoreboard.
Token Description ValuesRangeDefault
Vlow priority: left, high priority: right0..1007
Sets the order priority for the column ratio or disables it on the scoreboard.
Token Description ValuesRangeDefault
V-1: disable, low priority: left, high priority: right-1..100-1
Sets the order priority for the column score or disables it on the scoreboard.
Token Description ValuesRangeDefault
V-1: disable, low priority: left, high priority: right-1..1004
enables or disables the showing of game mode descriptions on the console after map starts.
Token Description ValuesRangeDefault
B0 off, 1 on0..11
Enables or disables showing the player's horizontal speed.
Token Description ValuesRangeDefault
N0 off, 1 on0..10
Turns on/off display of FPS/rendering statistics on the HUD.
Token Description ValuesRangeDefault
N0: Show no stats, 1: Only show FPS stats, 2: Show all stats0..21
enables or disables showing the player name on the HUD when in your crosshair.
Token Description ValuesRangeDefault
N0 off, 1 on0..11
Turns on/off the display of the hudgun while spectating a player in first-person view. Works in demo mode as well.
Token Description ValuesRangeDefault
Vshow/hide hudgun when spectating0..11
Token Description ValuesRangeDefault
V1..1000200
Token Description ValuesRangeDefault
V1..1000105
Token Description ValuesRangeDefault
V1..1000200
Token Description ValuesRangeDefault
V1..1000105

Sound

This section describes all identifiers related to music and sound effects.

The distance from the source emitting the sound to the listener.
Token Description ValuesRangeDefault
V0..1000000400
This value indicates the relative "strength" of a sound (how far away the sound can be heard.
Token Description ValuesRangeDefault
V0..1000000100
Enables or disables the audio subsystem in AC.
Token Description ValuesRangeDefault
Benable0..11
Enables verbose output for debugging purposes.
Token Description ValuesRangeDefault
Benable audio debug0..10
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..10008
Token Description ValuesRangeDefault
V0..100015
Token Description ValuesRangeDefault
V0..10008
Token Description ValuesRangeDefault
V0..11
Token Description ValuesRangeDefault
V0..100015
Each subsequent played sound's gain-value is scaled by this percentage.
Token Description ValuesRangeDefault
Npercentage0..100100
This lowers the gain of the sounds before they are mixed, this might be useful in cases when the mixer has problems with too high gain values.
Specifies the interval for checking mapsounds.
Token Description ValuesRangeDefault
Ninterval in milliseconds0..100050
If set to value 0, the map sounds will be checked in every frame without any interval limitation.
Token Description ValuesRangeDefault
V0..10040
music A B C
Play music in the background.
ArgumentDescriptionValues
Amusic file name
Bplaytime
Ccommand to be executed, when music is done
Sets the music volume.
Token Description ValuesRangeDefault
Nthe volume0..255128
see also: soundvol
Mute a specific game sound.
ArgumentDescriptionValues
NID of the sound to mutesee config/sounds.cfg, starting at ID 0
Aaudible?(mute) 0 || 1 (unmute)
Plays the specified sound.
ArgumentDescriptionValues
Sthe sound to playstring, see config/sounds.cfg
See config/sounds.cfg for default sounds, and use registersound to register your own. For example, sound 0 and sound (registersound "aard/jump") both play the standard jump sound.
Sets the desired amount of allocated sound channels.
Token Description ValuesRangeDefault
number of channels4..102432
AC will try to allocate that number of channels but it is not guaranteed to succeed.
Returns 1 if sound A is muted, else 0.
ArgumentDescriptionValues
Asound IDSee /config/sounds.cfg for valid sound ID's.

Example: mutesound 5; if (soundmuted 5) [echo Sound 5 is muted!] [echo Sound 5 is not muted!]Output: Sound 5 is muted!

Token Description ValuesRangeDefault
V0..10005
Token Description ValuesRangeDefault
V0..1000100
Token Description ValuesRangeDefault
V0..1000100
Token Description ValuesRangeDefault
V0..1002
Sets the sound volume for all sounds.
Token Description ValuesRangeDefault
Nthe volume0..255128
Unmutes all previously muted sounds.
see also: mutesound

Server commands

This section lists commands used by the client that communicate to the server. Most are used for server administration. Also see the "mode" section and the "map" command which also communicate to the server.

Adds a new category in the serverbrowser favourites.
ArgumentDescriptionValues
Areference designator (keep short and unique)
Add new categories to your autoexec.cfg, check favourites.cfg for examples.
Sets automated team assignment.
ArgumentDescriptionValues
BEnables or disables auto team.1 (On), 0 (Off)
see also: setadmin
ban CN
Temporary ban of the specified player from the server.
ArgumentDescriptionValues
CNThe player to banClient number
Temporary ban duration is fixed at 20 minutes.
see also: removebans, setadmin
callvote T A B
Calls a vote on the server.
ArgumentDescriptionValues
TVote typevalue
AFirst argument
BSecond argument
This command is wrapped by aliases for better usability and is used to action votes such as ban, kick, etc. See config/admin.cfg for actual uses.
Clears all demos currently in memory on the server.
Deletes a map from the current server.
ArgumentDescriptionValues
Amap name
Calls a vote to forceteam yourself to the specified team.
ArgumentDescriptionValues
Tthe team to force yourself to (optional)0-4
By default, if you are on team CLA or RVSF, this command will force you to the enemy team, no arguments necessary.
see also: forceteam, curteam
Calls a vote to force the specified player to switch to the specified team.
ArgumentDescriptionValues
Cclient number of playerinteger
Tthe team to force to0-4
see also: forceme, curteam, setadmin
Gives admin state to the specified player.
ArgumentDescriptionValues
CNThe player to become adminClient number
Requires admin state. The admin will lose his admin state after successfully issuing this command.
see also: setadmin
Hide favourites icons in serverbrowser.
Token Description ValuesRangeDefault
N0: show, 1: hide0..10
kick CN
Kicks the specified player from the server.
ArgumentDescriptionValues
CNThe player to kickClient number
see also: setadmin
List all registered serverbrowser favourites categories
Sets the mastermode for the server.
ArgumentDescriptionValues
NThe master mode0 (Open), 1 (Private), 2 (Match)
If the mastermode is set to 'private', no more clients can join the server. Default is 'open' which allows anyone to join the server.
see also: setadmin
Token Description ValuesRangeDefault
V1..24*60*6060*60
Sets the number of servers to be pinged at once.
Token Description ValuesRangeDefault
V0..100010
Removes all temporary bans from the server. Temporary bans are normally automatically removed after 20 minutes.
see also: ban, setadmin
Token Description ValuesRangeDefault
V0..21
Search a nickname (or -part) on all servers.
ArgumentDescriptionValues
Nnickname to search
Sends a map to the server.
ArgumentDescriptionValues
Mmap to send (optional)
During coop edit, the current map gets saved to file and sent to the server. Other players can use 'getmap' to download it.
When not in edit mode, the map will not be saved. The new map will be used, when the next game on that map starts on the server.
see also: getmap, dlmap
Hide favourites tag column in serverbrowser
Token Description ValuesRangeDefault
N-0..21
Hide server IP and port in serverbrowser.
Token Description ValuesRangeDefault
N-0..22
If the server was run with -n1 and -n2 arguments (prefix and suffix of descriptive title) a serveradmin can set a user-defined server description with this command, if it wasn't this command results in "invalid vote". This title will only stay until the next map is loaded.
ArgumentDescriptionValues
Ddescription
If, for example, the server was run with -n"Fred's Server" -n1"Fred's " -n2" Server", then you could call "/serverdesc [pWn4g3 TOSOK]" and it would show up as "Fred's pWn4g3 TOSOK Server" in the serverbrowser.
Modded servers announcement of features. See source/src/server.cpp [Line 2926ff. "case SV_EXTENSION:"]
ArgumentDescriptionValues
Eextension
Ddescription
Token Description ValuesRangeDefault
V0..NUMSERVSORT-10
Select ascending of descending sort order in serverbrowser.
Sort official maps over custom maps in serverbrowser.
Token Description ValuesRangeDefault
N-0..11
Token Description ValuesRangeDefault
V1000..600005000
setadmin B PASS
Claims or drops admin status.
ArgumentDescriptionValues
BStatus1 (Claim), 0 (Drop)
PASSPasswordcase sensitive
Failed logins result in an auto kick. The admin is granted the right to kick, ban, remove bans, set autoteam, set shuffleteam, change server description (if enabled), change map, change mastermode, force team, change mode, record demos, stop demos and clear demo(s) - All without needing votes from other users. If the admin votes on any (other players) call, his vote is final. In the scoreboard, the admin will be shown as a red colour.
Whether servers that have not yet responded to a ping should be shown in the server list.
Token Description ValuesRangeDefault
V0..11
Show 'minutes remaining' in serverbrowser.
Token Description ValuesRangeDefault
N0..10
Show player names in serverbrowser.
Token Description ValuesRangeDefault
N-0..10
Show only servers of one favourites category in serverbrowser.
Token Description ValuesRangeDefault
Ncategory index0..1000
Show only servers with the correct protocol in serverbrowser.
Token Description ValuesRangeDefault
N-0..10
Show 'weights' in serverbrowser.
Token Description ValuesRangeDefault
N0..10
'weights' are the sort criteria with the highest priority. Favourites categories can change the weights. Use 'showweights' to debug problems with serverbrowser sorting.
Shuffles the teams. The server will attempt to restore balance, but the result may be less that optimal, and there are certainly better ways to keep teams balanced.
see also: forceteam, forceme

Editing

A variable indicating if the game is in editmode.
Description ValuesRangeDefault
editmode1 (true), 0 (false)0..10
addselection X Y XS XY
Select the given area, as if dragged with the mouse holding CTRL.
ArgumentDescriptionValues
Xthe X coordinate
Ythe Y coordinate
XSthe length along the X axis
XYthe length along the Y axis
This command is useful for making complex geometry-generating scripts. It adds a selection to the current list of selections. The dimensions of the current selections can be accessed by the commands selsx, selsy, selsxs and selsys. These commands return the list of coordinates corresponding to each selection.
Coordinates are as follows: after a "newmap 6" the top-left corner (the one where the red dot points) are (8,8), the opposite corner is (56,56) (or (120,120) on a "newmap 7" etc.).
Adds a bot waypoint at the current position.
ArgumentDescriptionValues
Aconnect automatically0 or 1
Select the increment of the map revision number for the next 'savemap'.
Token Description ValuesRangeDefault
Nincrement1..1001
Controls the ambient lighting of the map, i.e. how bright areas not affected by any light entities will appear.
Token Description ValuesRangeDefault
Nthe ambient color0x000000..0xFFFFFF0
Deletes the entity closest to the player
hotkey x
During map editing, drop all mapsounds so they can be re-added.
arch S
Makes an arch out of the current selection.
ArgumentDescriptionValues
Sside delta (optional)
The selection must be a heightfield before this command can be used. Will make the arch in the long direction, i.e when you have 6x2 cubes selected, the arch will span 7 vertices. Optionally, sidedelta specifies the delta to add to the outer rows of vertices in the other direction, i.e. give the impression of an arch that bends 2 ways (try "arch 2" on an selection of at least 2 thick to see the effect). Not all arch sizes are necessarily available, see config/prefabs.cfg.
archvertex S V D
Defines a vertex delta for a specific arch span prefab, used by the 'arch' command.
ArgumentDescriptionValues
Sspan valueinteger
Vvertex valueinteger
Ddelta valueinteger
See config/prefabs.cfg for an example on usage.
Automatically place waypoints.
Deletes all entities of said type.
ArgumentDescriptionValues
Tthe entity type, see command 'newent'string
Restrict 'closest entity' display to one entity type.
ArgumentDescriptionValues
Aentity type
Converts the nearest entity (if its a clip or plclip) to its opposite type.

Example: convertclipsAssuming the nearest entity is a clip, it will be converted to a plclip.

Example: convertclipsAssuming the nearest entity is a plclip, it will be converted to a clip.

Copies the current selection into a buffer.
hotkey c
Copies the current closest entity into a buffer.
Only works while in edit mode.
see also: pasteent
Makes the current selection into a "corner".
Currently there is only one type of corner (a 45 degree one), only works on a single unit (cube) at a time. It can be positioned either next to 2 solid walls or in the middle of 2 higher floorlevels and 2 lower ones forming a diagonal (and similar with ceiling).
In both cases, the corner will orient itself automatically depending on its neighbours, behaviour with other configurations than the 2 above is unspecified. Since the latter configuration generates possibly 2 floor and 2 ceiling levels, up to 4 textures are used: for example for the 2 floors the higher one will of the cube itself, and the lower one of a neighbouring low cube. You can make bigger corners at once by issuing "corner" on grid aligned 2x2/4x4/8x8 selections, with equal size solid blocks next to them.

default key: K

Returns the number of solid walls contained into the current selection.
ArgumentDescriptionValues
Tthe integer of type of the walls you want to count 0 (solid), 1 (corner), 2 (floor heightfield), 3 (ceil heightfield), 4 (empty cube), 5 (semi solid)

Example: echo (concat "The selection contains " (countwalls 0) "solid wall(s)")Output: The selection contains 3 solid wall(s)

Deletes the entity closest to the player
hotkey x
Deletes the selected waypoint.
Contains the main axis of the player orientation.
Token Description ValuesRangeDefault
N11: X, 12: Y, 13: Z0..130
Changes the height of the current selection.
ArgumentDescriptionValues
Tan integer denoting the type0 (floor), 2 (ceiling)
Dthe delta value to move it in1 (forwards), -1 (backwards)
Default keys are [ and ] for floor level, and o/p for ceiling.
Token Description ValuesRangeDefault
V1..00
ArgumentDescriptionValues
Ttaginteger value
edittex T D
Changes the texture on current selection by browsing through a list of textures directly shown on the cubes.
ArgumentDescriptionValues
Tan integer denoting the type0 (floor), 1 (lower or wall), 2 (ceiling), 3 (upper wall)
Dthe direction you want to cycle the textures in1 (forwards), -1 (backwards)
Default keys are the six keys above the cursor keys, which each 2 of them cycle one type (and numpad 7/4 for upper).
The way this works is slightly strange at first, but allows for very fast texture assignment. All textures are in 3 individual lists for each type (both wall kinds treated the same), and each time a texture is used, it is moved to the top of the list. So after a bit of editing, all your most frequently used textures will come first when pressing these keys, and the most recently used texture is set immediately when you press the forward key for the type. These lists are saved with the map. make a selection (including wall bits) and press these keys to get a feel for what they do.
switches between map edit mode and normal.
In map edit mode you can select bits of the map by clicking or dragging your crosshair on the floor or ceiling (using the "attack" identifier, normally MOUSE1), then use the identifiers below to modify the selection. While in edit mode, normal physics and collision don't apply (clips), and key repeat is ON. Note that if you fly outside the map, cube still renders the world as if you were standing on the floor directly below the camera.
Hotkey E
see also: select, Coopedit
Changes property of the closest entity.
ArgumentDescriptionValues
Pthe property to change0..3
Aamount by wich the property is increasedinteger
For example 'entproperty 0 2' when executed near a lightsource would increase its radius by 2.
entset type value1 value2 value3 value4
Edits the closest entity.
ArgumentDescriptionValues
typethe entity typelight, sound, clip, plclip, playerstart, pistol, ammobox, grenades, health, armour, akimbo, mapmodel, ladder, ctf-flag, helmet
value1see newent 'type'
value2see newent 'type'
value3see newent 'type'
value4see newent 'type'
Overwrites the closest entity with the specified values.
Print some map entity statistics to the console.
Levels the floor/ceiling of the selection.
ArgumentDescriptionValues
Tan integer denoting the type0 (floor), 2 (ceiling)
default keys , and .
Increases the size of the current selection by N cubes on all sides.
ArgumentDescriptionValues
Nnumber of cubesinteger
Instead of manually executing this command, you can bind "domodifier 11" to a key. While holding this key you can expand/shrink the current selection with the mouse wheel.
see also: shrinkselection
A variable indicating if the player looks at the floor or at the ceiling.
Description ValuesRangeDefault
flrceil0 (floor), 2 (ceiling)0..20
Determines by how much to multiply the fly speeds by.
Token Description ValuesRangeDefault
Nthe multiplier1.0..5.02.0
Sets all light values to fullbright.
ArgumentDescriptionValues
Bsets fullbright on or off0 (off), 1 (on)
Will be reset when you issue a 'recalc'. Only works in edit mode.
Returns the map message of the current map.
Enables or disables a special set of default textures while editing.
The textures in "packages/textures/map_editor" are used.
Marks the current selection as a heightfield.
ArgumentDescriptionValues
Tan integer denoting the type0 (floor), 2 (ceiling)
marks the current selection as a heightfield, with T being floor or ceiling, as above. A surface marked as heightfield will use the vdelta values (see below) of its 4 corners to create a sloped surface. To mark a heightfield as normal again (ignoring vdelta values, set or not) use "solid 0". Default keys are h (floor) and i (ceiling).
Heightfields should be made the exact size that is needed, not more not less. The most important reason for this is that cube automatically generates "caps" (side-faces for heightfields) only on the borders of the heightfield. This also means if you have 2 independent heightfields accidentally touch each other, you will not get correct caps. Also, a heightfield is slightly slower to render than a non-heightfield floor or ceiling. Last but not least, a heightfield should have all the same baseheight (i.e. the height determined by a normal editheight operation) to get correct results.
see also: vdelta
Used to finetune the "overbright lighting" rendering feature when enabled.
Token Description ValuesRangeDefault
Nthe brightness of the scene1..1004
After changing this value, a "recalc" is needed to see the differences.
see also: recalc
Determines if map backups (.bak) should be created when a map is saved.
Token Description ValuesRangeDefault
N0 off, 1 on0..11
Enlarges the current map.
This command will make the current map 1 power of two bigger. So a size 6 map (64x64 units) will become a size 7 map (128x128), with the old map in the middle (from 32-96) and the new areas solid.
see also: newmap
Sets the map message, which will be displayed when the map loads.
ArgumentDescriptionValues
MThe map messageString
You will need to use quote marks around the message, otherwise it save the message correctly.
For example: /mapmsg "Map By Author"
Reduces the world size by 1.
This command will make the current map 1 power of two smaller. So a size 7 map (128x128) will become a 6 size map (64x64 units), by removing 32 cubes from each side. The area to be removed needs to be empty (= all solid).
movemap dX dY dZ
Move the whole map (including all entities) in the specified direction.
ArgumentDescriptionValues
dXx-offset
dYy-offset
dZz-offset
newent type value1 value2 value3 value4
Adds a new entity
ArgumentDescriptionValues
typethe entity typelight, sound, clip, plclip, playerstart, pistol, ammobox, grenades, health, armour, akimbo, mapmodel, ladder, ctf-flag, helmet
value1see newent 'type'
value2see newent 'type'
value3see newent 'type'
value4see newent 'type'
(x,y) is determined by the current selection (the red dot corner) and z by the camera height, of said type. Type is a string giving the type of entity, such as "light", and may optionally take values (depending on the entity).
Adds a new akimbo item.
Adds a new ammo box item.
Adds a new armour item.
newent clip Z X Y H
Adds a clip entity.
ArgumentDescriptionValues
Zelevation above the groundinteger
XX radius around the box centerinteger
YY radius around the box centerinteger
Hheight of the boxinteger
Defines a clipping box against which the player will collide.
Use this clip type to clip visible obstacles like fences or the gas tank. If you only want to prevent a player from entering an area, use plclip instead.
Adds a CTF flag entity.
ArgumentDescriptionValues
Tdenotes the flag's team0 (CLA), 1 (RVSF)
Note that outside of edit mode, this entity is only rendered as flag if the current game mode is CTF.
Adds a new grenades item.
Adds a new health item.
Adds a new helmet item.
Adds a ladder entity.
ArgumentDescriptionValues
Hthe height of the ladderinteger
Note that this entity is used for physics only, to create a visual ladder you will need to add a mapmodel entity too.
see also: newent mapmodel
newent light radius R G B
Adds a new light entity
ArgumentDescriptionValues
radiusthe light radius1..32
Rred colour component. see remarks below.1..255
Ggreen colour component1..255
Bblue colour component1..255
if only argument R is specified, it is interpreted as brightness for white light.
Adds a map model to the map (i.e. a rendered md2/md3 model which you collide against but has no behaviour or movement)
ArgumentDescriptionValues
NThe mapmodel identifierInteger
ZExtra elevation above ground (optional)Integer
TThe map texture to use (optional)Integer
The mapmodel identifier is the desired map model which is defined by the 'mapmodel' command. The order in which the mapmodel is placed in the map config file defines the mapmodel identifier. The map texture refers to a texture which is defined by the 'texture' command, if omitted the models default skin will be used. The 'mapmodel' and 'texture' commands are placed in the map config normally. Mapmodels are more expensive than normal map geometry, so do not use insane amounts of them to replace normal geometry.
Adds a pistol magazine item.
Adds a new spawn spot.
The yaw is taken from the current camera yaw.
newent plclip Z X Y H
Adds a player clip entity.
ArgumentDescriptionValues
Zelevation above the groundinteger
XX radius around the box centerinteger
YY radius around the box centerinteger
Hheight of the boxinteger
Defines a clipping box against which (only) the player will collide.
Use this clip type to define no-go areas for players without visible obstacles, for example to prevent players from walking on a wall.
Nades will not be affected by this clip type.
newent sound N R S V
Adds a sound entity.
ArgumentDescriptionValues
Nthe sound to playinteger
Rthe radius
Sthe size (optional)default 0
Vthe volume (optional)default 255
Will play map-specific sound so long as the player is within the radius. However, only up to the max uses allowed for N (specified in the mapsound command) will play, even if the player is within the radius of more N sounds than the max. By default (size 0), the sound is a point source. Its volume is maximal at the entity's location, and tapers off to 0 at the radius. If size is specified, the volume is maximal within the specified size, and only starts tapering once outside this distance. Radius is always defined as distance from the entity's location, so a size greater than or equal to the radius will just make a sound that is always max volume within the radius, and off outside.
A sound entity can be either ambient or non-ambient. Ambient sounds have no specific direction, they are 'just there'. Non-ambient sounds however appear to come from a specific direction (stereo panning). If S is set to 0, the sound is a single point and will therefore be non-ambient. However if S is greater than 0, the sound will be ambient as it covers a specified area instead of being a single point.
see also: mapsound
Creates a new map.
ArgumentDescriptionValues
Sthe size of the new map6..9
The new map has 2^S cubes. For S, 6 is small, 7 medium, 8 large.
Binds a list of keys to be used to create new (multiple) selections in editmode.
LCTRL is default.

Example: newselkeys = [LCTRL RCTRL LALT RALT]Makes all 4 keys create new (multiple) selections in editmode.

Choose another 'closest ent'.
Use this, when two entities are placed in exactly the same location.
Visit next player spawn entity.
ArgumentDescriptionValues
TYPE0|1|100
Enables or disables the old editing binds.
If disabled, an updated editing binds system is used, see the comments in "/config/resetbinds.cfg" for more info.

Example: old_editbinds = 0disables the old editing binds

Example: old_editbinds = 1enables the old editing binds

Enables or disables using triangles to render the editing grid/current selection instead of squares.
Token Description ValuesRangeDefault
N0 off, 1 on0..11
If this alias exists, it will be automatically executed when you start a new map.
Pastes a previously copied selection.
To paste a selection back requires a same size selection at the destination location. If it is not the same size the selection will be resized automatically prior to the paste operation (with the red dot as anchor), which is easier for large selections.
hotkey v
Pastes a previously copied entity.
Only works while in edit mode.
see also: copyent
perlin S E C
Generates a perlin noise landscape in the current selection.
ArgumentDescriptionValues
Sthe scale, frequency of the featuresdefault is 10
Ethe random seedinteger
Ccube size, how many cubes to generate a surface for at once (unused)
Keep the seed the same to create multiple perlin areas which fit with each other, or use different numbers if to create alternative random generations.
Recomputes all there is to recompute about a map, currently only lighting.
hotkey R
Registers a sound.
ArgumentDescriptionValues
Nsound namestring, see config/sounds.cfg
This command returns the sound number, which is assigned from 0 onwards, and which can be used with "sound" command. If the sound was already registered, its existing index is returned. registersound does not actually load the sound, this is done on first play.
See for example config/sounds.cfg.
see also: sound
Repeats the last texture edit throughout the map.
The way it works is intuitive: simply edit any texture anywhere, then using "replace" will replace all textures throughout the map in the same way (taking into account whether it was a floor/wall/ceil/upper too). If the there was more than one "old" texture in your selection, the one nearest to the red dot is used. This operation can't be undone.
Resets all current selections.
Saves the current map.
ArgumentDescriptionValues
Mfile name of the map, see command 'map' for the naming schemestring
savemap makes a versioned backup (mapname_N.BAK) if a map by that name already exists. If the name argument is omitted, it is saved under the current map name.
Where you store a map depends on the complexity of what you are creating: if its a single map (maybe with its own .cfg) then the "base" package is the best place. If its multiple maps or a map with new media (textures etc.) its better to store it in its own package (a directory under "packages"), which makes distributing it less messy.
see also: map
Scales all lights in the map.
ArgumentDescriptionValues
Ssize change (percentage)
Iintensity change (percentage)
This command is useful if a map is too dark or bright but you want to keep the light entities where they are.
select X Y XS XY
Resets all current selections and selects the given area, as if dragged with the mouse.
ArgumentDescriptionValues
Xthe X coordinate
Ythe Y coordinate
XSthe length along the X axis
XYthe length along the Y axis
This command is similar to addselection although "select" resets all selections.
Flip the selected part of the map at an axis.
ArgumentDescriptionValues
AXISX or Y
Rotate the selected part of the map in 90 degree steps.
ArgumentDescriptionValues
Dsteps
To rotate clockwise, use a positive number of steps. Note, that only quadratic selections can be rotated by 90 degrees.
Return a list containg the x-coordinate of each selection
Return a list containg the x-span of each selection
Return a list containg the y-coordinate of each selection
Return a list containg the y-span of each selection
settex T t
Set a texture for the current selection.
ArgumentDescriptionValues
Tposition of the texture to set in map cfginteger
tthe type of the texture0 (floor), 1 (wall), 2 (ceil), 3 (upper wall)
takes the current player yaw for the current waypoint
Show clips/plclips/mapmodel clips in edit mode.
Token Description ValuesRangeDefault
N-0..11
Show editing cursor grid.
Token Description ValuesRangeDefault
N-0..11
Toggles between showing what parts of the scenery are rendered.
Shows what parts of the scenery are rendered using what size cubes, and outputs some statistics about it. This can give map editors hints as to what architecture to align, textures to change, etc.
Show mapmodel clipping during edit mode.
Token Description ValuesRangeDefault
N-0..10
Decreases the size of the current selection by N cubes on all sides.
ArgumentDescriptionValues
Nnumber of cubesinteger
Instead of manually executing this command, you can bind "domodifier 11" to a key. While holding this key you can expand/shrink the current selection with the mouse wheel.
see also: expandselection
slope X Y
Makes a slope out of the current selection.
ArgumentDescriptionValues
Xx delta stepinteger
Yy delta stepinteger
The selection must be a heightfield before this command can be used. The steps specify the slope with the red vertex as left-top, i.e. "slope 1 2" will make a slope that increases just 1 step from left to right, and is slightly steeper from top to bottom. "slope -6 0" decreases steeply from left to right, and does not slope at all from top to bottom. Note that like the vdelta command, an increasing vdelta goes further away from the player, regardless of floor or ceiling.
makes the current selection all solid (i.e. wall) or all non-solid.
ArgumentDescriptionValues
Ban integer denoting the solid-ness0 (non-solid), 1..* (solid)
This operation retains floor/ceiling heights/textures while swapping between the two. Default keys f and g respectively.
teletransports the bot with the lowest connection number to you current position.
ArgumentDescriptionValues
this command does not take any argumentsnone
This is a debugging command and only works for single player modes.
ArgumentDescriptionValues
Ddirection0..5 for Forward, Backward, Left, Right, Up AND Down
When used you will see what the bot sees. Type it again (with or without name) to return to the game(you will respawn).
ArgumentDescriptionValues
Nbotnamethe name of the bot
Will toggle the focus of the mouse in game. Normally you can use your mouse to look around, when you type this command your mouse cursor is visible and can be used as normally. This is only useful when you run cube windowed.
Turns occlusion culling on and off.
The reason one may want to turn it off is to get an overview of the map from above, without having all occluded bits stripped out.
Multi-level undo of any of the changes caused by editing operations
hotkey u
Sets the number of megabytes used for the undo buffer.
ArgumentDescriptionValues
Nnumber of megabytes, default is 1integer
undo's work for any size areas, so the amount of undo steps per megabyte is more for small areas than for big ones (a megabyte fits 280 undo steps on a 16x16 area, but only 4 steps on a 128x128 area).
changes the vdelta value of the current selection
ArgumentDescriptionValues
Nvdelta value
Note that unlike all other editing functions, this function doesn't affect a cube, but its top-left vertex (market by the dot in the editing cursor). So to edit a N * M heightfield, you will likely have to edit the vdelta of (N+1) * (M+1) cubes, i.e. you have to select 1 row and 1 column more in the opposite direction of the red dot to affect all the vertices of a heightfield of a given size (try it, it makes sense :)
A floor delta offsets vertices to beneath the level set by editheight (and a ceil delta to above). Delta offsets have a precision of a quarter of a unit, however you should use non-unitsize vertices only to touch other such vertices. Default keys are 8 and 9 to decrease/increase the vdelta.
Sets the global water level for the map.
ArgumentDescriptionValues
Hthe water levelinteger
Every cube that has a lower floor than the water level will be rendered with a nice wavy water alpha texture. Water physics will be applied to any entity located below it.
Performance notes: water is rendered for a whole square encapsulating all visible water areas in the map (try flying above the map in edit mode to see how). So the most efficient water is a single body of water, or multiple water areas that are mostly not visible from each other. Players can influence how accurate the water is rendered using the "watersubdiv" command (map config).
makes waypoints visible and either turns on or off the waypoint information display.
ArgumentDescriptionValues
Yshow info?0||1
ArgumentDescriptionValues
Vvisible0||1

Editing configs

All the below commands are used specifically in map configuration files. Some of these commands can also be used without the need of a map configuration file.

fog N
Sets the fog distance.
ArgumentDescriptionValues
NThe fog distance64...1024, default is 180
You can do this for tweaking the visual effect of the fog, or if you are on a slow machine, setting the fog to a low value can also be a very effective way to increase fps (if you are geometry limited). Try out different values on big maps / maps which give you low fps. It is also good for aesthetic features of maps especially when combined with "fogcolour".
see also: fogcolour
Sets the fog and clearing colour.
ArgumentDescriptionValues
CThe colourHexadecimal colour, default is 0x8099B3
see also: fog
Isolates the given context. This disables access from this context to identifiers located in other contexts, also it removes all aliases created in this context once the running context changes
ArgumentDescriptionValues
Cthe context
see also: sealcontexts
Binds a texture to be used if a slot couldn't be loaded with a given textures path.
ArgumentDescriptionValues
Ffile name of the texture to bindstring
Binds the texture indicated in the filename to the texture slot of any textures that aren't found. The path is given exactly as with the texture-command, if it is omitted (or can't be loaded) the default is used. The default is located in packages/misc/notexture.jpg (not in packages/textures - where custom ones must reside!)

Example: loadnotexture // Reset to default

Example: loadnotexture "makke/black.jpg" // Any missing texture will show up black

see also: texture, texturereset
Loads a skymap for a map.
ArgumentDescriptionValues
Ppath to the six skymap texturesstring
The available skymaps reside in packages/textures/skymaps/..
To select a skymap you need to use the full path from "packages/" but only up to the underscore "_" in the filename.

Example: loadsky "textures/skymaps/makke/mountain"

mapmodel R H Z 0 N
Registers a mapmodel that can be placed in maps.
ArgumentDescriptionValues
RThe square radius of the bounding box.Integer
HThe height of the bounding box.Integer
ZThe initial height offset from the ground.Integer
0This integer is redundant. Leave it at zero so you don't break the command.0
NThe name of the map modelstring
A mapmodel registered with this command can be placed in a map using the 'newent mapmodel' command. The bounding box is an invisible force surrounding the model, allowing players to collide against it, instead of walking through the mapmodel. For more information about this command, read mapediting5.xml.
Example: mapmodel 4 2 4 0 "modelname"
This mapmodel has a bounding box of 8x8x2 in size (X/Y/Z) and by default hovers 4 units above ground.
Resets the mapmodel slots/indices to 0 for the subsequent "mapmodel" commands.
Each subsequent mapmodel command increases it again. See config/default_map_settings.cfg for an example.
Defines a mapsound.
ArgumentDescriptionValues
NPath to the sound file
MMaximum simultaneous sounds (optional)default -1 (unlimited)
Registers the sound as a map-specific sound. These map-specific sounds may currently only be used with "sound" entities within a map. The first map sound registered in a map has slot/index number 0 and increases afterwards.
Resets the mapsound slots/indices to 0 for the subsequent "mapsound" commands.
Each subsequent mapsound command increases it again. See config/default_map_settings.cfg for an example.
md2anim A F R S
ArgumentDescriptionValues
Aanim
Fframe
Rrange
Sspeed
md2emit T Y A B
ArgumentDescriptionValues
Ttag
Ytype
Aarg1
Barg2
md2tag N A B C D
ArgumentDescriptionValues
Nname
Avert1
Bvert2
Cvert3
Dvert4
md3anim A S R V
ArgumentDescriptionValues
Aanim
Sstartframe
Rrange
Vspeed
md3emit T Y A B
ArgumentDescriptionValues
Ttag
Ytype
Aarg1
Barg2
ArgumentDescriptionValues
Mmodel
md3skin N S
ArgumentDescriptionValues
Nobject name
Sskin texture
ArgumentDescriptionValues
Aalphatest
ArgumentDescriptionValues
Lcachelimit
ArgumentDescriptionValues
Ccullface0||1
ArgumentDescriptionValues
Ppercent0..100..N*100
ArgumentDescriptionValues
Dshadow distance
mdltrans X Y Z
translates (= moves) the model
ArgumentDescriptionValues
X
Y
Z
ArgumentDescriptionValues
Ttranslucency0..100..N*100
ArgumentDescriptionValues
Vvertexligh0||1
ArgumentDescriptionValues
Ccontext
Nidname
secure this configuration for the rest of the game
Shadow yaw specifies the angle at which shadow stencils are drawn on a map.
ArgumentDescriptionValues
DThe angle in degrees to rotate the stencil shadows0...360, default is 45
When specifying shadowyaw, remember that the default angle is 45 degrees. The example below would make the shadows appear at 90 degrees (45 degrees more to the left).

Example: shadowyaw 90

texture S F
Binds a texture to the current texture slot.
ArgumentDescriptionValues
SScale of the texture to load (should be a power of two).Float
FFile name of the texture to bindString
Binds the texture indicated in the filename to the current texture slot and increments the slot number.
The texture is rendered at the given scale. At scale 1.0 (or if scale is 0), 32x32 texels cover one cube. At scale 2.0, which is the current maximum, it's 64x64.
Sets the texture slots/indicies to 0 for the subsequent "texture" commands.
Each subsequent texture command increases it again. See config/default_map_settings.cfg for an example.
see also: texture
Determines the water colour in a map.
ArgumentDescriptionValues
RRed colour intensityBetween 1 and 255
GGreen colour intensityBetween 1 and 255
BBlue colour intensityBetween 1 and 255
You must define all 3 values, otherwise this command may not work correctly (use "1" as a placeholder if needed).
see also: waterlevel
Sets the wave height of water, between 0 (completely still, no waves at all) and 1 (very choppy).
Token Description ValuesRangeDefault
Fwave height (floating-point value)0..10.3

Menus

This section describes identifiers related to the menu gui.

chmenumdl N M A R S
Changes the menu model of a specified menu.
ArgumentDescriptionValues
Nthe name of the menu
Mthe (new) model
Athe animation to play
Rthe rotation speed
Sthe scale
see also: menumdl
Closes the specified menu if it is open.
ArgumentDescriptionValues
Nthe name of a previously defined menu
If it is open multiple times in the stack only the topmost instance will be closed!
see also: newmenu, delmenu, showmenu
Deletes the entire contents (all menu items) of the given menu.
ArgumentDescriptionValues
Nthe name of a previously defined menu
Specifies commands to be executed when a menu opens.
ArgumentDescriptionValues
CThe code to execute on init
This command should be placed after newmenu.
see also: newmenu
Defines the initial selection for a menu.
ArgumentDescriptionValues
Aline number
menuitem N A H
Creates a new menuitem.
ArgumentDescriptionValues
NThe menuitem description.
AThe command to execute on selection of the menuitem. (optional)
HThe command to execute upon rolling over the menuitem. (optional)
Upon activating the menuitem, the associated command will be executed. (See config/menus.cfg for examples). If the command argument is omitted, then it will be set to the same value as the description. If -1 is specified instead of the command to execute, then no command is executed when activating the item. If the rollover option is used, the menuitem will execute that command when selecting (but not activating) the menuitem.
(Note: To activate the menu item, select it, and either: Click, press SPACE or press ENTER/Return).
see also: newmenu
Creates a new menuitem with variable content.
ArgumentDescriptionValues
NThe cubescript to generate the menuitem description.
AThe command to execute on selection of the menuitem. (optional)
HThe command to execute upon rolling over the menuitem. (optional)
Like 'menuitem', but the menuitem description will be the result of an evaluation, everytime the menu gets displayed.
see also: newmenu, menuitem
menumdl M A R S
Specifies a model to render while displaying the last added menu.
ArgumentDescriptionValues
Mthe model
Athe animation to play
Rthe rotation speed
Sthe scale
Selects a line in a menu.
ArgumentDescriptionValues
Amenu name
Bline number
Defines the background color for the menu selection bar.
ArgumentDescriptionValues
Rred (0..100)
Ggreen (0..100)
Bblue (0..100)
Aalpha (0..100)
Creates a new menu.
ArgumentDescriptionValues
NThe name of the menu
All menu commands placed after newmenu (i.e. menuitem, menuitemcheckbox, etc) are added into the menu until another "newmenu" command is specified.
see also: menuitem
Displays the specified menu.
ArgumentDescriptionValues
Nthe name of a previously defined menu
The menu allows the user to pick an item with the cursor keys. Upon pressing return, the associated action will be executed. Pressing ESC will cancel the menu.
If wrapslider is set the menuitemslider will toggle to the min/max value if at end of the range.
Token Description ValuesRangeDefault
N0 off, 1 on0..10

Ingame Reference

This section describes all identifiers related to the ingame documentation reference.

docargument T D V I
Adds a new argument documentation to the last added identifier.
ArgumentDescriptionValues
Tthe token
Dthe description
Vthe value notes
Iflags this argument as variable-length (optional)1 (true), 0 (false)
An argument represents either a command argument or a variable value.
The last argument of an identifier can be flagged as variable-length to indicate that it represents an unknown number of arguments.
see also: docident
Adds an example to the last added identifier.
ArgumentDescriptionValues
Cthe example code
Ethe explanation (optional)
Searches the ingame docs for identifier documentations matching the specified search string.
ArgumentDescriptionValues
Sthe search string
The name, description and remarks are included in the search.
Adds a new identifier documentation to the last added section.
ArgumentDescriptionValues
Nname of the identifier
Dthe description
An identifier represents a command or variable. The new identifier
The name may contain spaces to create a "multipart" identifier documentation that can be used to describe a complex argument as a single pseudo identifier, look at the examples.

Example: docident fov "Sets the field of view."

Example: docident "newent light" "Adds a new light entity."

Outputs a list of identifier documentations that do not match any existing identifier.
Multipart identifiers are not included in this list, see 'docident'.
ArgumentDescriptionValues
Avalue
docref N I U
Adds a new documentation reference to an identifier.
ArgumentDescriptionValues
Nthe display name
Ithe identifier to refer to (optional)
Uthe URL to refer to (optional)
The new reference is added to the last added identifier documentation.
see also: docident
Adds a new documentation remark to the last added identifier.
ArgumentDescriptionValues
Sthe remark
see also: docident
Adds a new section to the ingame documentation.
ArgumentDescriptionValues
Sthe section name
see also: docident
Token Description ValuesRangeDefault
V0..10000
Outputs a list of yet undocumented identifiers (commands,variables, etc)
ArgumentDescriptionValues
Aoutput all identifiers (optional)1 (true), 0 (false)
If the one argument is omitted, only the builtin identifiers will be listed. Therefore specify the argument other identifiers like aliases should be included too.
Note that the list also includes identifiers that contain the substrings "TODO" or "UNDONE" in their documentation.
Token Description ValuesRangeDefault
V0..11
Writes out a base XML documentation reference containing templates for the builtin identifiers.
ArgumentDescriptionValues
Rthe reference name (optional)
Sthe XML schema location string (optional)
TXML stylesheet to use (optional)
The generated reference is written to "docs/autogenerated_base_reference.xml" by default. The three arguments can be changed later on in the generated XML document.

TODO

This section describes identifiers that are not documented yet, but you may try to help us there.

addzip A B C
TODO: Description
ArgumentDescriptionValues
ATODO
BTODO
CTODO
for toggling on the ability for any text to have the blinking bit set.
ArgumentDescriptionValues
TTOGGLE
see also: menucanblink
do you really want to quit?
Token Description ValuesRangeDefault
NTODO0..11
TODO
Token Description ValuesRangeDefault
NTODO0..10
deletes the passed alias.
set the formatstring for demo filenames - default: TODO (when stable)
ArgumentDescriptionValues
SSTRING
we use the following internal mapping of formatchars:
%g : gamemode (int) %G : gamemode (chr) %F : gamemode (full)
%m : minutes remaining %M : minutes played
%s : seconds remaining %S : seconds played
%h : IP of server %H : hostname of server (%N : title of server (really???))
%n : mapName
%w : timestamp "when"
set the formatstring for demo timestamp - default: TODO (when stable)
ArgumentDescriptionValues
SSTRING
same as strftime() - see http://www.cplusplus.com/reference/clibrary/ctime/strftime/ for details
use localtime (1) or GMT (0)?
Token Description ValuesRangeDefault
BBOOL0..10
At what char does the definition proceed?
ArgumentDescriptionValues
ATODO
returns the currently used formatstring for demo filenames
returns the currently used formatstring for demo timestamp
An alias used for i18n. Translateable text should be marked [(_ "this is the EN-us variant of the text")].
ArgumentDescriptionValues
MI18Nmessage
TODO
Token Description ValuesRangeDefault
NTODO0..10
TODO
Token Description ValuesRangeDefault
NTODO0..42
TODO
Token Description ValuesRangeDefault
NTODO0..200
TODO
Token Description ValuesRangeDefault
NTODO0..11
switch the font in which the menu is displayed
ArgumentDescriptionValues
FFONT
a menuitem that loads a map, displays the title and the preview or a default image
ArgumentDescriptionValues
MMAP
TTEXT
TODO
Token Description ValuesRangeDefault
NTODO0,0..6,00,0
TODO
Token Description ValuesRangeDefault
NTODO0,0..1000,00,0
TODO: Description
ArgumentDescriptionValues
ATODO
TODO: Description
TODO: Description
ArgumentDescriptionValues
ATODO
TODO
Token Description ValuesRangeDefault
NTODO0,001..1000,00,5
TODO
Token Description ValuesRangeDefault
NTODO0,001..1000,01,0
TODO: Description
Hides the list of entity types you set. Pass 1 for light, 2 for spawn, or use "playerstart".
ArgumentDescriptionValues
Llist of types to hide
Pass light or 1, playerstart or 2. Call [setedithide 1 10] to just hide all lights and mapmodels.
Or [setedithide [3 4 5 6 7 8 9 12 13]] for all the clips, ammo, nades, health, helmet, armour, akimbo, ladder, and flag.
Reversly just use [1 2 10 11 13 14 15 16] to hide light, spawn, mapmodel, ladder, sound, clip, plclip.
Only shown entity types are potential 'closest entity'.
Hides all but the single entity type you give. Pass 1 for light, 2 for spawn, or use [playerstart].
ArgumentDescriptionValues
Ttype to show exclusively
Just run [seteditshow model] and see just the model entities.
The other entity types are ignored as closestentity too.
other call forms may use the numerical item type
TODO: Description
ArgumentDescriptionValues
ATODO
shows the settings of edithide (sparklies)
TODO
Token Description ValuesRangeDefault
NTODO0..10
CubeScript command & variable list