Console Commands

From NS2 community wiki
Jump to: navigation, search

List of implemented console commands. To use them press "~" to open or close the console.

Commands listed in orange require cheats to be enabled.

Commands listed in magenta are only available to server administrators.


Launch Options

Command Parameters Description
+connect <ip> Server IP to automatically connect to.


+password <password> Server password if required when using +connect
game
addpath
config_path
debug
noerrors
hotload
nomodupdate


Debug Commands

Command Parameters Description
profile Enter command to toggle the Profiler on/off. (Monitors performance.)


Keyboard Controls:

  • Spacebar Pauses readout
  • [ ] Cycle frames (while paused)
  • LMB Click on the text bars to open/close the tree menu.
  • Mouse Wheel Scroll up and down the list.
  • M Toggle between the tree display & a sorted list.
  • T Toggle sort by Time or Alphabeticaly
trace <prefix> Toggles all matching tracers to debug hit registration.

Prefix "all" matches all

tracedur <prefix> <duration> Sets the duration of a trace for all matching tracers.
ctrace Turns on client-side trace marking for point of attack and probable targets (yellow)
maxfps <fps> Limits frames per second, minimum is 30FPS. For debug purposes only, does not provide smooth gameplay.
r_stats Toggle list render scene data/stats/FPS
g_stats Toggle GUI stats
e_stats Toggle entity stats
p_stats Toggle physics stats
s_stats Toggle list of sounds currently being played.
s_profile true/false Sound profiling
server_sound true/false Turns server sounds on/off
cinematics Prints info about loaded cinematics
fx_stats Toggle list of sounds & Cinematics being played.
nav_debug Toggle pathing mesh visible
nav_stats Toggle list of navigation mesh info
o_stats [object_type] Shows some information about the objects being created, you can specify object types such as "o_stats Vector" to show specifically Vector objects.
o_stats_pause Pauses/Unpauses the object count tracker (o_stats)
displayannotations <optional build number and map name> Toggle display of annotations.
  • displayannotations
  • displayannotations 200 ns2_tram


vt_start Starts the FPS profiler (stop with vt_stop)
vt_stop Stops the FPS profiler and displays the results
annotate <message> Leave a message at your current position for the map maker to look at.
  • -> annotate Hello World
collision damage, default, move, los, select, predict Toggles the visibility of the collision mesh
  • damage, shows you the collision shapes used for bullets
  • default, shows the default collision mesh (typing "collision" in the console works the same)
  • move, shows the objects that are collided with for movement
  • select, <citation needed>
  • los, <citation needed>
  • predict, shows the client side predicted collisions
physics Toggle physics mesh visibility
dumpmesh Dumps pathing information to file pathingMeshDump.obj
prediction true/false Toggles prediction
hitboxes  ?  ?
waypoints  ?  ?
extents  ?  ?
driftms <float>  ?
reload true  ?
memory Prints out memory information
resources Prints out list of loaded resources
which <filename> Prints the location of the given file. (Ex: "which game_setup.xml")
a_simd true/false Toggles blend SIMD
memory_debug Shows memory fragmentation in a graphical way (green = free, yellow = allocated by game (like scripts), cyan = low level, purple = similar to yellow)
f_log true/false Enable/disable file access logging.
p_log <category> Starts the capture of a profile log.
p_logall [minimal function time] Starts the capture of a profile log. for example p_logall 0 to capture everything
p_endlog Ends the log started with p_logall and writes it to a file
sv_test_event Event check list
record [<filename>] Starts demo recording. Filename is optional. Must enter the record command before connecting to a server (at main menu). Type stop in console to stop recording. To replay a demo type play <filename>. To exit playback mode, type disconnect in console. Playback of a demo requires the same build version as it was recorded.

Keyboard Controls (during playback):

  • Spacebar: Toggles time synchronization. When disabled, the playback will occur as fast as your computer will allow (usually faster than it was recorded)
  • p: Brings up the profiler
  • r: Brings up stats (r_stats)
loadtimes true/false models and textures load times
togglebadgerequest Something to do with badges. May turn them off.
soundgeometry Toggles sound occlusion geometry. Shows a popup where a sound was triggered, and prints in console as well. May cause script errors.
debugnotifications Prints out information about notifications to console
pathingfill  ?
outline Something to do with hivesight effect toggle.
test_events_opacity <float>  ?
resettipvids Resets tip videos
reset_help Resets help widgets
resetcommandertutorial Resets commander tutorial
cents Prints Client entities
changegcsettingclient <settingName> <newValue> Something to do with garbage collection
tracereticule Toggles tracereticule cheat
gothere Tells AI unit to go to location of crosshair


drawdecal <material> <scale> Draws a decal at the location of the crosshair


gothere Tells AI unit to go to location of crosshair
debugpath  ?
followandweld Makes a MAC follow and weld target
distance Prints out distance from the crosshair to an object. Point to an entity to print out information about that entity.
r_animation true/false Disables bone updating (disabled animations)
r_poseparams true/false  ?
gothere Tells AI unit to go to location of crosshair
target Prints out information about entities
hastech <techname> Prints whether or not team has specified tech

Developer Mode

Command Parameters Description
dev 0/1 Disable/Enable Developer mode
anim_debug <class_name> Debug animations (self)
effect_debug <class_name> Debug effects (self)
debugtext <?>  ?

Gameplay Cheats

Command Parameters Description
cheats 0/1 Disable/Enabled Cheats (Server)
switch Swap team at current location (Client)
warp <x> <y> <x> Teleports the player to the specified position
autobuild Toggle autobuild, Structures are placed in a built state. (Server)
create <item> (armoury, observatory) Spawn specified object/structure at crosshair target location. (Server)
darwinmode Toggle unlimited ammo and energy. Cannot take damage (Client)
giveupgrade <upgrade_name> Give your self an unlocked upgrade. (Client)
alltech Unlock all tech upgrades (Server)
pres <amount> Gives player the specified number of Personal Resources, or 100 if not specified (Client)
tres <amount> Gives commander the specified number of Team Resources, or 100 if not specified (Server)
energy Gives selected structure max energy (Server)
takedamage <amount> Hurt your self
killall <entity> (Hive, Cyst, Sentry, Hydra, etc) Destroys every instance of the given entity on the map. Note: entity name is case-sensitive.
killnearby <entity> <distance>(15) Destroys every instance of the given entity on the map within distance. Note: entity name is case-sensitive.
highdamage Turn on high damage mode (x10 damage multiplier) (Server)
damage <multiplier> Multiplies all damage values by <multiplier> (Server)
ents <className> Print out entity count. (Client)
sents <className> Print out entity count. (Server)
entinfo <entityId> Print out entity info.
storeposition Store last position
allfree Everything free for client, non commander
respawn_team Respawn team
push Should push player, doesn't seem to work.


heal <amount> Heals by specified amount
vortex Spawns vortex at player origin
deployarcs Deploy ARC's
undeployarcs Undeploy ARC's
welddoors Welds all doors shut
setgameeffect <effect_name> true/false Enable/Disable a screen effect
command Teleports you to the nearest hive/Command Station and logs you in if built
clearorders Clears orders from the commander
debugspeed Displays a speedometer on your HUD. This can be useful to keep an eye on the speed you gain, for example from walljumping as a skulk.
respawn_team Respawns your entire team
sfindref <class> Finds references to the specified class
infestationspeed <amount> Set how fast infestation grows
music <path> "sound/NS2.fev/" Name of sound from the specified path. Doesn't seem to work.
distress or bacon Beacons to nearest Command Station
selecthallucinations Select all Hallucinations
debugcommander  ?
resizeblobs Unsure if still works
debugblobs Unsure if still works
debuginfest Unsure if still works
blobspeed <scale> Unsure if still works

Alien Specials

Command Parameters Description
give <item> (skulk, gorge, lerk, fade, onos, hydra, crag, whip, shift, shade) Spawns Structure/Class (Client)
skulk, gorge, lerk, fade, onos Transform into lifeform
electrify Electrify self
inkall All built Shades use ink
fastevolve Makes all evolve times 5 seconds
enzyme Gives player enzyme
umbra Gives player umbra
alienvision Disables Alien Vision so it never turns on even when using flashlight.
hivevision true/false Toggles outlines around things in commander view
skulk_view_tilt Toggles Skulk view tilt
lerk_view_tilt Toggles Lerk view tilt

Marine Specials

Command Parameters Description
give <item> (pistol, rifle, shotgun, flamethrower, medpack, ARC, armory, infantry portal, sentry turret, observatory, marine) Gives player an item/weapon
giveammo Give your self ammo for selected weapon.
catpack Give self a catalyst pack injection
exo Gives player an exosuit
dualminigun Gives player a dualminigun exosuit
dualrailgun Gives player a dualrailgun exosuit
clawrailgun Gives player a claw railgun exosuit
nanoshield Gives the player Nano Shield
parasite Applies Parasite to the player
corrode Corrodes self with infestation effect (Client)
rupture Similar to corrode
nanoshield Nanoshield self
giveammo Gives 1 clip of ammo to currently active gun
gore Gives gore effect to player
poison Poisons player (same as Lerk poison)
stun Gives stomp effect to player
spit Plays spit effect on player's screen
changeminizoom <value> Change minimap zoom

Gameplay and Mapping

Command Parameters Description
map <map_name> Starts a new listen server using <map_name>
reset Reset current round
endgame End current round
speed <value> Makes it possible to speed up or slow down the game

For example:

  • speed 0.5, runs the game at 50% speed
  • speed 2, runs the game at 200% speed

It is not recommended to run the game at very high speeds!

onresetgame Flush scoreboard & powernode lights
logout Logout of commander mode.
closemenu Close an open menu
setsquad <squad_number> Assign your self to an existing squad.
location Prints to console your room location.
locate Prints to console your coordinates with respect to the origin of the map.
connect <IP:port> Connects you to server with the specified IP and port.
disconnect Disconnects you from the server and returns to the main menu.
retry Retries to connect to the last server you were on.
exit or quit Closes the game and returns to desktop
name <name> Changes your player name
j1 or jointeamone Joins team 1 (normally marines)
j2 or jointeamtwo Joins team 2 (normally aliens)
j3 Joins a random team
rr or readyroom Joins the ready room
spectate Enter spectating mode
film Hold crouch for dolly, movement modifier for speed or attack to orbit then press movement keys. Ready room player, cheats 1 or dev 1 must be true.
kill Commit suicide
say <text> Speak to all
teamsay <text> Speak to team
tooltip <text> Displays <text> as a tooltip
clear Clears the console
output <string> Displays a timed message on the screen
setsensitivity <float> Mouse sensitivity
pause <integer> Sleeps for the given amount of milliseconds
ssv or setsoundvolume <float> Sound sound effects volume
svv or setvoicevolume <float> Sound voice communication volume
setmusicvolume <float> Sound music volume
setmaplocationcolor <red> <green> <blue> <alpha> Sets the color of location names on the minimap. Numbers are from 0 to 255.
bind <key> <function> Binds the specified key to the specified function (e.g. "bind NumPad0 j1" will bind the number pad "0" key to join marines)
print_bindings Prints all current key bindings
clear_binding <key> Clears the specified binding

Bots

Command Parameters Description
addbot <number of bots> <teamNum> <test/com> <passive> Adds a bot to the optional specified team, with the optional bot type, test for normal bot, com for commander bot. If no team specified, they join a random team.
addbots <number of bots> <teamNum> <test/com> <passive> Adds a bot to the optional specified team, with the optional bot type, test for normal bot, com for commander bot. If no team specified, they join a random team.
addpassivebot <number of bots> <teamNum> <test/com> <className> Adds a bot to the optional specified team, with the optional bot type, test for normal bot, com for commander bot. If no team specified, they join a random team.
removebot <number of bots> <teamNum> Removes the specified number for bots from the optional team. If no team specified, removes a bot from a random team.
bot_target When this command is entered and pointing at a bot, it will print information about that bot
bot_clear Clears and stops output of information from any bot commands
bot_teamdump Dumps information about team bots
bot_debugselected Similar to bot_target
bot_com Prints out information about the commander bot if there is one
marinejitter <amount> Adjusts the amount of aim jittering marine bots have
freezebots Freezes bots

Insight

Command Parameters Description
teams <team1name> <team2name> Sets team names
team1 <team1name> Sets team 1 names
team2 <team2name> Sets team 2 name
score <team1score> <team2score> Sets team scores. Also do-able by clicking the circle between the scores, adding and removing score and flipping it.
scores1 <team1score> Sets team 1 score. Also do-able by clicking the circle between the scores, adding and removing score and flipping it.
scores2 <team2score> Sets team 2 score. Also do-able by clicking the circle between the scores, adding and removing score and flipping it.
johnmadden or jm or pen <red> <green> <blue> <alpha> Sets pen color, numbers 0 to 255.

Render Options

Command Parameters Default Description
r_gui true/false true Enable/Disable all GUI Menus & GUI Overlays
r_atmospherics true/false true Enable/Disable God Rays
r_bloom true/false true Enable/Disable Bloom effect lighting
r_shadows true/false true Enable/Disable shadow rendering
r_shadowsfade true/false true Enable/Disable shadow fade falloff blending (has been truncated)
r_instancing true/false true Turn model instancing on/off
r_wireframe true/false false Turn wireframe mode on/off
r_lights true/false false Toggle light placement data
r_mode lit/unlit/normal,albedo,specular,gloss,depth,emissive,id,none lit Toggle directional lighting on rendered surfaces.
thirdperson [meters] - Toggle third person mode, Optional: Specify distance in meters
r_mt true/false true Enable/Disable multi-threaded rendering
r_aa true/false false Enable/Disable Fast Approximate Anti-Aliasing (FXAA)
r_sync <value>  ? Maximum buffered frames
r_debugging true/false false
r_cull none/frustum frustum Culling
r_particles true/false true Toggle particles
r_anisotropic true/false  ? Enable/Disable anisotropic filtering
r_fog true/false true Toggle fog
r_colordebug  ?  ?  ?
r_reflect true/false false Enable/Disable Reflections (only works on NVIDIA® Graphics currently)
r_ao true/false false Enable/Disable Ambient Occlusion
r_decals
r_loading true/false false Prints out rules applied to textures and other various loading information
r_healthrings true/false false Enable/Disable health rings
fps Enable/Disable FPS indicator on the HUD
print_client_ui Prints out class names of currently used GUIs
print_client_resources  ?
debuggui true/false false Prints out information about GUIs
guiinfo true/false false Pritns out information about GUIs

Networking Commands

Command Parameters Description
net_stats Toggle list network traffic information
net_messages Prints to the console the network messages that the client is receiving
net_peers Prints peer connection information
net_log <log level> (0,1,2...?) Network log
net_lag  ? Simulates network loss
net_loss  ?  ?
net_blackout <interval> <duration> Creates a <duration> second network blackout every <interval> seconds


net_classes  ? seems to print the current classes and any networkVars name and current value to console.
net_usage  ?  ?
net_compensation  ?  ?
net_snapshots  ?  ?
net_test  ?  ?
nm_stats Toggle display of incoming & outgoing network messages for the client.
nms_stats Toggle display of sound network messages.
c_chokedebug true/false Prints state packet send/receive info
networkdiff Show differences in one network snapshot for all subclasses of classname.

Server Commands

Command Parameters Description
sv_ban <PLAYER> <minutes> <reason> Bans player from server
sv_kick <player> Kicks player from server
sv_switchteam <player> <team number> Moves player to specified team
sv_rrall Moves all players to the readyroom
sv_randomall Makes all players join a random team
sv_eject <player> Ejects player from hive/Command Station
sv_help Lists all commands which user has access to
sv_reset Resets the current round
sv_statusip Lists in-game name, game id, steam id, and ip address
sv_status Lists in-game name, game id and steam id address
sv_say <message> Admin broadcast message
sv_tsay <team number> <message> Admin team message
sv_psay <player> <message> Sends personal message to player
sv_slay <player> Kills the specified player
sv_password <password> Adds a password to the server. Use "" as the password to remove the current password
sv_ban <STEAMID> Bans a player from the server
sv_unban <STEAMID> Unban a player from the server
sv_listbans <STEAMID> Lists banned players from the server
cyclemap Forces server to switch to the next map in the Map Cycle (See Dedicated Server#Map Rotation)
changemap <mapname> Change map to specified map
sv_tournament true/false Enables or disabled tournament mode.
sv_reserved_slots <amount> Set the amount of reserved slots available on the server.
sv_add_reserved_slot <amount> Adds a new reserved slot for the SteamID specified.
sv_remove_reserved_slot <amount> Removes the reserved slot for the SteamID specified.
sv_p_log <category> Starts the capture of a profile log.
sv_p_logall [minimal function time] Starts the capture of a profile log. for example p_logall 0 to capture everything
sv_p_endlog Ends the log started with p_logall and writes it to a file
sv_autobalance <true/false> <player count> <seconds> Toggles auto team balance. The player count and seconds are optional. Count defaults to 2 over balance to enable. Defaults to 10 second wait to enable.
sv_auto_afk_kick <seconds> <number> Auto-kick is disabled when the first argument is 0. A player will be kicked only when the server is at the defined capacity (0-1).
mr <float> Changes movement rate of server
interp <float> Changes the interp of the server
Personal tools