ClanMod Documentation :
Server Command Reference

Following is a list of all commands that can be issued from the server console. Many of these also appear in the config files that initialize ClanMod. Players may also use these commands from the client if combined with rcon or an alias (see the cm_alias command below).

All files referenced in this section are in <mod_dir>/addons/clanmod.

If a command defines a text field element and a similar element has already been defined, then the new one won't be added. Use a unique name for each new entry.

cm_addcvar "<cvar name>" "<starting value>" <flags>

This command creates a new server cvar. If starting value is "", the starting value will default to "0". The following flags will affect the cvar:
Examples of usage:

cm_admin "<nick, ip or wonid>" "<password>" "<level and flags>"

This command creates a new admin account. All of your cm_admin commands should be in your cm_admins.cfg file. The command is described in great detail including examples in the section titled "Creating an admin account". Please see that section for details.

cm_alias "<name>" "<server command>" <level and flags>

Set an alias for a server command. Aliases can be run on the client without using rcon. Also, if the appropriate flag is set, aliases can be run through the say/say_team commands by the clients. These commands should be in your cm_aliases.cfg file. Admins must have one of the listed levels to use the alias. Available flags are:
Examples of usage:
Note: Aliases that are executes using the say command (flag "s") can't have spaces in name. They also can't be called with arguments.
cm_ban "<name, wonid, ip or id>"

Bans people from your server and writes it in banlist.txt
Examples of usage:
cm_bury "<name, wonid, ip or id>"

It will bury a player in the ground.
Examples of usage:
cm_unbury
Will cancel the effect of cm_bury
Examples of usage:
cm_cancelvote

Cancels the current vote in progress.

cm_clexec "<name, wonid, ip or id>" "<command to execute>"

Causes a command to be executed on the identified client. cvar cm_clientcmd must be set to 1. As "name" you can also use "*" to execute the command on all clients. In Counter-Strike, use "t" or "ct" to execute on specified team. This command is aliased as "clexec" so clients can use it.
Examples of usage:

cm_cmd "<description>" "<command>" <level and flags>

Adds a command to Custom Commands menu. Place these commands in your cm_menus.cfg file. The description is what appears in the menu. The command is what is executed. Admins must have one of the levels to use this command. The flags are as follows:
Examples of usage:

cm_command "<command name>" "<action>"

This command creates a new server command that performs <action>. This is useful as a shortcut to perform complex actions with shorter commands.
Examples of usage:

cm_cvar <name> <increasing step> <max. value> <level and flags>
cm_cvar <name> "<argument#1>" "<argument#2>" ... <level and flags>c

Register a variable for the Settings menu. All of your cm_cvar commands should be in your cm_cvars.cfg file. The special flag "c" indicates that the cvar has a custom argument list (the second model above). There is a maximum of 10 custom arguments. Custom arguments must be enclosed in quotes.
Examples of usage:
cm_exec

Executes files in your current clanmod folder set by cm_configpath
cm_gag "<name, wonid, ip or id>"

Will prevent a player from using "say"
Examples of usage:
cm_ungag
Will undo the effect of cm_gag
Examples of usage:
cm_glow "<name, wonid, or id>" "<colour>"

Will make a player glow in a spesific colour, the valid colours are: red, green,blue, yellow, pink,white,turquoise
Examples of usage:
cm_unglow "<name, wonid, or id>"

Examples of usage:
cm_if <cvar> <operator> <value> then <cmd to execute> [else] [cmd to execute]

This is a conditional expression allowing you to perform commands based on the current environment. Valid operators are "<", "=", "!=", and ">". <cmd to execute> will be executed if the condition is true. Otherwise, the optional else clause will be executed
Examples of usage:

cm_kick <mask> ...

Kick player from game. Can't be used on admins with level O. Mask accepts wildcards.

cm_listadmin

Shows the list of admins previously defined using the cm_admin command. The list will appear in a graphic window if executed on the client, or in the server console if executed from the server console.

cm_listplayer [output file]

Shows the list of players currently connected to the server. The list will appear in a graphic window if executed on the client, or in the server console if executed from the server console.

cm_listtask

Shows the list of tasks previously defined using the cm_task command. The list will appear in a graphic window if executed on the client, or in the server console if executed from the server console.

cm_log "<text>"

Write an entry to the log current hlds file.
Examples of usage:
cm_login <name, wonid, ip or id> <password>
Allows you to login on the server without the client saving you password, the client side command is login
Examples of usage:
cm_makeadmin <name, wonid, ip or id> <level and flags>

Make specified player a temporary admin. Valid entries to identify the player include those described for the cm_admin command as well as the current player ID on the server. This function does not register any new accounts or make any permanent changes. The player must be currently connected to the server. The player will retain admin status only until the ClanMod configs are reloaded. You can manually exec the clanmod.cfg to remove the account or wait for it to occur automatically. See cm_loadconfig in the "cvars" section of the ClanMod Manual for details on when the configs will automatically be reloaded.
Examples of usage:

cm_map <map name> <level>

Add the map "map name" to the Map menu for voting and changelevel. The "level" allows you to restrict who has access to that map. Only admins who have one of the levels indicated will see the map in their menus. These commands should be placed in you cm_maps.cfg file.
Examples of usage:

cm_motd "<text>" <RRRGGGBBB> <hold time>

Adds a message that will appear in bold at the centre of the screen for all clients. The colour of the message is defined by RRR (red), GGG (green) and BBB (blue), which can be values between 000 and 255. Place these commands in your clanmod.cfg file. To say "&" needs to be written as "\&" to be displayed without cvar parsing
Examples of usage:

cm_pause

Pause server even if cvar pausable is set to 0. This is aliased on the client as "pa".

cm_remove <object> <mask>

Removes items from the current live clanmod configuration. Valid objects are:
Examples for <mask>:
Examples of usage:
Note: This does not affect what is stored in the config files therefore this command will not have any permanent effects unless you use cm_save afterwards to save the changes.

cm_replace <object> <mask> with <parameters for new element in object>

Search for an element and replace with a new one. Valid objects are the same as for cm_remove.
Examples of usage:

cm_save <object> <output file>

Saves part or all of the current ClanMod configuration to a file. Valid objects are the same as for cm_remove above.
Examples of usage:

cm_say <parameter> <text>

This will write bold text on the screen with the desired colour and location. Location is controlled using @'s such that:
@ = Left side of screen @@ = Centre of screen @@@ = Bottom centre of screen
To colour the text, add one of the following letters after the "@":
Finally, if you use @@@@, it will appear as regular chat text however, it will not indicate who said the message.
Examples of usage:

cm_sayadmin <text>

Send text to admins only
Examples of usage:

cm_saycenter <text>

Send center screen message.
Examples of usage:

cm_string <string index> "<string>"

Sets strings used by ClanMod. These are stored in the titles.cfg file and allow you to alter the messages generated by ClanMod. See titles.cfg for many examples.


cm_task <MMDDhhmmss> "<command to execute>" <flags> "<task name>"
cm_task <hhmmss> "<command to execute>" <flags> "<task name>"
cm_task <MMDD> "<command to execute>" <flags> "<task name>"
cm_task <value> "<command to execute>" <flags> "<task name>"

Shedule a task to run on the server which will be executed on specified date and time. If a scheduled date/time is missed, the task will be run as soon as possible. Valid flags are:
Examples of usage:

cm_vote <text> [first option] [command] [second option] [command]

Start a custom vote. If you don't specify the first or second option, they will automatically become YES and NO. If the voting commmand is called from the player console, then you will have the option to abort or proceed after the results have been shown. If the command was called from server console then the winning option will be automatically executed.
Note: Voting sessions close automatically either within 15 seconds of the vote being initiated, when the last player gives his vote, or if the vote is cancelled.
Examples of usage:

cm_votekick <mask for nick, wonid, ip or id>

Start a vote to kick a player. The ratio of "Yes" votes must be greater than cm_kickvoteratio in order for the player to be kicked.
Examples of usage:

cm_votemap <map name> [map name] [map name] [map name]

Start voting for a map. You can give up to 4 maps in the list. In order for a changelevel to occur, the ratio of players that voted for the map must be greater than cm_mapvoteratio
Examples of usage:

cm_whine "<sentence>"

Add a sentence to the list of "whine" sentences. If cm_chatfilter is set to make use of whine, then whenever a player uses say or say_team to say a bad word, the entire sentence will be replaced with one of these sentences chosen at random. Place all of your cm_whine statements into your cm_badwords.cfg file. Look in the cm_badwords.cfg file for many examples.

cm_word "<word>"

Add a word to the list of unacceptable words. You should place all of your cm_word commands into your cm_badwords.cfg file. See the cm_chatfilter command for details on how ClanMod will use these words. See cm_badwords.cfg for many examples.