Console commands (Counter-Strike 2D)

From Unreal Software English Wiki
Jump to: navigation, search
px This article/section is missing content.
You can help expand it by editing it

Below is a list of Counter-Strike 2D console commands with a description of their parameters and functions.

Command Parameters Info
ah
  • help (0/1)
Enables/disables automatic help. Additional texts and instructions will appear if this is set to 1.
ak47 none Buys an AK47.
alias
  • name (text) - name of the alias
  • script (text) - script to be executed

Creates an alias. An alias works like a script command.

ex. alias "test" "echo test!; echo 123" - this creates the new command "test" which prints the lines "test!" and "123" in your console.

CS2D does NOT automatically save your aliases. All aliases will be removed as soon as you quit CS2D.

aliases none Prints a list of aliases in the console.
attack none Attacks with the current weapon.
attack2 none Alternative attack. Is not available for most weapons. Switches the weapon mode (zoom, silencer, burst, color etc.) for several weapons.
aug none Buys an AUG.
autobuy none

Automatically tries to purchase the best items which are available for your money.

The principle behind this is pretty simple: Counter-Strike 2D reads the file "sys/autobuy.cfg" and tries to buy the items in the same order as they are listed in this file. Read the file for details.

autoscreen
  • autoscreen (0/1) - take screenshots automatically?
Select if you want to take screenshots of the scoreboard automatically after each round.

Same as hud_takesshots!

autoswitch
  • autoswitch (0/1) - automatically switch to collected weapon?
You will automatically switch to the weapon you've collected if this is set to 1. Otherwise you will just collect it without switching to it.
awp none Buys an AWP.
back none Moves the player backwards.
banip
  • ip (text) - player IP
  • duration (-1 - 1440) - duration of ban

Bans an IP address. Players with this IP will not be able to join anymore.

This command supports wildcards (*). The address does always have to have 3 dots even when using wildcards. Some examples:

123.*.*.* = ban every ip starting with 123

*.*.*.123 = ban every ip ending with 123

*.123.234.* = ban every ip with 123.234 in the middle

The following ban addresses are NOT supported! Do NOT use comparable bans:

123.* = not enough dots

*.123.234 = not enough dots

12*.*.* = mixed digits and * (12*) are not supported

You can also specify a duration if you want the ban to be temporary only. Use -1 if you want to use the value of mp_tempbantime as duration or use a value >0 to specify the ban duration in minutes. 0 means that the ban will be infinite (default).

banname
  • name (text) - player name
  • duration (-1 - 1440) - duration of ban

Bans a name. Players with this name will not be able to join anymore.

You can also specify a duration if you want the ban to be temporary only. Use -1 if you want to use the value of mp_tempbantime as duration or use a value >0 to specify the ban duration in minutes. 0 means that the ban will be infinite (default).

bans none

Shows a list of all bans at your server (as server only).

Same as listbans.

banusgn
  • usgn (number) - USGN account ID
  • duration (-1 - 1440) - duration of ban

Bans an U.S.G.N. account. The player with this account will not be able to join if he is logged in.

You can also specify a duration if you want the ban to be temporary only. Use -1 if you want to use the value of mp_tempbantime as duration or use a value >0 to specify the ban duration in minutes. 0 means that the ban will be infinite (default).

bind
  • key (key) - key to bind script to
  • script (text) - script to be executed

Bind a script to a key. Afterwards you can execute the script by pressing the key as often as you want.

For example: bind "L" "say lol"

Now you can say "lol" by pressing "L".

CS2D does NOT automatically save your binds. All binds will be removed as soon as you quit CS2D. You can also use unbindall to remove all binds.

CS2D uses the file "sys/controls.cfg" to save the controls which have been set in the controls menu!

bot none Opens the bot menu.
bot_add none Adds a bot to the team with least players.
bot_add_ct none Adds a bot to the Counter-Terrorist team.
bot_add_t none Adds a bot to the Terrorist team.
bot_count
  • count (0-32) - number of bots to add after server start
Selects how many bots join the server after starting it.

Does not have any effect when executed after start.

bot_jointeam
  • team (0-2) - team the bots will join (0 - Spectators, 1 - Terrorists, 2 - Counter-Terrorists)
Selects which team the bots will join.
bot_kill none Kills all bots.
bot_prefix
  • prefix (text) - bot name prefix
Sets a prefix for all bot names. This makes it easier to see which players are bots.

You have to change this setting BEFORE bots join. It does NOT affect bots who already joined.

Set it to "" if you don't want to use a prefix for bots.

bot_remove none Removes a random bot.
bot_remove_all none Removes all bots.
bot_remove_ct none Removes a random bot from the Counter-Terrorist team.
bot_remove_t none Removes a random bot from the Terrorist team.
bot_skill
  • skill (0-4) - skill level (0 - low, 4 - high)
Sets the skill level of all bots.
bot_weapons
  • weapons (0-7) - groups of weapons bots can use

Defines which weapons bots will buy and use:

0 - all weapons

1 - melee only

2 - pistols only

3 - shotguns only

4 - smgs only

5 - riles only

6 - sniper rifles only

7 - mgs only

bullets
  • draw (0/1) - draw bullets?
Enables/disables drawing bullets when firearms are fired. Disabling this option is advisable if playing on slow computers.
buy none Opens the buying menu.
buyammo1 none Purchases the ammo for primary weapons.
buyammo2 none Purchases the ammo for secondary weapons.
buyequip none Opens the equipment buying menu (B->8).
changelevel
  • map (text) - name of map

Changes the map on a server.

Same as sv_map, map and changemap.

changemap
  • map (text) - name of map

Changes the map on a server.

Same as sv_map, map and changelevel.

chooseteam none Opens the team changing menu.

Same as team.

clientport
  • port (0-65535) - local port, 0 - autodetect

This setting is recommended for experienced users only! It forces the game to use a special port in client mode.

It is recommended to use 0 (auto detection). In this case CS2D will find the best port automatically.

Same as localport!

close none Closes all current windows.
connection
  • speed (0-2) - internet connection speed, 0 - slow, 2 - fast

Selects the speed of your internet connection.

connections none Shows a list of active UDP connections in the console.
console none Opens/closes the console.
copyaddress none Copies the IP address of the server you're currently on into the clipboard.
customkill
  • killer (0-32) - killer ID or 0 for no killer
  • weapon (text) - weapon the victim was killed with
  • victim (1-32) - victim ID
Simulate a kill with a custom weapon (server-only).

Use killer 0 for suicides or "environment kills".

deagle none Buys a Desert Eagle.
deathslap
  • player (1-32/text) - player ID
Slaps a player to death killing him.
debug
  • debug (0/1) - debug mode on/off

Enables/disables the debug mode.

In debug mode you get additional console output. Moreover you will see the current FPS (frames per second) in the top left corner of the screen.

Enable the debug mode if you have problems.

debugai
  • debug (0/1) - show/hide additional AI debug info

Shows/hides additional AI debug info.

debuglog
  • log (0/1) - debug logging on/off

Enables/disables creating debug logs (text files) with the whole console output.

debuglua
  • debug (0/1) - Lua debug on/off

Enables/disables printing additional debug messages about Lua scripts into the console.

debugstats none Show stat system debug information.
defuser none Buys Defuse Kit (Counter-Terrorist only)
disconnect none Disconnects from current server to main menu.

Same as exit.

dmgindicator
  • show (0/1) - show/hide damage indicator
Enables/disables damage indicator showing the direction damage came from. Useful for finding enemies.
drawradar
  • draw (0/1) - show/hide radar
Shows/hides radar on your screen.
drop none Drops the weapon you're currently wielding.
echo
  • message (text) - message to show in console

Sends a message to the console.

Can be used for script debugging or information. Everyone sees only own echo messages.

effect
  • effect (text) - effect type
  • x (0-N) - x position in pixels
  • y (0-N) - y position in pixels
  • p1 (0-N) - parameter 1 (usually amount)
  • p2 (0-N) - parameter 2 (usually radius)
  • r (0-255) - color red
  • g (0-255) - color green
  • b (0-255) - color blue
Creates effects on the map. The usage of the parameters depends on the type. You can use r,g,b to define a color for some of the effects, however not all of them support coloring. The amount is limited to a maximum of 100 in most cases.

"fire"

fire particles (yellow/orange/red).

p1=amount, p2=radius

r,g,b=no influence


"smoke"

smoke particles (gray).

p1=amount, p2=radius

r,g,b=no influence


"flare"

flare particles with certain color.

p1=amount, p2=radius

r,g,b=color


"colorsmoke"

smoke particles with certain color.

p1=amount, p2=radius

r,g,b=color

elite none Buys an Elite.

Same as elites.

elites none Buys an Elite.

Same as elite.

equip
  • player (1-32) - player ID
  • item (1-255) - item ID
Gives a weapon to a player (as server only).

Hint: Use the editor and the Env_Item entity to see the IDs of weapons.

Attention: A player can hold only one weapon of the same type. Equipping an existing weapon again will refill its ammunition.

exec
  • file (text) - file address (relative to CS2D folder)

Executes all scripts in a script (text) file.

Same as include.

exit none Disconnects from current server to main menu.

Same as disconnect.

explosion
  • x (0-N) - x position of explosion in pixels
  • y (0-N) - y position of explosion in pixels
  • size (0-N) - size of explosion in pixels
  • damage (0-N) - explosion damage
  • source (0-32) - source player ID, 0 for no source

Creates an explosion somewhere on the map (as server only).

You can specify a source player. This player will get the score etc. when the explosion kills someone, however it's optional. Don't specify the last parameter or enter a 0 when your explosion is not caused by a player.

famas none Buy Famas
flash none Buy Flashbang
flashplayer
  • player (0-32): player who will be flashed (0 for all)
  • intensity (0-100): flash intensity
Flash one or all players.
flashposition
  • x (0-X): x position in pixels
  • y (0-X): y position in pixels
  • intensity (0-100): flash intensity
Flash all players who are close to the position + which have a direct line of sight to this position (without wall).

Pretty similar to the explosion of a flashbang.

fn57 none Buy FN57
forward none Move player forward.
fowalpha
  • opacity (0-100): invisible (0) - opaque/black (100)
Set the opacity of the fog of war.
fowdetails *details (0-1): details of fog Select how detailed fog of war is.

High fog of war details can slow down the game on slow systems!

fps none Prints the current FPS value (frames per second) to the console.

Useful to check if a server runs at maximum speed (50 FPS)


Personal tools
Namespaces
Variants
Actions
Navigation
Toolbox