1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. If you have a problem and need help, create a new thread with a title that briefly describes the problem.
    Do not use titles like 'Help!' or 'I have a problem!'
    Dismiss Notice
  3. Hey Guest, is it this your first time on the forums?

    Visit the Beginner's Box

    Introduce yourself, read some of the ins and outs of the community, access to useful links and information.

    Dismiss Notice

How to add Bots to a Server

Discussion in 'Server Help' started by Creille, May 10, 2012.

  1. Creille

    Creille Base Burner

    Is there anyway can mod a script or so to have some BOTS in my server?
    Im guessing it'll involve a bit of copying and pasting the files?

    I'd like to have like 1 - 2 on each team or so Someone PLZ help!!! :)

    NOTE: Kouji or anyother guard feel free to move this to the server thread i just wasnt sure which category to put it in :P
  2. Bookmark

    Bookmark Ballista Bolt Thrower

    Here is my how-to (with analysis) on summoning bots using rcon:

    /rcon addBotX( 0, 0, `Name` );

    The syntax (or whatever):
    addBotX( [team], [class], `[name]` );

    The team is either 0 or 1 for blue or red; respectively.
    Class can be 0, 1, or 2 for builder,knight, or archer; respectively.

    Classes that are greater than 2 loop around; 3 is builder, 4 is knight, etc.. (I wouldn't do this though because it might cause problems)
    It's recommended to make only archer bots because they are the least derpy and are good to practice with. Builders and knights are extremely crippled because they don't build or slash. Rarely or if at all.

    Names can have spaces like 'George Bush' and can be as long as you'd like. However, it's recommended that you don't put spaces because you can't kick them by name; you'll have to kick by their ID.

    That's all. Enjoy the bot summoning. And remember: they take up a slot on the server.

    If done properly it should look like the following:
    /rcon addBotX( 0, 2, `Jesus` );

    This will spawn a bot named Jesus on blue team [0] that is an archer [2]. That semicolon is required at the end.
    hierbo, RikTelner, WarrFork and 10 others like this.
  3. BlueLuigi

    BlueLuigi :^) Forum Moderator Donator Tester

    Can this get stickied?

    It's legitimately one of those things that has like no comments and was found out by people asking the devs, the fewer that have to ask the better, and Bookmark put it as good as it will get.
    kl4060, Auri, Drafiks and 4 others like this.
  4. sj67

    sj67 Greg hunter

    I second this for further threads having to do with the same question, as in making it easier for people who don't know what a search button is.
  5. Kouji

    Kouji Cold, Uncaring, Sadistic, Evil and Cruel Meanie Administrator Global Moderator Forum Moderator Tester
    1. MOLEing Over Large Estates - [MOLE]
    2. REKINS OF SEAS: Super Crew of Ultimate Havoking 2: Return of King of KAG: Chapter 420blazeit - REKIN

    kl4060, BlueLuigi and sj67 like this.
  6. Creille

    Creille Base Burner

    THX alot man really helped :)

    This was the best way i have found for teaching people so i thoguht i'd post it here:

    Go into the server
    push the "HOME" key
    then type /rcon whatevertherconisputithere
    then if that gets passed
    type this
    /rcon addBotX(0,3,`nameHere`);

    the 0 = team
    -1 is red
    -0 is blue

    the 3 = class
    -2 Archer
    -1 Knight
    -0 Builder

    the `` = name
    Type whatever you want here avoid using spaces though :)

    also remember this at the end ;
    and remember the brackets and Capitals
    sj67 likes this.
  7. Rayne

    Rayne ༼ つ ◕_◕ ༽つ Administrator Global Moderator Forum Moderator Tester

    I think you got the classes wrong Creille, read this^ part again.
    Boxpipe likes this.
  8. trelawney

    trelawney KAG Guard Tester

    I'll be moving this to Server Help and leaving a permanent redirect in Modding. For the sake of completion, here's a way of adding bots in a dedicated server. Configuration courtesy of Rayne, edited to reflect a generic CTF server and to reduce the number of bots added from 28 (!) to 3. This should go in Base/Scripts/dedicated_autostart.gm
    // autostart on dedicated server launch
    newWorld( "" );
            LoadMapCycle( "Scripts/mapcycle.cfg" );
            LoadMap( " " );
            addBotX( 1, 2, "Kay" );
            addBotX( 1, 0, "Lancelot" );
            addBotX( 1, 2, "Gawain" );
    print(`Config loaded from dedicated_autostart.gm`);
    You can obviously modify the duration of 'wait prior to spawning' (sleep, in seconds), and the name of each bot. Class and Team rules you saw in previous examples still hold.
    FG, Rayne and BlueLuigi like this.
  9. Creille

    Creille Base Burner

    oh right i think thats cause i was doing it in RTDM where theres no builders :P so it must have restarted the cycle :) *edited now :)
  10. Ghozt

    Ghozt Haxor

    I have been trying to do this, but it won't work.
    I want to add bots to swordfight, so I can have hectic matches, is this possible?
  11. BlueLuigi

    BlueLuigi :^) Forum Moderator Donator Tester

    Yes, just add more bots to it. Go find the line to add bots in the swordfight.gm (I believe that's the one) and copy it like crazy.
    Ghozt likes this.
  12. MCrypa

    MCrypa Bison Rider

    • Spam
    Even though it's solved: You could just had used SirSalamis "Coop" files :3

    Huh? Spam?

    ITROLLEDU Ballista Bolt Thrower

    Sounds like complicated file mangling :eek:
    trelawney likes this.
  14. Creille

    Creille Base Burner

    i found the best file confg that automatically puts the BOTs in :) go into
    then you can make the BOTs in any gamemode by changing the file names, you can also change the BOTs names and when they spawn.
    Just thought i'd mention this it is quite handy when your making Modded gamemodes and such :)

    ITROLLEDU Ballista Bolt Thrower

    To be correct the "Bots" Will have to be at least a bit smart...Soo its an idea to just copy&paste the bots from the single player mode...
  16. -Tj-

    -Tj- Sicarii Donator
    1. The Ivory Tower of Grammar-Nazis

    Im guessing that is would be the same thing if you just want to add bots to like zombies or something......

    And this might not be the right thread but.......How would you be able to play as red team in zombies......Ive been trying to figure it out for a while now, and i really need help..
    Creille likes this.
  17. PainGiver

    PainGiver Arsonist

    What is the function to remove bots?
  18. Ghozt

    Ghozt Haxor


    Na, but depends. If you have added the bots for just that game you could maybe just next map?
  19. PainGiver

    PainGiver Arsonist

    I am interested in learning how to exactly kick or remove bots from zombie fortress, I used to just black list them but that doesn't seem to work anymore.
  20. eric999

    eric999 Ballista Bolt Thrower

    The code does not work for me.
    it says - 'Script Error: Runtime'
    Did I do something wrong? I checked everything and it was all correct, it is in dedicated_autostart.gm
    Please help!