Half-Life 2: Deathmatch

Entering Commands









How To Enter Commands


There are 3 ways to use a command.  You can enter it in chat, enter it in console, or bind a key to use it.  Each method has its own format, so make sure you read this!





Using Commands In Chat

First off, I should explain that there are 2 type of commands that you can type in chat.  One type is called a chat trigger. 

I won't go into the details, but these commands can ONLY be typed in chat.  99% of the other commands are regular sourcemod commands that can be entered in the 3 ways discussed here. 

If you want to see a list of the chat triggers, see the chat triggers page.

To use a sourcemod command in chat, simply put a slash in front of it.  For instance, if you want to load up the player menu from chat, you would type in /menu. 

If you wanted to remove your checkpoint, you could type /ucp. 





Binding Keys To Use Commands


Binding keys to do things is usually your best bet.  For example, you could bind your C key to save your checkpoint when you press it. 

If you do not know what a certain key is named, like the keypad up arrow, you can find out by going into your normal keyboard settings and temporarily assigning it to a standard function. 

Then after you know what it is called (kp_uparrow), be sure to clear the key for that thing you just set.

To bind a key to load up the player menu, you could type something like this into your console.

bind c sm_menu

To bind a key to a command that has more than one word in it, such as to set your model to a specific model, then enclose the command in quotation marks. 

So, to set your model to sonic the hedgehog by hitting your N key, you would type this in...

bind n "sm_model sonic"

To see more about binding keys and some examples, check out the binding commands page.