Bot: Difference between revisions
m (Added Botrix in see also) |
m (Setting bug notice hidetested=1 param on page where the bug might not need tested in param specified) |
||
(33 intermediate revisions by 14 users not shown) | |||
Line 1: | Line 1: | ||
{{LanguageBar}} | |||
{{Delisted|csgo|cat=doc}} | |||
{{stub}} | {{stub}} | ||
A '''bot''' (short for robot) is similar to an [[NPC]] in a multiplayer game, usually designed to behave like a human-controlled player. An example is the [[ | A '''bot''' (short for robot) is similar to an [[NPC]] in a multiplayer game, usually designed to behave like a human-controlled [[player]]. An example is the {{css|4}} bot. | ||
{{confusion|Bots are considered [[player]]s, not [[NPC]]s.}} | |||
Given the team-based competitive nature behind many first-person shooters, | == Long Version == | ||
Given the team-based competitive nature behind many first-person shooters, a player who plays offline games, presumably with limited or no internet access, will be missing out on a huge portion of the game. To remedy this, these games usually come with bots, which are NPCs that behave like a human player. | |||
Another distinct definition of bot is that of a computer program which is commonly designed to perform monotonous or hard-to-achieve tasks such as "farming" and raising levels in RPG-type games. As a result, most RPG games have banned them from use because it is considered '''''cheating'''''. In FPS games this type of bot is also known to be a form of cheating. It helps players achieve better scores by improving their aim and reflexes which, in the extreme case, are completely controlled by the bot software. | Another distinct definition of "bot" is that of a computer program which is commonly designed to perform monotonous or hard-to-achieve tasks such as "farming" and raising levels in RPG-type games. As a result, most RPG games have banned them from use because it is considered '''''cheating'''''. In FPS games this type of bot is also known to be a form of cheating. It helps players achieve better scores by improving their aim and reflexes which, in the extreme case, are completely controlled by the bot software. | ||
==See also== | == Bot Classes and Properties == | ||
* [[Navigation Meshes]] | |||
{| border="2" cellpadding="5" style=margin:1em | |||
|- style="background:#404040;" | |||
!rowspan=2| Bot Class | |||
!rowspan=2| Game | |||
!rowspan=2| Target Class<br>for [[I/O]], [[VScript]] | |||
!colspan=2| Affected by...? | |||
|- style="background:#404040;" | |||
! [[File:Toolsnpcclip.gif|64px|link=npc clip|NPC Clip]] | |||
! [[File:Toolsblocklos.gif|64px|link=LOS|LOS Blockers]] | |||
|- | |||
|rowspan=3| [[cs_bot]] | |||
| {{css|4}} | |||
| player | |||
| {{yes}} | |||
| {{no}} | |||
|- | |||
| {{csgo|4}} | |||
| [[cs_bot]]<sup>1</sup> | |||
| {{yes}} | |||
| {{yes}} | |||
|- | |||
| {{cs2|4}} | |||
| [[cs_bot]]{{confirm}} | |||
| {{yes}}{{confirm}} | |||
| {{yes}}{{confirm}} | |||
|- | |||
| [[survivor_bot]] | |||
| {{l4d|4}}<br>{{l4d2|4}} | |||
| player | |||
| {{no}} | |||
| {{yes}} | |||
|- | |||
| [[tf_bot]] | |||
| {{tf2|4}} | |||
| player | |||
| {{no}} | |||
| {{no}} | |||
|} | |||
{{inline note|name=1|In VScript, if <code>bot</code> is the handle of a cs_bot, then <code>bot.[[List of CS:GO Script Functions#Methods|GetClassname]]()</code> always delivers <code>"player"</code>.<br>If a cs_bot receives a {{ent|targetname}}, it turns into a <code>player</code>.}} | |||
=== Determining game mode === | |||
In {{css}}, the built-in bots determine what game mode the current map is designed for based upon the last instance of an entity with one of the following [[classname]]s: | |||
{| class="wikitable" | |||
|- | |||
! Classname !! Game mode | |||
|- | |||
| {{ent|func_bomb_target}} || Bomb defusal | |||
|- | |||
| {{obs}}{{ent|info_bomb_target|engine=goldsrc}} || Bomb defusal | |||
|- | |||
| {{ent|func_hostage_rescue}} || Hostage rescue | |||
|- | |||
| {{obs}}{{ent|info_hostage_rescue|engine=goldsrc}} || Hostage rescue | |||
|- | |||
| {{ent|hostage_entity}} || Hostage rescue | |||
|- | |||
| {{obs}}{{ent|func_vip_safetyzone|engine=goldsrc}} || {{obs}}VIP assassination | |||
|} | |||
If none of these are currently present, then it defaults to "fight yard" (eliminate opposing team). | |||
{{important|This means that if a map has both hostages ''and'' bombsites, bots will only go for one or the other! A third-party bot plugin is necessary for such maps to work correctly with bots.}} | |||
== Related Console Commands and Variables == | |||
All games with bots have ConCommands and ConVars to control them. These might have slightly different side effects per game. | |||
{{note|{{tf2}} The following need the prefix <code>tf_</code>, such as <code>tf_bot_add</code>.}} | |||
{{note|For commands to modify where bots can go, see [[Nav Mesh Commands]]. To learn how to use them, see [[Nav Mesh Editing]].}} | |||
{| class=standard-table | |||
! ConCommand / ConVar !! Description | |||
|- id="bot_add" | |||
| <tt>bot_add</tt> || Adds a bot to the server. Parameters can be used to set the name, team or difficulty of the new bot. This command might do nothing the first time if <tt>bot_quota_mode</tt> is set to <tt>fill</tt>. | |||
|- id="bot_dont_shoot" | |||
| <tt>bot_dont_shoot</tt> {{css}}{{csgo}} || Determines whether bots will intentionally shoot at enemies or not. They might still shoot for example if they are blinded by a [[weapon_flashbang|flashbang]] or if a [[func_breakable]] is in their way. {{note|In {{l4d|4}} and {{l4d2|4}}, even if this parameter is off, bots will frequently shove ({{code|+attack2}}) {{code|func_breakable}} objects nearby them anyway, or entities perceived to be in their way.}} | |||
|- id="bot_kick" | |||
| <tt>bot_kick</tt> || Remove all bots from the server. Parameters can be used to target only specific bots.<br>{{csgo}} Bots don't die in this process such that they don't drop any equipment. | |||
|- id="bot_kill" | |||
| <tt>[[bot_kill]]</tt> || Cheat command that makes all bots suicide. If a parameter is given, tries to kill the bot with that name. | |||
|- id="bot_quota" | |||
| <tt>[[bot_quota]]<br>bot_quota_mode</tt> || Determines the number of bots on the server that are added automatically. | |||
|- id="bot_stop" | |||
| <tt>bot_stop</tt> || If set to non-zero, bots won't do anything. | |||
|- id ="bot_moveto" | |||
| <tt>bot_moveto</tt> || Will move a generic bot. {{bug|hidetested=1|If used on a [[NextBot]], the game will crash. {{in|{{tf2}}}}|only=tf2}} | |||
|} | |||
== See also == | |||
* [[Nav Mesh|Navigation Meshes]] | |||
* [[NextBot]] | |||
* [[Server-Side Bots]] | * [[Server-Side Bots]] | ||
* [[RCBot2]] | |||
* [[Botrix]] | * [[Botrix]] | ||
* {{csgo}} [[CS:GO Bot Behavior Trees|Bot Behavior Trees]] | |||
* {{csgo}} [[CS:GO VScript Examples#Functions to distinguish bots and human players|VScript Examples#Functions to distinguish bots and human players]] | |||
==External links== | ==External links== | ||
Line 16: | Line 109: | ||
[[Category:Glossary]] | [[Category:Glossary]] | ||
{{stub}} |
Latest revision as of 07:08, 20 May 2025


It is covered here for historical and technical reference.
A bot (short for robot) is similar to an NPC in a multiplayer game, usually designed to behave like a human-controlled player. An example is the Counter-Strike: Source bot.
Long Version
Given the team-based competitive nature behind many first-person shooters, a player who plays offline games, presumably with limited or no internet access, will be missing out on a huge portion of the game. To remedy this, these games usually come with bots, which are NPCs that behave like a human player.
Another distinct definition of "bot" is that of a computer program which is commonly designed to perform monotonous or hard-to-achieve tasks such as "farming" and raising levels in RPG-type games. As a result, most RPG games have banned them from use because it is considered cheating. In FPS games this type of bot is also known to be a form of cheating. It helps players achieve better scores by improving their aim and reflexes which, in the extreme case, are completely controlled by the bot software.
Bot Classes and Properties
Bot Class | Game | Target Class for I/O, VScript |
Affected by...? | |
---|---|---|---|---|
![]() |
![]() | |||
cs_bot | ![]() |
player | Yes | No |
![]() |
cs_bot1 | Yes | Yes | |
![]() |
cs_bot[confirm] | Yes[confirm] | Yes[confirm] | |
survivor_bot | ![]() ![]() |
player | No | Yes |
tf_bot | ![]() |
player | No | No |
bot
is the handle of a cs_bot, then bot.GetClassname()
always delivers "player"
.If a cs_bot receives a targetname, it turns into a
player
.Determining game mode
In , the built-in bots determine what game mode the current map is designed for based upon the last instance of an entity with one of the following classnames:
Classname | Game mode |
---|---|
func_bomb_target | Bomb defusal |
![]() |
Bomb defusal |
func_hostage_rescue | Hostage rescue |
![]() |
Hostage rescue |
hostage_entity | Hostage rescue |
![]() |
![]() |
If none of these are currently present, then it defaults to "fight yard" (eliminate opposing team).

Related Console Commands and Variables
All games with bots have ConCommands and ConVars to control them. These might have slightly different side effects per game.

ConCommand / ConVar | Description |
---|---|
bot_add | Adds a bot to the server. Parameters can be used to set the name, team or difficulty of the new bot. This command might do nothing the first time if bot_quota_mode is set to fill. |
bot_dont_shoot ![]() ![]() |
Determines whether bots will intentionally shoot at enemies or not. They might still shoot for example if they are blinded by a flashbang or if a func_breakable is in their way. ![]() ![]() ![]() |
bot_kick | Remove all bots from the server. Parameters can be used to target only specific bots.![]() |
bot_kill | Cheat command that makes all bots suicide. If a parameter is given, tries to kill the bot with that name. |
bot_quota bot_quota_mode |
Determines the number of bots on the server that are added automatically. |
bot_stop | If set to non-zero, bots won't do anything. |
bot_moveto | Will move a generic bot. ![]() ![]() |
See also
- Navigation Meshes
- NextBot
- Server-Side Bots
- RCBot2
- Botrix
Bot Behavior Trees
VScript Examples#Functions to distinguish bots and human players
External links