[Tutorial] Maptesting using bots

Discussion in 'Tutorials & Resources' started by martijntje, Sep 18, 2009.

  1. martijntje

    martijntje L8: Fancy Shmancy Member

    Messages:
    539
    Positive Ratings:
    168
    Map testing with bots

    Bots are computer controlled players that will play your map for you. The advantage of this is that you dont have to find real players (or have to wait till gameday), the disadvantages is that they dont simulate real people as well as some of us had wanted too.

    Now to not dissapoint you afterwards, I will list some of the disadvantages of using bots
    -They are stupid; walking straight into wall and stuff
    -They cant do everything you would want them to do (Certain gametypes are very hard for them)
    -You have to manually tell the bots where the can walk, so called waypointing. (takes some time, but aint that hard)
    -you need sv_cheats set to 1. (shouldnt be an issue)


    Now as some of you brilliant minds probably already have figured out, Team Fortress 2 doesn't come with bots (This thread should not be used to comment wheter or not tf2 should have bots), so we will have to install them ourselfes.

    We are going to use RCbot2, wich is the only bot I found that worked with tf2. (If you know any others, please reply)

    to download it, go to this site
    http://rcbot.bots-united.com/
    I wont explain you how to install it, a readme is included

    now a slight recommendation, add the following line to your autoexec.cfg (located in STEAMNAME/team fortress 2\tf\cfg ) If you dont have such a file, create one. You can edit it with notepad, or any text editor you like. (not stuff like ms word!)
    add the following lines

    Code:
    plugin_load ../bin/HPB_Bot2
    alias "bots" "sv_cheats 1;wait 30;rcbot addbot 1 3;wait 30;rcbot addbot 1 2;wait 30;rcbot addbot 2 3;wait 30;rcbot addbot 2 2;wait 30;rcbot addbot 3 3;wait 30;rcbot addbot 3 2;wait 30;rcbot addbot 4 3;wait 30;rcbot addbot 4 2;wait 30;rcbot addbot 5 3;wait 30;rcbot addbot 5 2;wait 30;rcbot addbot 6 3;wait 30;rcbot addbot 6 2;wait 30;rcbot addbot 7 3;wait 30;rcbot addbot 7 2;wait 30;rcbot addbot 8 3;wait 30;rcbot addbot 8 2;wait 30;rcbot addbot 9 3;wait 30;rcbot addbot 9 2"
    the first pugin_load blablaba allows you to use the bots, if you dont do this you will have to type this at the menu (in the console of course). Please note that if you use this command more than once, rcbot will give you error messages when you try to add bots later on. The second command, will populated the server with bots, when you type the command "bots", (without qoutes) 9 players per team, 1 of each class per team.

    You can now already have some fun with these bots, you can create a listenserver and play a little match with your bots on some maps. (a big part of the official maps that is.) However, when you let them play on you own map, they just stand still.

    This is because the bots use the waypoint system. The maps the bot can play on are filled with waypoints, these point tell the bot they can stand there. Some of these waypoints tell them there is something special there (a healtkit for instance). Bot will spend most of their time traveling from waypoint to waypoint. They usually only go of this path to fight enemies, after wich they return to this path. To make them do special stuff like capturing a point, you have to do extra stuff (I dont yet know how to, so it wont be covered yet)

    to do waypoint, follow this thread, I wont tell you because this guy already does a decent job (his tutorial isnt finished yet, but it definately helps)
    http://rcbot.bots-united.com/forums/index.php?showtopic=1155

    A very useful tip, use the command "rcbot waypoint save" when you are done (use it often so you dont forget). If you dont do this you have to do everything all over again.

    now you can finally start testing your map.
    create a listen server, from the main menu click on "create server".
    go into spectate mode (make sure you have spectator cams), open up a console and type "bots", and the server will be populated and played.
    You might have to join yourself to make sure a certain team makes progress.

    A problem is that if you change the name of the map (from cp_test_a3 to cp_test_a4) the waypoints wont work anymore (renaming the waypoint files doesnt work), recompiling under the same name does work however, unless you made a big layout change, then they will walk into stuff etc.

    Just remember, while useful, they are not a very good testplayer replacement, real testplayers are still needed.
     
    • Thanks Thanks x 3
  2. StickZer0

    aa StickZer0 💙💙💃💙💙

    Messages:
    664
    Positive Ratings:
    667
    I waypoint my maps and try them out sometimes, it's very good fun but you honestly don't get the same level of testing as if you had real people.

    Arena/koth maps are best for bots
     
  3. The Political Gamer

    aa The Political Gamer

    Messages:
    4,468
    Positive Ratings:
    1,684
    I give this a shot and see what happens.
     
  4. Freyja

    aa Freyja ¯\_(ツ)_/¯

    Messages:
    2,869
    Positive Ratings:
    4,896
    I use this in my main menu background. Fun to see bots fight on Sawmill (IMO the prettyest map)
     
  5. martijntje

    martijntje L8: Fancy Shmancy Member

    Messages:
    539
    Positive Ratings:
    168
    no you dont, I and think I already mentioned it in my post. It allows for more frequent tests than with real people. A lot of people only get their maps tested on gameday (me for instance), but with the help of bots, they could test it everyday

    Very true, although it is possible to let them play other gametypes, they are pretty bad at them
     
  6. Trotim

    aa Trotim

    Messages:
    1,180
    Positive Ratings:
    995
    It's true though, it's just fun to place waypoints in your map and let bots run about. Reminds me of the old UT99 days... *sniff*

    What this does do is make you REALLY realize where players will walk most frequently, in what direction they will look and where some natural chokepoints are (or at least could be). You can also use it to test if certain sniper and sentry spots work.