Team Fortress 2

Team Fortress 2

126 ratings
How to make bots smarter
By Karamel and 2 collaborators
Are you tired of playing offline because Bot AI is unbelievably underdevolped? Are you like me, whose internet connection consistenly fails you, denying you the oppurtunity to play with your friends and maintain what little skill you have? Then this is the guide for you!
   
Award
Favorite
Favorited
Unfavorite
Introduction
Hello, fellow TF2-ers! I'm pretty sure most of you have noticed that the AI for the bots in TF2 are just down right terrible! But fear not, my friends! For we can improve their AI with the magic of the console commands! Yes, your fellow 'bot-mates' might actually be of some use (for once) after we mess around some.
What you will need:
Before you are able to enhance the brains of these foolish bots, you will need to enable the developer console (console for short).

Go to Options, then Keyboard, then Advanced Options, then Enable developers console, then click OK

What to do with these facinating skills you've just learned:
Now for the moment you've all been waiting for: Making the Bot AI smarter!

Step 1: Load up a compatible map

You can do this by clicking on 'Create Server' (That's the cross icon) and then choosing your desired map from the dropdown list

Here is a list of Bot compatible maps:

Control point:
  • Dustbowl
  • Gorge

King of the hill:
  • Viaduct
  • Badlands
  • Nucleus
  • Lakeside
  • Sawmill

Payload:
  • Upward
  • Thunder Mountain
  • Hoodoo
  • Gold Rush
  • Badwater Basin
  • Barnblitz

Step 2: Console

Open up your console with the ~ button (It's located below the 'esc' key) and type in mp_teamplay 1. This command will make the Bot AI smarter.

Step 3: Add Bots

If there isn't bot's added already, go to console and type in tf_bot_add

If you want to be specific in making the bot, here is a copy paste from Tf2's Offical Wiki on Bot commands:

Syntax
tf_bot_add [<count>] [<class>] [<team>] [<difficulty>] [<name>]
Parameters

<count>
Specifies the number of bots to spawn. If omitted, one bot is spawned.
Trying to create bots beyond maxplayers will fail with an error message in the console.

<class>
The classname of the class can be Demoman, Engineer, HeavyWeapons, Medic, Pyro, Scout, Soldier, Sniper, or Spy

<team>
Specifies the team name to assign the bot, where team can be red or blue.

<difficulty>
Sets the difficulty level for the bot, where difficulty can be easy, normal, hard, or expert.

<name>
Sets the connecting bot's name.

Example
tf_bot_add 3 heavyweapons red easy (will add three Heavies to the RED team at the easy skill level.)

Here is a picture for an easier read

Here is the link to the Bot commands: https://wiki.teamfortress.com/wiki/Bots

There are some really useful one's like: tf_bot_keep_class_after_death 0/1 which makes bot's keep their class after death. You should enter it in console before adding bot's because they might kill each other before you have the chance to put that command in, thus their class won't be the same as the one from their previous life.

Also, if you look at the middle of the page, you'll find AI Bot behaivor and some intresting bugs. You might learn some new things about how bot's function.
What these extra-ordinary skills did:
Once you entered the command in console, you will notice small gameplay impacts, such as:

All classes: Doesn't focus on objective 100% Ex: Not stacking the cart/control point. Not more than x4 cap speed (Exception for Scout's for x5 cap speed)

Medic: Heal's all classes, but still pockets Soldiers, Pyros, Heavys, Demo-men, Scouts.
Doesn't pop immediatly after being shot, meaning Medic drops exsist now, even at expert difficulty.

Pyro: Uses Flamethrower instead of just airblasting.

Spy: Once backstabbing an enemy, if the other enemy's don't notice, he keeps backstabbing. If they DO notice him, if the enemy is close enough, he uses his knife. Once out of melee range, he uses his revolver.

Sniper: Doesn't become an MLG 360 wallhack master, even at expert difficulty.

There may be some differences in the behavior of Soldiers, Demomen and such, but we won't be focusing on it .




My prefrences when playing
Here are some of my prefrences when playing with bot's:

4v4

tf_bot_taunt_victim_chance 0; tf_bot_keep_class_after_death 1; mp_autoteambalance 0; tf_weapon_criticals 0; tf_damage_disablespread 1; mp_teamplay 1; mp_tournament 1;
tf_bot_add 1 scout BLU expert; tf_bot_add 1 RED expert;
tf_bot_add 1 demoman BLU expert; tf_bot_add 1 demoman RED expert;
tf_bot_add 1 soldier BLU expert; tf_bot_add 1 soldier RED expert;
tf_bot_add 1 medic BLU expert; tf_bot_add 1 medic RED expert;

Highlander

tf_bot_taunt_victim_chance 0; tf_bot_keep_class_after_death 1; mp_autoteambalance 0; mp_highlander 1; tf_weapon_criticals 0; tf_damage_disablespread 1; mp_teamplay 1; mp_tournament 1;
tf_bot_add 1 scout BLU expert; tf_bot_add 1 scout RED expert;
tf_bot_add 1 demoman BLU expert; tf_bot_add 1 demoman RED expert;
tf_bot_add 1 soldier BLU expert; tf_bot_add 1 soldier RED expert;
tf_bot_add 1 medic BLU expert; tf_bot_add 1 medic RED expert;
tf_bot_add 1 spy BLU expert; tf_bot_add 1 spy RED expert;
tf_bot_add 1 sniper BLU expert; tf_bot_add 1 sniper RED expert;
tf_bot_add 1 engineer BLU expert; tf_bot_add 1 engineer RED expert;
tf_bot_add 1 heavyweapons BLU expert; tf_bot_add 1 heavyweapons RED expert;
tf_bot_add 1 pyro BLU expert; tf_bot_add 1 pyro RED expert;
Dramatic Outro
Now, your fellow bot will actually feel less like a frilly wanka and more like an average pubber. (Which can help you in-game! Sweet!)

Enjoy your insane bot matches!

I would like to thank Marosaur for editing the guide into a more creative and colorful one and for being my guinea pig and testing out mp_teamplay 1 further and Hex for editing this page like the intellegent guy he is. They are both incredibly good friends, and I'm thankful for it.
20 Comments
Jason Jason 30 Jan, 2019 @ 8:23am 
hider
Type nav_generate into the console
i<3scones 26 Feb, 2017 @ 4:57am 
bots do work on other maps just type sv_cheats 1 and then nav_generate in to the console for bots koth is the best some of my favourites are product, railbridge and brazil(yes these are custom maps) . payload and A/D are pretty good. 5cp less so and ctf is terrible rd,sd and par won't work at all. for custom game modes ADCTF is broken but Tug o war works. also this article and comments section are filled with accident lies please go some where else. this is coming from some one who has spent hundreds of hours with bots and understands their shity unreliable magic
Juggernaut 18 Jul, 2016 @ 8:34pm 
dosent work on other maps

DreadedGhoul575 4 Jun, 2016 @ 9:49am 
how does mp_teamplay 1 make the bots smart?
Breebls 4 Jun, 2016 @ 6:12am 
You can actually get bots to play other maps. Before spawning bots, type nav_generate, it makes bots know what to do outside of those given maps. It may not work for all maps, but it works for most of 'em.
DreadedGhoul575 2 Jun, 2016 @ 1:41am 
@Rafflor tf_bot_kick all (all bots kicked), tf_bot_kill all (kill all bots), tf_bot_kick red (kicks all bots on the red team) etc.
Deaxon 1 Jun, 2016 @ 8:34pm 
How do you remove the bots?
Elsen 26 Apr, 2016 @ 2:12pm 
Alright, thank you.
Karamel  [author] 25 Apr, 2016 @ 7:34pm 
Karamel [author] Just now Delete
I'm not quite sure, but I remember someone doing so. The bots uses the weapon like a default, so if let's say a Demoman had a Charge 'n Targe and a sword/ grenade launcher, he wouldn't use the shield.
Elsen 25 Apr, 2016 @ 3:15pm 
Can I make bots use certain weapons?