Game Modes
It is covered here for historical and technical reference.
Here are tables of the game modes and the console commands to launch them in Counter-Strike: Global Offensive and Counter-Strike 2.
The paths named on this page are relative to .../steamapps/common/Counter-Strike Global Offensive/
or .../steamapps/common/Counter-Strike Global Offensive/game/
respectively.
- The game supports the game modes Casual, Competitive, Wingman, Training Day and Deathmatch.
- Custom works as usual. In Guardian, special kills are not counted such that the human players cannot win as intended. In both Arms Race and Demolition, the players are not given any guns but the C4.
- Skirmish modes seem not to be implemented yet.
- The
map
command does not support a game mode parameter.
Overview
To launch a map with a desired game mode, adjust the ConVars
game_type
,game_mode
,sv_game_mode_flags
andsv_skirmish_id
according to the tables below and load a map by using the map <mapname>
or changelevel <mapname>
console command.
mp_warmup_start
.
|
For details, see #Game Type and Game Mode.
|
For details, see #Skirmish Modes.
|
Loading a Map
When loading a map, the game will...
- set the whitelisted ConVars (the ones listed in
csgo/bspconvar_whitelist.txt
) to their default value,[no such file in CS2] - execute the CFG files associated with the current values of
game_type
andgame_mode
(defined incsgo/gamemodes.txt
andcsgo/gamemodes_server.txt
), - execute the CFG file associated with the current value of
sv_game_mode_flags
, see below, and - execute the CFG file associated with the current value of
sv_skirmish_id
(defined incsgo/scripts/items/items_game.txt
underskirmish_modes
), see below.
If these four ConVars are not set before loading a map, the map launches in the last game mode played. Their initial value is 0 (Casual).
map
and changelevel
commands have an optional <game mode alias>
parameter. Example: map de_dust2 deathmatch
or changelevel myCustomMap coop
. If such an alias parameter is given and if it is valid, the game will adjust game_type
and game_mode
and launch the map with the associated game mode. See the map command aliases column in the following big table.map <mapname> default
or map <mapname> auto
. See #Map default.+game_type <number> +game_mode <number> +map <mapname>
alias MyMapRetake "game_type 0; game_mode 0; sv_skirmish_id 12; map MyMap"
. Best used in autoexecs which allows to quickly launch and test custom maps in the right game mode.competitive
, as this causes them to stop.
gamemode_competitive_server.cfg
(see below) to automatically set bot_quota
and bot_quota_mode
to have bots on your local server whenever you load a map in Competitive.csgo/materials/panorama/images/icons/ui/<internal mode name>.svg
. If sv_skirmish_id
is not 0, the internal name of the skirmish mode is used. If the game doesn't have the file, one can put a custom one to that place.Game Type and Game Mode
game_type
and game_mode
are console variables that determine how the next map is initialized when loaded, including but not limited to the execution of CFG files, used to set some of the countless ConVars that control game rules, for example mp_roundtime
, mp_t_default_secondary
, sv_deadtalk
and so forth.
Apart from that, there are also other game rules or settings for which the value of game_type
and game_mode
is checked during the current match.
Examples are the UI for all players, the events when weapon_c4 is planted or defused, whether item_heavyassaultsuit causes a screen tint, whether players can pick up experimental weapons such as weapon_axe, ...
The following table lists all available game modes along with their values for game_type
and game_mode
, their internal name, their aliases for the map
command, their default maximum number of players, the CFG files that are executed when a map is launched in this game mode, and a description.
_offline.cfg
are only executed if the server was launched via Practice with Bots from the main menu. Valve uses them to enable bots in offline competitive since bots have been disabled in competitive by default, see bot_quota. The CFG files ending with
_server.cfg
don't exist locally by default. You can create them and write commands into them that will be executed every time you locally launch the corresponding game mode.
csgo/gamemodes.txt
. The possible map command aliases can be found in the function
GameTypes::GetGameTypeAndModeFromAlias
defined in gametypes.cpp
.
Game Mode | type | mode | Internal Name | map command aliases |
max- players |
CFG filenames executed, if existent | Description | |
---|---|---|---|---|---|---|---|---|
Casual (default) | casual | casual | 20 | gamemode_casual.cfg, gamemode_casual_server.cfg |
Like Competitive but with fewer rounds, shorter freezetime per round, no friendly fire, no team collision, free armor and free defuse kit/cutters. | |||
Competitive | competitive | competitive, comp | 10 | gamemode_competitive.cfg, gamemode_competitive_offline.cfg (!) gamemode_competitive_server.cfg |
The classic game mode, usually made for 5v5. Best of 30 rounds, teams are switched at halftime, friendly fire is on. Round-ending objectives are elimination, bomb explosion, bomb defusal, hostage rescue and timeout. | |||
Wingman | scrimcomp2v2 | scrimcomp2v2 | 4 | gamemode_competitive2v2.cfg, gamemode_competitive2v2_offline.cfg (!) gamemode_competitive2v2_server.cfg |
Like Competitive, but adjusted for 2v2 and for a smaller map or a map section. Best of 16 rounds. Also, each round is shorter. | |||
Weapons Expert | scrimcomp5v5 | scrimcomp5v5 | 10 | gamemode_competitive.cfg, gamemode_competitive_offline.cfg (!) op08_weapons_expert.cfg, gamemode_competitive_server.cfg |
Like Competitive but every player can buy each weapon at most once per match. The freezetime is a bit longer. | |||
Training Day | new_user_training | new_user_training | 10 | gamemode_new_user_training.cfg | Like Competitive with bots but automatically assigning humans to Terrorists with game instructions turned on. This game mode's CFG file also specifies a behavior tree for the bots that is made for Dust II. | |||
Arms Race | gungameprogressive | armsrace, arms, gungame, gg, gungameprogressive |
10 | gamemode_armsrace.cfg, gamemode_armsrace_server.cfg |
The game is one perpetual round where killed players respawn at the default spawns. A weapon progression (a number of guns and their order) is defined where players win by making a specified number of kills with each of these weapons. | |||
Demolition | gungametrbomb | demolition, demo, gungametrbomb |
10 | gamemode_demolition.cfg, gamemode_demolition_server.cfg |
A mixture of Casual with Armsrace. Best of 20 rounds. Each player is given a fixed weapon for each round, depending on their individual progress. Each player can progress one gun per round by making at least one kill. | |||
Deathmatch | deathmatch | deathmatch, dm | 16 | gamemode_deathmatch.cfg, gamemode_deathmatch_server.cfg |
Like Armsrace but with free weapon choice and respawns across the map. Kills grant points, depending on the weapon type and if it is currently the bonus weapon. A player wins by scoring the highest after the round's time limit. | |||
Training | training | training | 1 | gamemode_training.cfg, gamemode_training_server.cfg |
Assigns clients to CT with no weapon. No round limit, no time limit, no freezetime, minimal HUD. Good for singleplayer maps, used on CS:GO's Training Course. | |||
Custom | custom | custom | 100 | gamemode_custom.cfg, gamemode_custom_server.cfg |
Like Undefined, see below. This is an "empty" game mode allowing mapmakers to implement any map-specific custom game mode, if they wish to. If sv_autoexec_mapname_cfg is not 0 (which however it its default value), the CFG file csgo/maps/cfg/<mapname>.cfg is executed with whitelist.
| |||
Guardian | cooperative | guardian, guard, cooperative |
20 | gamemode_competitive.cfg, gamemode_cooperative.cfg, gamemode_cooperative_server.cfg |
Two human players must defend a bombsite as CT or hostages as T against rushing bots. Maps must support this mode to work as intended. | |||
Co-op Strike | coopmission | coop, coopstrike, coopmission |
10 | gamemode_competitive.cfg, gamemode_coopmission.cfg, gamemode_coopmission_server.cfg |
Usually a custom mission for two human players on a custom map that is designed primarily for this mode. | |||
War Games | skirmish | skirmish | 12 | - | Like Undefined, see below. Risk of Confusion:This game type is not used for #Skirmish Modes, also known as War Games.
| |||
Danger Zone | survival | survival | 16 | gamemode_survival.cfg, gamemode_survival_server.cfg |
A Battle Royale mode for big maps where players win by being the last man (or team) standing. Maps must be designed for this mode to work as intended. | |||
Workshop | workshop | workshop | 1 | gamemode_workshop.cfg, gamemode_workshop_server.cfg |
Clarify: Seems unused yet. Appears in the file
csgo/pak01_dir.vpk/gamemodes_tools/gamemodes_tools.txt and is not yet a legal combination of game_type and game_mode. | |||
Map default | description |
- | default, auto | depends | depends | This is not a game mode itself, rather a "redirect". The game picks game_type and game_mode from the map's default_game_type and default_game_mode values, defined in either csgo/maps/<mapname>.kv , csgo/gamemodes.txt (under maps/<mapname>/ ) or csgo/gamemodes_server.txt . If they are defined in more than one of these files, the latter of the named files overrides the former. If they are not defined in any of these, the current type and mode are kept. All official maps use this appropriately (just that competitive maps use Casual).
Example:
| ||
Undefined | the above |
- | - | ? | - | No CFG file is executed, only the whitelisted ConVars are set to their default value. By default this results in game rules like Casual but with no round limit, instead with a time limit of 5 minutes for the game and map. mp_roundtime is also set to 5 minutes.
|
Game Mode Flags
The ConVar sv_game_mode_flags
is used for game mode variations. It can determine more CFG files that will be executed after the game mode CFG files when a map is launched.
Its value is read bitwise, meaning that adding values of the following table together results in all associated CFG files being executed.
Value | CFG file executed, if existent |
---|---|
4 | gamemode_<internal game mode name>_tmm.cfg
|
32 | gamemode_<internal game mode name>_short.cfg
|
_short
CFG is executed before a _tmm
CFG.- If set to 32 and a map is launched in Wingman, it will cause the execution of the CFG file
gamemode_scrimcomp2v2_short.cfg
. - If set to 36 and a map is launched in Wingman, it will cause the execution of the CFG files
gamemode_scrimcomp2v2_short.cfg
andgamemode_scrimcomp2v2_tmm.cfg
, in this order.
Valve currently uses this to implement game mode variations without touching sv_skirmish_id
.
Game Mode | Flags Value | |||
---|---|---|---|---|
0 | 4 (tmm) | 32 (short) | ||
Competitive | default | Short Match | ||
Deathmatch | default | Team vs Team | Free For All |
game_type 1; game_mode 2; sv_game_mode_flags 4; map <mapname>
, or shorter: sv_game_mode_flags 4; map <mapname> dm
.Skirmish Modes
War Games are game mode variations.
The ConVar sv_skirmish_id
determines the War Game that a map will be launched in. Each War Game can have CFG files associated to it that are executed if a map is launched in that War Game, namely if sv_skirmish_id
is set to the ID of that War Game. These CFG files contain only few commands and are executed after the CFG files of a game mode and after the CFG files of the game mode flags. They can be loaded in any game mode, but each skirimsh CFG file has a game mode that is intended to be used as a base which can be found in the appropriate game's text file and also in the skirmish CFG file itself.
To play one of the following skirmish modes, type sv_skirmish_id <number>
in the console and launch a map with the intended game mode, see above.
Alternatively, one could also do exec <cfg filename>
and mp_restartgame 1
in-game or even write own configs for that matter.
To return to a "pure" game mode found in the above table, set sv_skirmish_id
back to 0, so the game will not load any additional CFG files to a game mode.
- To launch Stab Stab Zap on
de_dust2
, entersv_skirmish_id 1
andmap de_dust2 casual
. This is equivalent tosv_skirmish_id 1; game_type 0; game_mode 0; map de_dust2
. - To launch Competitive on
de_dust2
after having played a skirmish mode, entersv_skirmish_id 0
andmap de_dust2 comp
. This is equivalent tosv_skirmish_id 0; game_type 0; game_mode 1; map de_dust2
.
csgo/cfg/
that have no associated skirmish ID. They are mentioned at the end of the following table.csgo/scripts/items/items_game.txt
under skirmish_modes
or in csgo/scripts/items/skirmish_ids.txt
.War Game | skirmish _id |
Internal Name | Intended Game Mode | CFG filenames executed with whitelist | Description | |
---|---|---|---|---|---|---|
None (default) | - | - | - | No Skirmish Mode, i.e. the game mode defined by game_type and game_mode .
| ||
Stab Stab Zap | stabstabzap
|
Casual | op08_stab_stab_zap.cfg | Only knives, recharging taser and grenades. | ||
Free For All | dm_freeforall
|
Deathmatch | gamemode_dm_freeforall.cfg | Like Deathmatch, but teammates are enemies. Note:The official FFA Deathmatch mode is not this skirmish mode, see #Game Mode Flags.
| ||
Flying Scoutsman | flyingscoutsman
|
Casual | op08_flying_scoutsman.cfg | Only scouts and knives, low gravity, high precision. | ||
Trigger Discipline | triggerdiscipline
|
Casual | op08_trigger_discipline.cfg | Gunshots that a player does not hit an enemy with damage theirselves down to a minimum of 1 HP. | ||
Boom! Headshot! | headshots
|
Deathmatch | op08_headshots.cfg | Helmets are disabled and bodyshots deal no damage, causing a small spark effect instead of blood. | ||
Hunter-Gatherers | huntergatherers
|
Deathmatch | op08_hunter_gatherers.cfg | Team deathmatch with collecting dogtags: Killed enemies will drop dogtags that anyone can pick up. Collecting dogtags from the enemy team awards victory points. Killing enemies with the Deathmatch bonus weapon makes them drop an extra dogtag. The team with the most victory points at the end of the time limit wins. | ||
Heavy Assault Suit | heavyassaultsuit
|
Casual | op08_heavy_assault_suit.cfg | Heavy armor can be purchased for $6000. Deprecated:The item is no longer accessible, neither using the buy menu, nor with the command
buy heavyarmor , rendering this skirmish mode useless. | ||
Arms Race | armsrace
|
Arms Race | - | Equivalent to #Arms Race. | ||
Demolition | demolition
|
Demolition | - | Equivalent to #Demolition. | ||
Retakes | retakes
|
Casual | gamemode_retakecasual.cfg | Each round, 3 Terrorists spawn on a bomb site with a bomb being planted and 4 CTs spawn at fixed locations around it or on the other bomb spot. Each player can choose a loadout card at round start. Warning:If there is exactly one bombsite, the game crashes with a probability of 50 %.
| ||
Bloodletter | - | Arms Race | op08_bloodletter.cfg | Dealing damage heals you 100 % of the damage dealt (max 200). Players take non-lethal damage over time while they are alive. | ||
Bounty Hunter | - | Deathmatch | op08_bounty_hunter.cfg | All players are enemies, killed enemies will drop dogtags that anyone can pick up. Killing players awards less points. Collecting dogtags awards additional Deathmatch points. | ||
Team Deathmatch | - | Deathmatch | op08_team_deathmatch.cfg | Killing enemies is worth team victory points, killing enemies with the Deathmatch bonus weapon awards additional victory points. The team with the most victory points at the end of the time limit wins. Note:The official Team Deathmatch mode is not this skirmish mode, see #Game Mode Flags.
|
Game Mode dependent Events
local nType = ScriptGetGameType() // game_type
local nMode = ScriptGetGameMode() // game_mode
if (nType == 0 && nMode == 2)
{
// code executed only in Wingman
EntFire( "spawnpoints.2v2", "SetEnabled", "", 0 )
}
else
{
// code executed only in any other game mode
EntFire( "spawnpoints.2v2", "SetDisabled", "", 0 )
}
Note:The variable names
nType, nMode are arbitrary. |
In VScript, there are the specific VScript functions ScriptGetGameType()
and ScriptGetGameMode()
which return the current integer value of game_type
and game_mode
, respectively.
sv_skirmish_id
.These allow VScript structures such as the one on the right; If this example code is executed, it will fire an I/O event to entities named spawnpoints.2v2 depending on the current game mode. Code can be executed every round by saving it in a .nut
file under csgo/scripts/vscripts/
and by adding it to the Entity Scripts of any entity in a map. See also: VScript Fundamentals and Squirrel.
With this concept, one can manipulate gameplay depending on the current game mode, which is a really powerful tool to make other game modes such as Co-op Strike work.
csgo/scripts/vscripts/2v2/2v2_enable.nut
provided by Valve is commonly used to shift player spawn points and activate blockers in Wingman.
|
|