home *** CD-ROM | disk | FTP | other *** search
/ PC Gamer 3.2 / 1997-05_Disc_3.2.iso / QUAKECTF / CTFBOT12.TXT < prev    next >
Text File  |  1997-02-03  |  61KB  |  1,269 lines

  1. Title    : CTF Bot
  2. Filename : ctfbot12.zip
  3. Version  : 1.2
  4. Date     : 3 Feb 97
  5. Author   : Drew 'BZ' Davidson
  6. Email    : drew@interpath.com (Please see Bug Reporting section 
  7.            below before emailing me.)
  8. Homepage : http://www.interpath.com/~davidson/ctfbot.htm
  9.  
  10. Type of Mod
  11. ===========
  12. Quake C  : yes
  13. Sound    : no
  14. MDL      : yes (extra skins)
  15.  
  16. Format of QuakeC
  17. ================
  18. unified diff  : no
  19. context diff  : no
  20. .qc files     : yes
  21. progs.dat     : yes (in pak1.pak file)
  22. pak0.pak file : no
  23. pak1.pak file : yes (progs.dat, progs/player.mdl)
  24.  
  25. Description of the Modification
  26. ===============================
  27. This is CTF Bot (aka Capture the Flag Bot), a bot that plays ThreeWave  
  28. Capture the Flag 3.5.  The unmodified ThreeWave CTF is available from: 
  29. http://www.planetquake.com/quakex/threewave/
  30.  
  31. Before You Install the Modification
  32. ===================================
  33. You should have a basic knowledge of Quake things like how to edit and
  34. use config files, how to use the Quake console, how to load a specific
  35. map file, what autoexec.cfg files do, etc, before you try to install 
  36. and use CTF Bot.  It would also be very good if you had experience 
  37. with installing and using Quake C patches.  If you don't know this
  38. stuff, please go to the CTF Bot web page and check the "Links" section
  39. for web pages with general Quake info.
  40.  
  41. If you've never played CTF before then you definitely should go to
  42. ThreeWave at http://www.planetquake.com/quakex/threewave/ and read about
  43. it because I assume you know what you are doing with regard to CTF, i.e.
  44. you know how to pick up the flag, what you have to do to capture the flag,
  45. how to use the hook, how to drop backpacks with ammo, what the runes are,
  46. etc.
  47.  
  48. *IMPORTANT NOTE*:  If you don't have the ThreeWave CTF client mod, you
  49. won't be able to play Capture the Flag with the bots, so go download that
  50. now before you install the bots.  You can download ThreeWave CTF stuff 
  51. from http://www.planetquake.com/quakex/threewave/
  52.  
  53. It would also be a good idea to download the ThreeWave server mod.  The
  54. server mod contains documenation about the different teamplay options that
  55. are also available in CTF Bot.  However, the server mod is not required 
  56. for play.
  57.  
  58. [SIDE NOTE: Technically, you don't *absolutely* need the ThreeWave CTF
  59. client or server mod to use CTF Bot.  But you won't have any CTF maps to
  60. play on. You could use the non-custom CTF models (i.e. the flags look like
  61. keys) and then create your own CTF map with the dynamic map creation
  62. features of CTF Bot, but that would be very silly and you would miss out
  63. on the fantastic maps, models and graphics that greatly enhance the CTF
  64. experience.  Also the bots will be much dumber because they only have
  65. waypoints for maps in the ThreeWave client mod.  But just for the record
  66. you can set the teamplay variable in server.cfg so that CTF Bot does not
  67. require the ThreeWave CTF client side mod.]
  68.     
  69. Quake may crash if it is given the default 8 Megs of memory.  You should
  70. probably use the "-winmem 16" parameter to give Quake 16 megs of memory
  71. when using this bot. Also, this bot may play too slow on slower machines.
  72. If it plays too slowly, reduce the number of bots.  I would like to hear
  73. if you have a slow machine and can get acceptable game play.
  74.  
  75. How to Install the Modification
  76. ===============================
  77. First please read the "Before You Install the Modification" section
  78. above! The following installation procedure assumes you will be playing
  79. on a single machine that is not networked (i.e that you will be playing
  80. by yourself on the server).  If you are playing with a network, you will
  81. have to follow the installation for *all* machines, not just the server.
  82. The pak1.pak file is required (and the ctfbot.cfg file is useful) for all
  83. clients also.  See "CTF Bot on Network Servers" below for more
  84. information.
  85.  
  86. 1) Unzip the CTF Bot zip into a *NEW* directory called "ctfbot" 
  87.    inside your Quake directory.  This will install the following:
  88.  
  89.     - ctfbot            [DIR /quake/ctfbot/ that you created ]
  90.         ctfbot12.txt    [ this file ]
  91.         whatsnew.txt    [ file describing new features in this version ]
  92.         impulses.txt    [ numerical list of impulse commands ]
  93.         ctfbot.cfg      [ CTF Bot default key config ]
  94.         server.cfg      [ CTF Bot server config ]
  95.         autoexec.cfg    [ execs ctfbot.cfg and server.cfg ]
  96.         makebots.cfg    [ exec this to make some bots ]
  97.         pak1.pak        [ brains of the bot & red/blue skins ]
  98.         file_id.diz     [ archive description ]
  99.         src/            [DIR source code ]
  100.         ents/           [DIR entities for converting maps to CTF ]
  101.  
  102. 2) Copy the pak0.pak from the ThreeWave CTF client mod into the
  103.    ctfbot directory.  You can get the ThreeWave CTF client mod from
  104.    http://www.planetquake.com/quakex/threewave/ 
  105.    DO *NOT* OVERWRITE YOUR EXISTING pak0.pak OR pak1.pak FILES IN 
  106.    THE id1 DIRECTORY!
  107.  
  108. 3) OPTIONAL: Install More CTF Maps
  109.  
  110.    If you want to play on more maps that CTF Bot has waypoints for,
  111.    create a directory in the ctfbot directory called "maps".  Copy the 
  112.    bsp's (e.g. idctf1.bsp) into your new /ctfbot/maps/ directory.
  113.  
  114.    If you want to play CTF Bot on the id maps that have been converted to
  115.    CTF, follow the instructions in "Converting Maps to CTF" below to
  116.    convert your id bsp's into CTF bsp's.  You will also need to edit the
  117.    server.cfg file to change the percentage of custom CTF/id maps when
  118.    playing if you want the id maps to show up when the level changes.
  119.    See the ThreeWave server mod docs for more info on converting bsp's.
  120.    
  121.    Check the CTF Bot web page for the latest on maps CTF Bot has
  122.    waypoints for.
  123.  
  124. 4) Your final CTF Bot directory structure should look like this
  125.    (excluding the files/directories not used for play):
  126.  
  127.    - quake                  [DIR /quake/ ]
  128.         quake.exe           [ Quake application ]
  129.         q95.bat             [ Q95 batch file ]
  130.         - ctfbot            [DIR /quake/ctfbot/ ]
  131.             ctfbot.cfg      [ CTF Bot default key config ]
  132.             server.cfg      [ CTF Bot server config ]
  133.             autoexec.cfg    [ execs ctfbot.cfg and server.cfg ]
  134.             makebots.cfg    [ F7 execs this file to make some bots ]
  135.             pak0.pak        [ copied from ThreeWave CTF client mod ]
  136.             pak1.pak        [ from CTF Bot zip file ]
  137.             - maps          [DIR /quake/ctfbot/maps/ ]
  138.                 idctf1.bsp  [ if you got idctf1 CTF map ]
  139.                 koc1.bsp    [ if you got koc1 CTF map ]
  140.                 e?m?.bsp    [ if you converted id bsp's to CTF ]
  141.  
  142. 5) Run Quake (or Q95.BAT if you want to play networked games) with 
  143.    the following command line parameters:
  144.  
  145.     -game ctfbot   ==> to use CTF Bot resources (i.e. pak0.pak, pak1.pak)
  146.     -listen        ==> start a listen (i.e. deathmatch) server
  147.     -winmem 16     ==> give Quake 16 megs of ram
  148.     -zone 512      ==> give Quake more ram for config files (optional)
  149.  
  150. 6) If you have trouble, consult the "Troubleshooting" section below.
  151.  
  152. Converting Maps to CTF
  153. ======================
  154. This procedure will allow you to convert your id bsp's into CTF
  155. bsp's so you can play CTF on id maps.  If you already have converted 
  156. your id bsp's to CTF with this procedure, you can just copy those over, 
  157. you don't have to convert them again.
  158.  
  159. 1) Unpack the pak0.pak and pak1.pak files from the quake/id1 
  160.    directory to get the separate bsp's (e1m1.bsp, etc).  You can 
  161.    get a unpaking utility at:  http://www.cdrom.com/pub/quake/
  162.  
  163. 2) Copy the *.bsp files you extracted in step (1) to your /ctfbot/ents/ 
  164.    directory.  You only need to copy the .bsp files that have 
  165.    corresponding .ent files.
  166.  
  167. 3) Get a copy of QBSP, make sure that it is in your execution path, then
  168.    run dobsp.bat.  This will insert the *.ent files into the *.bsp files
  169.    (that is, it will insert the CTF entities into the bsp files so that
  170.    the flags appear in the maps).  It shouldn't take more than a minute
  171.    or two to convert all the bsp's.
  172.    
  173. 4) Move the converted bsp's to your /ctfbot/maps/ directory.
  174.    
  175. 5) For more detailed instructions on converting maps to CTF, read
  176.    the ThreeWave server mod documentation.  The ThreeWave server
  177.    mod is available at: 
  178.    http://www.planetquake.com/quakex/threewave/files.html
  179.  
  180. Troubleshooting
  181. ===============
  182. If the flags are not visible, one of the following two things has
  183. happened: either (1) you are in single player mode, or (2) the file
  184. server.cfg is not being exec'ed when you start Quake.  You can solve (1)
  185. by adding the "-listen" param to the Quake command line.  You can solve
  186. (2) by making sure that server.cfg is being exec'ed when you start Quake
  187. (e.g. make sure that autoexec.cfg in the ctfbot directory has the line
  188. "exec server.cfg"). The server.cfg file sets various server variables
  189. that are *REQUIRED* to run CTF correctly.  Also make sure that you
  190. didn't exec another file that overrode the settings.
  191.  
  192. If the bots are all one color (i.e. you can't tell the difference between
  193. the teams), somehow the progs/player.mdl in the CTF Bot pak1.pak is not
  194. being used by Quake.  If you are running a server on a different machine,
  195. see "CTF Bot on Network Servers" below for how to fix this.
  196.  
  197. If the bots are *still* all one color, you probably unpaked your pak
  198. files. Quake is probably using the player.mdl from the pak0.pak instead
  199. of the one from the pak1.pak.  If you want to unpak any pak files (e.g.
  200. to use a custom progs.dat) then you should unpak the pak0.pak also, so
  201. that there are *no* pak files in the ctfbot directory. Sometimes it's
  202. tricky to know what files Quake is going to use.  Having no pak files
  203. makes it much easier to control what Quake does.  You should use
  204. everything from the pak0.pak, *EXCEPT* the player.mdl, which should come
  205. from the pak1.pak file (the player.mdl from the pak1.pak has extra skins
  206. required to see the bots as different colors).  This is probably the
  207. case for clients also; don't unpak any of the pak files unless you unpak
  208. all of them.  (Of course, on the client side there's no reason to unpak
  209. the files because clients don't use progs.dat files at all.)  After
  210. you unpack everything, move the pak files to another directory so Quake
  211. won't see them.
  212.  
  213. If you are playing on a map that you thought CTF Bot had waypoints for,
  214. but the bots are really dumb and you can't see the waypoints when
  215. you turn on bot debug, perhaps you renamed the bsp.  CTF Bot knows
  216. what map it is playing on by the name of the bsp file, and if you
  217. rename the bsp file, the waypoints will not work.
  218.  
  219. If you are playing by modem and are having trouble changing levels, 
  220. try using the "changelevel" command instead of the "map" command to 
  221. start a new level.  It works just like the map command (i.e. in the
  222. console type "changelevel ctf1").  Also remember that both sides need
  223. the pak0.pak and pak1.pak.
  224.  
  225. If you are getting a message that says something like "progs/star.mdl
  226. not found" then you either forgot to copy the ThreeWave pak0.pak file
  227. into the ctfbot directory, or you copied the wrong pak0.pak file (e.g.
  228. the one from the id1 directory) into the ctfbot directory, or you didn't
  229. include the "-game ctfbot" Quake command line parameter when you ran
  230. Quake. Please follow the installation instructions above.
  231.  
  232. If you find that IPX or TCP/IP is disabled in the Multiplayer menu, 
  233. try using Q95.BAT instead of Quake.exe.
  234.  
  235. If you are trying to use CTF Bot with QuakeWorld, give up.  CTF Bot
  236. currently doesn't work with QuakeWorld.  (See "CTF Bot with QuakeWorld"
  237. for more info.)
  238.  
  239. Customizing Controls and Settings
  240. =================================
  241. The file autoexec.cfg execs ctfbot.cfg and server.cfg. If you have a cfg
  242. file containing your Quake key bindings, you may want to exec it from
  243. the autoexec.cfg file in the ctfbot directory.  That is, add the line
  244. "exec blah.cfg" as the first line, where blah.cfg is the name of the
  245. config file containing your custom key bindings.  Or, if you want to
  246. override the default ctfbot key bindings, exec your config as the 
  247. last line.  However, be careful if your config file changes various
  248. teamplay options, or CTF may not work correctly.
  249.  
  250. The file ctfbot.cfg sets up some key bindings for you, so you can spawn
  251. bots quickly (hit F7).  Tweak this file to change the settings, or just
  252. use the impules listed below to spawn bots and start killing.
  253.     
  254. The file server.cfg sets up the various CTF server variables.  You can
  255. tweak this to your liking, for example if you want to start in a
  256. different map by default, or if you want to disable observer mode or
  257. change the teamplay options.  See the ThreeWave CTF server docs for more
  258. info on what teamplay options are available.  Also see "Server 
  259. Administration & Settings" below for useful bot-related server settings.
  260.  
  261. CTF Bot on Network Servers
  262. ==========================
  263. If you are running a CTF Bot server on a different machine than you
  264. are playing on (i.e. if you're not playing on the server), you need to
  265. have the CTF Bot pak1.pak on all of the *CLIENT* machines also.  The CTF
  266. Bot pak1.pak contains extra skins for the bots, and if it is not on a
  267. client's machine, that client will see all of the bots as the same color.
  268. (Also make sure all of the clients are using the "-game ctfbot" parameter
  269. so that Quake will actually see the pak1.pak.)  Of course, the clients
  270. also need the ThreeWave client side mod (unless you have tweaked
  271. the server variables to not require the custom client-side models).
  272.  
  273. HOWEVER, you can try a fix that may work.  If you set teamplay bit 
  274. 32768, CTF Bot will attempt to use the color maps of clients instead
  275. of using skins.  Due to an inherent Quake limitation, client-side 
  276. skins are required to have the bots show up as the correct colors 
  277. in all situations, but this may work most of the time.
  278.  
  279. Also keep in mind that you need to run Q95.BAT instead of Quake.exe
  280. to do most network stuff.  Consult the Quake documentation for more
  281. info on running networked servers.
  282.  
  283. If you are playing over a network, you may want to check out the
  284. "Server Administration & Settings" section below, because by default
  285. any player can execute any impulse (i.e. anybody can create a bot).  
  286.  
  287. CTF Bot has been primarily designed for play on a single machine
  288. or on a LAN.  It has not been extensively tested on public Internet
  289. servers, and it probably has many shortcomings in that area.  
  290.  
  291. Note that if you want to have your server automatically select only
  292. certain maps (for example only the maps with waypoints) you will need to
  293. edit the source code (the RandomLevel routine) to select only the maps 
  294. you want.  If you don't do this you will probably select levels 
  295. manually with the changelevel command or the admin change-level menu.
  296.  
  297. Impulse Commands
  298. ================
  299. See the file "impulses.txt" for a complete list of impulses
  300. in numerical order.
  301.  
  302. More default keys set in ctfbot.cfg:  F1-F4 sets skill 0-3
  303.  
  304. Help Impulses
  305. =============
  306. Impulse ##    Key   Description
  307. -----------   ---   -----------
  308. impulse 199 =   F1  =  help
  309.  
  310. Impulse 199 for help.  This lists all impulses & default keys,
  311. including the impulses that are default ThreeWave impulses.
  312.  
  313. Creating and Removing Bots
  314. ==========================
  315. Impulse ##    Key   Description
  316. -----------   ---   -----------
  317. impulse 100 =  F5 = creates a bot on your team
  318. impulse 101 =  F6 = creates a bot on the enemy team
  319. impulse 102 =  F7 = exec makebots.cfg (makes several bots)
  320. impulse 105 =     = creates a red bot (regardless of your team)
  321. impulse 106 =     = creates a blue bot (regardless of your team)
  322. impulse 107 =     = remove red bot (regardless of your team) [NEW!] 
  323. impulse 108 =     = remove blue bot (regardless of your team) [NEW!] 
  324.  
  325. Bot Debug
  326. =========
  327. impulse 103 =  F8 = bot debug mode (see what bot is thinking)
  328. impulse 104 =     = turn bot debug off
  329.  
  330. Maps [NEW!]
  331. ===========
  332. On some maps, bots use a waypoint scheme to navigate.  The bots are much
  333. smarter (and thus much more fun) on waypoint maps than others. The
  334. waypoints are compiled into the bot code.  You don't need special
  335. versions of the maps (bsp's) to use with CTF Bot (however, you *DO*
  336. need special versions of some of the bsp's to play CTF of course,
  337. for example the id maps).
  338.  
  339. Currently the maps with at least some waypoints include:
  340.  
  341.     ctf1 - ctf8
  342.     idctf1
  343.     koc1
  344.     e1m1
  345.     e1m2 
  346.     e1m3
  347.     e1m4
  348.     e1m5
  349.     e2m1
  350.     dm1 (new CTF version)
  351.     dm3
  352.     dm6
  353.     maniac1
  354.     maniac2
  355.     satyr1ac (CTF version of satyr1a)
  356.     mexx6c (CTF version of mexx6)
  357.     martim5c (CTF version of martim5)
  358.  
  359. See the section "Acknowledgements & Credits" below for complete
  360. information on who designed the above maps, and/or who converted
  361. them to CTF or added waypoints.
  362.  
  363. See "Waypoints" section below for technical info on adding waypoints
  364. to a map.
  365.  
  366. Playing Notes
  367. =============
  368. Even on waypoint maps, the bots have certain limitations.  They don't
  369. know they entire layout of maps.  So, the moral is: help your bots.  If
  370. you see a bot on your team with just a shotgun, then either lead it to a
  371. good weapon, or toss it your weapon.  Otherwise, don't be surprised with
  372. your bot gets slaugtered.  Use the "report in" order to find out what
  373. weapon your bots are using, and help them out if they can't seem to find
  374. anything good. Luckily on most of the default ctf good weapons are easily
  375. found.  On some of the id levels the good weapons are not on the main
  376. path between bases and so the bots are unlikely to find them.
  377.  
  378. Note that it is very helpful to have bots with you.  If you can't get
  379. past a high-skill enemy bot, bring along some buddies.  Let them grab
  380. the good weapons or toss them a rocket launcher and ammo and watch them
  381. kick ass while you get all the glory. :-)
  382.  
  383. Check the CTF Bot web page for links to more maps, including more maps
  384. with complete waypoint support.
  385.  
  386. On maps that do not contain waypoints, a lot of the time it is easy to
  387. capture their flag. If you go in their base, kill all the bots, and snag
  388. their flag, it may be easy to grab their flag again after that if they
  389. have all respawned away from their base, because they won't be able to
  390. find their way back. As a result, some non-waypoint maps work better than
  391. others with these bots. It can still be fun to play on non-waypoint maps,
  392. because the bots do use teamplay tactics.
  393.  
  394. Skill Levels
  395. ============
  396. The console variable "skill" is used as the skill of the next bot
  397. created. Type "skill #" in the console to change the skill, where # is a
  398. number from 0 to 3.  Skill levels don't have to be an integer (i.e. 1.5
  399. or 2.7 are legal). Skill has various effects on play.  Lower skill
  400. levels misjudge target's velocity and position when firing, have smaller
  401. field of view, are less likely to make evasive maneuvers, are less
  402. likely to jump effectively, are less likely to see enemies far away, are
  403. less likely to see enemies with Ring of Shadows, plus tons of other 
  404. things.
  405.  
  406. Bots with a skill of 2 or higher use the "visor dude" CTF skin.
  407.  
  408. Quick Spawning of Bots
  409. ======================
  410. Included is a file that spawns a series of bots to demonstrate how you
  411. can make a config file spawn various differently-skilled bots easily.
  412. By default you can hit F7 to spawn 4 differently-skilled enemy bots and
  413. 2 bots on your team. Edit makebots.cfg to suit your skill level and
  414. desired number of bots.
  415.  
  416. For some reason exec'ing this file from the console does not work.  You
  417. have to bind it to a key in the console like this:  bind F7 "exec
  418. makebots.cfg" and then hit that key.
  419.  
  420. If you get telefragged when you spawn the bots in this manner, it
  421. is likely that all the bots did not get created, because as soon
  422. as you get telefragged, you are dead and so impulse commands no
  423. longer work.  Start a new map and try again.
  424.  
  425. Bot Orders [NEW!] 
  426. =================
  427. Impulse ##    Key   Description
  428. -----------   ---   -----------
  429. impulse  80 =  f  = report status & weapon
  430. impulse  81 =  a  = order more bots on your team to attack
  431. impulse  82 =  d  = order more bots on your team to defend
  432. impulse  83 =  e  = order closest bot to escort you
  433. impulse  84 =  c  = order closest bot to camp at your location
  434. impulse  85 =  x  = order closest bot to drop items for you
  435. impulse  86 =  z  = team status
  436. impulse  87 =  s  = order more bots on your team to roam
  437.  
  438. When you give an order, the status of your team is printed so you
  439. can see how many bots are doing what.
  440.  
  441. Bots will generally follow your orders, but will sometimes go 
  442. AWOL and decide what to do on their own.  
  443.  
  444. When you give an order to attack, defend, or roam, you have no
  445. control over what bot will actually start attacking/defending/roaming.
  446. The bot will be taken out of the appropriate "pool" of other bots,
  447. for example, when you order more bots to attack, first they are taken
  448. out of the roaming pool, then if there are no roamers, they are taken
  449. out of the defender pool, then the camping pool, then the escort pool.
  450. If you keep pressing "more bots attack" eventually they will *all*
  451. attack.  However, you will be overriding orders given to bots to
  452. camp and escort (orders which were possibly given to the bots by
  453. other humans on your team).  So use teamwork with other humans on
  454. your team when giving bots orders.
  455.  
  456. "Attack" means go toward the enemy base.  
  457.  
  458. "Defend" means go toward your base.
  459.  
  460. "Escort" means follow you around. Bots will say things like "let's
  461. attack" while they are following you, so you know that you have their
  462. attention. They will sometimes get distracted by items though.
  463. Sometimes the bot wants something but can't get it, but if you grab it
  464. the bot will of course not want it anymore.  If you are far above or
  465. below them, but they are still following you, they will try to jump
  466. down or hook their way up, so you can get them to follow you most
  467. places. Sometimes you have to just be patient while the dumb bot
  468. figures out how to get where you are, and sometimes you are just out of
  469. luck.  Sometimes it helps to try to get your buddy to try a different
  470. route; e.g. get it to hook its way up somewhere easier and then lead it
  471. to where you want it to be once it gets up there.
  472.  
  473. Note that you do *NOT* need to request escort when you have the 
  474. enemy flag.  When you have the enemy flag, bots will *always* try to
  475. escort you.  
  476.  
  477. "Camp" means stay at the location you specify.  Bots will not
  478. just stand still, but will jump and hook around, and still pick up
  479. nearby stuff.  Bots may get stuck behind something and not be
  480. able to get back to the camping location you specified.  If they
  481. get lost for more than 30 seconds, they stop camping and say so.
  482.  
  483. Camping and escorting work for 2 minutes and then the bots go
  484. about their normal business.  
  485.  
  486. "Roam" means just wander around and pick up stuff and kill.  Bots
  487. currently don't explore as well as they attack and defend.  They
  488. don't know where to go exactly and can tend to stay in one area,
  489. but may be drawn out of that area when they try to find good
  490. stuff or see an enemy, so there's no guarantee that bots will
  491. stay still.  
  492.  
  493. Bots with the flag are not affected by orders to attack, defend, or
  494. roam.  They will camp and escort however.
  495.  
  496. The bots are not smart enough to know whether or not the flag is in the
  497. base, and will happily defend (or attack) an empty base if you order 
  498. them to.  This can be helpful if you've got the enemy flag and the
  499. enemy has your flag... order your bots to attack and hope they can
  500. get your flag back.
  501.  
  502. The bots have higher priorities than your orders, like fighting with
  503. enemies.  You may issue your orders and find that the bots are too 
  504. busy trying to kill to follow your orders.  However, the bots 
  505. remembered that you ordered them and will start attacking or defending 
  506. when they have finished killing the enemy, or finished getting
  507. the items they are interested in.
  508.  
  509. "Attack" and "Defend" work only on maps with waypoints.  
  510. The other orders (including "Camp") work on all maps.  
  511.  
  512. When you order a bot to drop stuff, a bot nearby you may drop something
  513. for you.  At most one thing will be dropped when you make this request,
  514. regardless of how many bots are nearby and regardless of how much good
  515. stuff they may have.  Bots will *NOT* drop anything that you already
  516. have.  This means that if you have a rune, bots won't drop a rune for
  517. you.  If you have a rocket launcher, they won't drop a rocket launcher.
  518. So if a bot has a rune that you want, you'll have to drop your rune first
  519. before asking the bot for its rune. When you ask bots to drop stuff, they
  520. will try to give you a rune first. Note that when bots drop runes, they
  521. pop out of the bot just like when you kill a someone with a rune.  This
  522. means that the rune may fall into lava or you might not be able to find
  523. it.  Those are the breaks.  If no nearby bot has a rune, they will try to
  524. drop a backpack containing a good weapon and some ammo for that weapon.
  525. Weapon priorities are: lightning gun, then rocket launcher, then grenade
  526. launcher, then super nailgun. When a bot drops a rune or backpack with a
  527. weapon, all bots on your team will ignore the item for 10 seconds, and
  528. then if its not picked up bots will try to get it.  However, other bots
  529. may pick up the item accidentally, so this may be tricky in a crowd of
  530. bots.
  531.  
  532. Currently bots won't drop just ammo, they will only drop runes and 
  533. weapon/ammo backpacks.  Also, if the teamplay flags are set so that
  534. rune and/or backpack dropping is not allowed, then this of course
  535. will work differently.
  536.  
  537. Detailed Scores
  538. ===============
  539. Impulse ##    Key   Description
  540. -----------   ---   -----------
  541. Impulse 120 =  i  = prints detailed scores for you.
  542. Impulse 121 =  u  = prints detailed scores for everyone.
  543. Impulse 122 = TAB = print frag list
  544.  
  545. Detailed scores includes number of frags (i.e. actual score), and
  546. also number of kills, deaths, suicides, captures, pickups, assists,
  547. recoveries, and bonuses.  Bonuses are things like fragging the
  548. enemy flag carrier, or fragging the person hurting your flag carrier.
  549. Recoveries are returning your flag to base.  Pickups are grabbing
  550. the enemy flag.  Assists are things like returning your flag to
  551. base right before your team captures.  For more info on CTF
  552. scoring, see the ThreeWave documentation.
  553.  
  554. Increase/Decrease Bot Awareness/CPU Usage [NEW!] 
  555. ================================================
  556. impulse  75 =     = decrease bot cpu usage/bot awareness
  557. impulse  76 =     = increase bot cpu usage/bot awareness
  558.  
  559. Impulse 75/76 decreases/increases bot cpu usage.  On my machine this
  560. doesn't have much noticable effect, but I left it in there in case it may
  561. help someone.  Decreasing/increasing CPU usage makes the bot awareness
  562. distances smaller/larger.  So when you reduce the CPU usage, you are
  563. making the bots nearsighted.  They don't look as far for items and
  564. enemies. Conversely,  when you increase CPU usage you are making the bots
  565. see farther.  Since the bots have been "tuned" for the default
  566. parameters, reducing or increasing bot awareness may have undesirable
  567. effects, like making the bots no longer use waypoints or the grappling
  568. hook as effectively. If this feature lets you run more bots on your
  569. machine, I'd like to hear about it.
  570.  
  571. Increase/Decrease Bot Ping [NEW!] 
  572. =================================
  573. impulse  77 =  <  = decrease bot ping
  574. impulse  78 =  >  = increase bot ping
  575.  
  576. Impulse 77/78 decreases/increases the crudely simulated bot ping.  If you
  577. find that the bots on a network server are slaugtering all of the human
  578. players, you may want to increase the bot ping.  Increasing bot ping
  579. increases their reaction time when they see enemies.  That is, they will
  580. not start firing at an enemy for at least N/1000 seconds after it sees
  581. the enemy, where N is the bot ping.  Bot ping has no other effect than
  582. reaction time.  Note that bot skill also affects reaction time, so low
  583. skill bots will be even slower at reacting to enemies.
  584.  
  585. The default bot ping is 0.  
  586.  
  587. Other Impulses [NEW!] 
  588. =====================
  589. Impulse ##    Key   Description
  590. -----------   ---   -----------
  591. impulse  40 =  p  = drop current rune
  592. impulse  41 =     = rune status
  593. impulse  70 =     = toggle normal/bot names
  594. impulse  71 =     = toggle bot use of waypoints [NEW!] 
  595. impulse  90 = F11 = toss out your weapon in backpack with ammo [NEW!] 
  596. impulse  97 =     = toggle no damage mode [NEW!] 
  597. impulse  98 =     = enter observer mode [NEW!] 
  598. impulse 130 =  o  = toggle no target mode
  599. impulse 131 =     = toggle always escort mode
  600.  
  601. Impulse 40 (default key p) drops the rune you are carrying so you 
  602. can pick up another.  Note that it pops out of you just like when
  603. you kill a player with a rune, so be careful if you are dropping
  604. it for a teammate -- it may pop out and fall into lava.
  605.  
  606. Impulse 41 prints what rune you have.
  607.  
  608. Impulse 70 toggles between "normal" names (e.g. "Outlaw") and bot
  609. names (e.g. "RedBot1").  There are 100 different normal names that
  610. the bots use.  Yes, some of the bots are girls.  Deal with it. :-)  
  611.  
  612. Impulse 71 toggles bot use of waypoints.  If waypoints are disabled,
  613. then bots will be much dumber.  This can be useful however if you
  614. want all bots to be "roaming killers" to liven up the mix, instead
  615. of bots trying to capture and defend the flag.  Also, if you want
  616. to move the flags on the maps that CTF Bot has waypoints for, you
  617. will need to turn off bot use of waypoints on those maps otherwise
  618. the bots will get very confused (e.g. defending the area where the
  619. flag used to be).
  620.  
  621. Impulse 90 tosses out a backpack with your weapon with some 
  622. ammo for it.  This is useful for tossing stuff to bots.  
  623.  
  624. Impulse 130 toggles no target mode.  When no target mode is on,
  625. enemy bots won't try to target human players, but otherwise everything is
  626. the same.  You can still pick up stuff, and you can still be harmed by
  627. bot crossfire, you can still capture the flag, you can still kill bots,
  628. etc.  This is very useful for debugging the bots.
  629.  
  630. Impulse 131 toggles always escort mode.  When always escort is on,
  631. bots will *always* try to escort you.  You don't have to explicitly 
  632. give them orders to request escort.  This is like version 1.1 of CTF
  633. Bot, where bots always follow you around.  
  634.  
  635. Impulse 97 puts you toggles no damage mode.  You take no damage.  This is
  636. for debugging aspects of the bots where it would be hard to debug if the
  637. bots are killing you.
  638.  
  639. Impulse 98 puts you in observer mode.  Observer mode is like when you
  640. join the server, press 1 or 2 for red/blue team.  When observer mode is
  641. on, you can fly and do not interact with the world at all. You can't
  642. execute impulses as an observer... you must press 1 or 2 to join a team
  643. or press jump to join a computer-selected team before you can execute
  644. impulses.  In observer mode you can fly, the same as when you use the
  645. fly mode cheat in single player.Impulse 107/108 removes the red/blue bot
  646. with the fewest frags.
  647.  
  648. Dynamic Map Creation/Modification
  649. =================================
  650. Impulse ##    Key   Description
  651. -----------   ---   -----------
  652. impulse 115 =  r  = move/create red flag
  653. impulse 116 =  b  = move/create blue flag
  654. impulse 117 =  a  = create base stockpile
  655. impulse 118 =  e  = print entity list
  656.  
  657. NOTE: By default the above keys are commented out in ctfbot.cfg...
  658. uncomment them to use the above key bindings.
  659.  
  660. Impulse 115/116 creates a red/blue flag where you are standing.  
  661. You can only create one red or blue flag.  If you create another,
  662. the first one is removed.  You can use this to move the maps in the 
  663. existing CTF levels (e.g. ctf1-ctf8) if you feel like a change.  
  664. (Of course if you are playing the bots then the waypoints will
  665. no longer work on those levels.)
  666.  
  667. In addition to the flag, 9 team spawn points are created when you
  668. create or move a flag.  This is done so that if you want to spawn
  669. some bots, they will appear near their flag.  All other team spawn
  670. points in the level for that team are removed.  If a spawn point
  671. is created in a wall, it is removed.
  672.  
  673. Impulse 117 creates a respawning stockpile of 1 yellow armor, 
  674. 1 super nailgun, 1 double shotgun, 2 large boxes of nails, 2 
  675. large boxes of shells, and 2 25-health boxes.  
  676.  
  677. The above items may behave strangely or will fall out of the level if
  678. they are spawned in a wall or on top of an object or player. Please step
  679. out of the way after creating the items.  You will be warned and be
  680. given 2 seconds before the items are enabled.
  681.  
  682. Your changes are *NOT* saved with the map.  You have to recreate the
  683. flags and bases every time you quit and restart Quake.  So don't 
  684. worry about screwing up your maps; you can't permanently change the
  685. map.
  686.  
  687. *HOWEVER*, if you want to permanently change a map, you can use impulse
  688. 118.  Impulse 118 prints out all entities that you dynamically created.
  689. It prints them to the console in the format used by QBSP for inserting
  690. entities into a bsp file.  If you want to use this feature to
  691. permanently modify a bsp file, start Quake with the -condebug command
  692. line option to save all console text to the file qconsole.log in the
  693. ctfbot directory.  Then add flags or items to the map with impulses
  694. 115-117.  Finally, use impulse 118 to list the entities that you
  695. created.  Impulse 118 doesn't print out all the entities in the map,
  696. only entities that you created, so you will have to strip out the
  697. existing entities from the bsp file, paste them together with the
  698. entities printed out in qconsole.log, then use QBSP with the -onlyents
  699. parameter (i.e. as done by the dobsp.bat file in the ThreeWave server
  700. mod) to replace the entities in the bsp file.  If you merely moved a
  701. flag instead of creating a new one, the old team spawn points will still
  702. be in the bsp file, so remember to delete them.  Also, this will print
  703. out the waypoints in the map, so either delete them or use them 
  704. depending on what you want to do.
  705.  
  706. Obviously, don't try modifying your bsp files like this unless you 
  707. know what you are doing!
  708.  
  709. Server Administration & Settings [NEW!] 
  710. =======================================
  711. Total Freedom Mode (teamplay flag 2048)
  712. ---------------------------------------
  713. By default, a CTF Bot server is in "total freedom" mode.  This means that
  714. anyone can create a bot, remove a bot, move the flag, etc.  This is great
  715. if you are playing by yourself, but most of the time over a network you
  716. don't want to have this total freedom for everyone, just the admin.
  717.  
  718. You can change the teamplay flags so that only a player who enters the
  719. admin password (which is a specific series of impulses) can do things 
  720. like create bots, move flags and such.
  721.  
  722. Toggle teamplay bit 2048 to turn total admin on or off.  If the bit is
  723. set, all bot impulses are allowed for all players.  If it is not set, all
  724. "naughty" bot impulses are disabled except for the admin, who can do
  725. anything. Some impulses still work for all players, like detailed scores,
  726. bot frags, rune status, rune dropping, etc.
  727.  
  728. See the admin.qc source file for more information about admin mode,
  729. and how to set an admin password.  There is a default password set
  730. in admin.qc, but you should change it because everyone who has 
  731. downloaded CTF Bot knows what it is (duh).  You will need to recompile
  732. the bot to use your new password.
  733.  
  734. The default password is in server.cfg.  By default you can type 
  735. "admin" at the console to enter admin mode.
  736.  
  737. Total Freedom Mode is on by default (i.e. the bit is set, and any player
  738. can do any impulse).
  739.  
  740. Auto-Even-Teams (teamplay flag 4096)
  741. ------------------------------------
  742. You can change the teamplay flags so that the red and blue teams 
  743. are always even.  Bots are used to pad out teams that are different
  744. in size.
  745.  
  746. Toggle teamplay bit 4096 to turn even teams on or off.  If the bit is
  747. set, when the teams are uneven bots will be added or removed so that the
  748. teams are even again.  Every 2 seconds, the server checks the team sizes
  749. and adds or remove bots.  When removing bots, the bot with the fewest
  750. frags is removed. 
  751.  
  752. The team size and default bot skill is determined by the console
  753. variable "sv_aim".  When you want even teams, multiply the size of the
  754. team desired (1-8) by 4.  Then add the skill of the bots that will
  755. be added in order to keep teams even.  Note that skill does not have 
  756. to be an integer.  Examples:
  757.  
  758. sv_aim 9        // team size 2, skill 1 = (2*4)+1
  759. sv_aim 18       // team size 4, skill 2 = (4*4)+2
  760. sv_aim 34.5     // team size 8, skill 2.5 = (8*4)+2.5
  761.  
  762. An additional tweak:  if you then add 64 to the total, the bot skill
  763. you set will actually be the average skill, and bot skills will vary
  764. plus or minus 0.5.  Thus, a skill of 2.5 will actually add bots that
  765. range (linearly) in skill from 2.0 to 3.0.  The maximum skill is 3.0.
  766.  
  767. sv_aim 98.5     // team size 8, skill 2.5, vary skill = 64+(8*4)+2.5
  768.  
  769. Note that when sv_aim is greater than or equal to 1 (which of course
  770. it will be if you use it in the above manner), all auto-aiming by
  771. Quake is disabled.  If for some insane reason you *want* auto-aiming on
  772. your server (a horrible idea IMO), you'll have to reprogram the bot
  773. to use a different server variable than sv_aim, or not use the
  774. auto-even-teams capability.
  775.  
  776. When auto-even-teams is on, you can't add or remove bots manually
  777. (i.e. with impulse 100 etc), even if you are the admin. 
  778.  
  779. Auto-Even-Teams is off by default (i.e. the bit is not set, and teams
  780. can be uneven).
  781.  
  782. No Player Rune Dropping (teamplay flag 8192)
  783. --------------------------------------------
  784. You can change the teamplay flags so that players and bots are not 
  785. allowed to drop runes.  
  786.  
  787. Toggle teamplay bit 8192 to turn rune dropping off or on.  If the bit is
  788. set, rune dropping is disabled.  If the bit is not set, players and
  789. bots can drop runes.  Note that bots will drop runes only if a player
  790. asks them to.
  791.  
  792. Rune dropping is on by default (i.e. the bit is not set, and players
  793. can drop runes).
  794.  
  795. No Bot Flag Pickups (teamplay flag 16384)
  796. -----------------------------------------
  797. You can change the teamplay flags so that bots are cannot pick up 
  798. the enemy flag.  They can still return their own flag to base.  This
  799. can be useful if humans are letting the bots too much work, or you feel
  800. that the bots are too dumb for the responsibility of carrying the flag.
  801.  
  802. Toggle teamplay bit 8192 to bot flag pickups off or on.  If the bit is
  803. set, bots can't pick up the enemy flag.  If the bit is not set, bots 
  804. can pick up the enemy flag.
  805.  
  806. No Bot Flag Pickups is off by default (i.e. the bit is not set, and bots
  807. can pick up the enemy flag).
  808.  
  809. Waypoints [NEW!]
  810. ================
  811. Bots use waypoints to navigate on certain maps.  Waypoints are basically
  812. "threads" that lead the bot into or out of a base.  Waypoints are 
  813. necessary because otherwise bots would have NO knowledge of a level
  814. when they are spawned.  They would wander around randomly and probably
  815. not find their way to the enemy base.  Without waypoints, enemy bots 
  816. generally take your flag only if they happen to spawn in your base.  
  817. With waypoints, however, bots know exactly how to get into your base 
  818. and actually try to go there on purpose.  This makes CTF much more
  819. interesting and challenging, as bots can actually use some CTF strategy
  820. (if "try to take the other team's flag" can be termed a strategy).
  821.  
  822. How to Create Waypoints
  823. -----------------------
  824. Most people will not want to try this because it is too technical.  It's 
  825. certainly not required to play the bots.  Several maps already have
  826. waypoints defined, and even on maps without waypoints the bots can be
  827. fun.
  828.  
  829. The waypoints for the maps the bots know about are compiled into the bot
  830. code and dynamically created when the map starts.  They are not stored as
  831. entities in the bsp so there is no need to use QBSP to modify the bsp
  832. file.  The bots know what map they are playing on and use the waypoints if
  833. they have them.  If there are no waypoints for the map, the bots probably
  834. won't capture your flag, but they will try their best anyway.  
  835.  
  836. If you want to add waypoints to a map you will need to modify the code
  837. and recompile the bot.  However, there are several impulse commands to
  838. help you add waypoints without having to think about programming at all.
  839. The tricky thing is then testing your waypoints and figuring out how to
  840. pick better points.
  841.  
  842. A sequence of waypoints is called a path.  Paths always start near a
  843. flag, with waypoint number 0. Waypoint 1 is then nearby, followed with
  844. increasing waypoint numbers as the path goes away from the flag.
  845. Generally paths lead to a central area.  Any number of paths can exist in
  846. a map, but you need at least 2: one from the red flag to a central area
  847. and one from the blue flag to a central area.  From each waypoint on a
  848. path you should be able to see the next waypoint.  So generally you put
  849. waypoints in hallway corners.  You should end a path when you can see
  850. the end of the other team's path. For doors and teleporters, you should
  851. put the waypoint close enough to the door/teleporter so that the bot will
  852. open the door or go through the teleporter.  Remember to put waypoints on
  853. *both* sides of a door/teleporter, because paths are two-way!  That is,
  854. the bots will follow the paths to get INTO and OUT OF a base.
  855.  
  856. Red waypoint 0 should be near the red flag, blue waypoint 0 should
  857. be near the blue flag.  Waypoint 0 is where the bots will tend
  858. to hang out when they are defending, so the closer to the flag the
  859. better.  
  860.  
  861. It is *NOT* necessary to make a path go all the way from one flag to the
  862. other flag.  You need to make each team's path go only halfway across the
  863. map.  The bots use the red path to get to the red flag and the blue path
  864. to get to the blue flag.... but if they can't find the red path, they go
  865. the opposite way on the blue path to try to get back to the central area
  866. where they can see the red path. However, having paths go all the way to
  867. the enemy flag will probably still work properly, and may even work
  868. better.  But the bots weren't designed to work with paths that go all
  869. the way across the map, and future versions of the bots that use 
  870. different ai techniques may not work as well with those maps.  It's
  871. probably better to stick to the current waypoint conventions. Also,
  872. it's easier to do it the "right" way because there are half as many 
  873. waypoint that you need to create.  Also, the fewer the waypoints, the
  874. better the bots run on that map, because looking through waypoints
  875. takes time and having extraneous waypoints wastes CPU time.
  876.  
  877. When making multiple paths, there is no reason to have a group of
  878. waypoint all in the same area.  If there is already a waypoint #1
  879. where you want it, then don't put another one there.  The bots will
  880. use the waypoint that is already there.  However, sometimes a couple
  881. of waypoints with the same number placed nearby can be helpful.
  882.  
  883. Also, there is no reason to put waypoints every couple of feet.
  884. Place waypoints only where necessary.  Bots will ignore the 
  885. intermediary waypoints when following the path and go directly
  886. toward the "best" waypoint.
  887.  
  888. Waypoints do *NOT* have to be numerically continuous... a path can
  889. go 0, 1, 2, 4, 16 and be perfectly valid.  Sometimes it is necessary
  890. to make discontinuous paths in order to let the bots take an alternate
  891. path to the base.  Bots will always go for the best waypoint, so bots
  892. will always go for the shorter path, unless you use discontinuous
  893. paths to fake the bot out.  
  894.  
  895. Examples:
  896. ---------
  897.  
  898. Map with 1 Path from Base to Base (Just Enough Waypoints):
  899. ----------------------------------------------------------
  900. red flag ->R0->R1->R2-> [central area] <-B2<-B1<-B0<- blue flag
  901.  
  902.  
  903. Map with 2 Paths from Base to Base:
  904. -----------------------------------
  905. red flag-->R0->R1->R2-> [central area] <-B2<-B1<-+
  906.             +->R1->R2-> [central area] <-B2<-B1<-B0<- blue flag
  907.  
  908.  
  909. Map with More Waypoints Than Necessary:
  910. ---------------------------------------
  911. red flag ->R0->R1->R2->R3->R4->R5->R6-> 
  912.          <-B6<-B5<-B4<-B3<-B2<-B1<-B0<- blue flag
  913.  
  914.  
  915. Turn on bot debug (default key F8) to see the waypoints on the maps that
  916. have them.  They are represented by bubble sprites.  You should be able
  917. to see what is going on fairly well.  Also when bot debug is on, when
  918. you walk over a waypoint it tells you the team and number of that
  919. waypoint.
  920.  
  921. To create a path, start up Quake with the -condebug parameter so that
  922. all console text is logged to the file qconsole.log in the ctfbot
  923. directory. Then use the following impulses to create a path.  You must
  924. be of the same color as the path (i.e. when you are red you make a red
  925. path).
  926.  
  927. Impulse ##     Key   Description
  928. -----------    ---   -----------
  929. impulse  185 =  n  = start a new path of your team
  930. impulse  186 =  w  = create the next waypoint in current path
  931. impulse  187 =  q  = print waypoints to console (stop creating waypoints)
  932. impulse  188 =  m  = start a new general path
  933. impulse  189 =     = remove closest waypoint
  934.  
  935. NOTE: By default the above keys are commented out in ctfbot.cfg... 
  936. uncomment them to use the above key bindings.
  937.  
  938. Plus, when you are creating waypoints:
  939.  
  940. impulse 1-20 = lay down specific waypoint number of your team
  941.  
  942. Use impulse 187 to stop spawning waypoints and print waypoints to the
  943. console. When you print waypoints with impulse 187, they are printed in
  944. a format that you can pretty much copy and paste into the bot code (but
  945. you may have to clean up the vectors so that they compile). The routine
  946. to add the code snippet is SpawnWaypointsForMap in the file botway.qc.
  947. Note that *all* waypoints in the map are printed out, not just the ones
  948. you added, so if there are already waypoints in the map they will be
  949. printed too. Don't worry about the order in which the waypoints are
  950. printed/created, it doesn't matter.
  951.  
  952. Use impulse 189 to remove the closest waypoint to you.  This is
  953. useful if you make a mistake when laying down waypoints, or want to
  954. move a waypoint.
  955.  
  956. When you are finished making waypoints, it would be good to test them.
  957. A good way to test them is to start the map, turn on "no target" mode so
  958. your presence won't affect the bots, add one red bot, and make sure the
  959. bot can capture the enemy flag.  Then do the same with a blue bot.
  960.  
  961. If you create a good group of waypoints for a map, please send them to me
  962. so that I can choose to incorporate them into the master CTF Bot code,
  963. so everyone can play with them.  I will of course give you credit for
  964. creating the waypoints.
  965.  
  966. Of course, don't try this unless you know what you are doing!  You will
  967. have to recompile the bot, for this you will require a Quake C compiler,
  968. which you can get at http://www.cdrom.com/pub/quake/quakec/utils/
  969. I recommend ADVQCC.  Also see the "Source Code" section below for 
  970. more info on recompiling the bot.
  971.  
  972. General Waypoints [NEW!] 
  973. ------------------------
  974. When bots can't find red or blue waypoints, they look for a path made up
  975. of general waypoints.  They always try to follow general waypoints in
  976. decreasing numbers looking for general waypoint zero.  From general
  977. waypoint zero you should be able to see either a red or a blue waypoint.
  978. It is useful to have a general waypoint path visible from every respawn
  979. location in the map, so that no matter where bots respawn they can find
  980. their way back to the bases.  Also, if the bots tend to get stuck
  981. somewhere because they fall in and can't see any red or blue waypoints
  982. from there, use a general waypoint path to lead them out. Sometimes just
  983. one strategically placed general waypoints will help bots know that they
  984. should grapple out of whatever hole they've fallen into.  You can have
  985. any number of general paths in a map.
  986.  
  987. Use impulse 188 to start a new general path.  Just as when creating
  988. red/blue paths, you can use impulse 186 to lay down the next waypoint, 
  989. or impulse 1-20 to lay down a specific number.
  990.  
  991. Waypoints in .BSP files [NEW!] 
  992. ------------------------------
  993. If you want to make waypoints that are entities in the bsp file, instead
  994. of created by the bot code, that is also possible.  This would make it
  995. possible to use custom maps with waypoints without having to recompile
  996. the bot. Note that the clients would *NOT* have to download the bsps that
  997. are modified in this manner. Only the server needs to have the bsp with
  998. waypoints, because the server controls the spawning of all entities.
  999.  
  1000. Most of the time it'd probably be better to put the entities into the
  1001. bot code, because that way you don't have to muck about with different
  1002. versions of the bsp files.  
  1003.  
  1004. Here is an example:
  1005.  
  1006. {
  1007. "classname" "waypoint"
  1008. "origin" "0 0 0"
  1009. "team" "5"
  1010. "waypoint_num" "0"
  1011. };
  1012.  
  1013. "classname" must be "waypoint". For "team", use 5 for red, 14 for blue,
  1014. and -1 for general. "origin" needs to be the where you actually want it
  1015. instead of '0 0 0' of course. "waypoint_num" needs to be a number as
  1016. described above.
  1017.  
  1018. Extra Waypoints
  1019. ---------------
  1020. In the file botway.qc, commented out, are several alternate waypoint 
  1021. sets sent to me by various people.  I have not tested these 
  1022. extensively, but they may in fact work better than the default 
  1023. waypoints.  Feel free to put them back in the code and try them out,
  1024. or combine them with existing waypoint sets.  Some of the alternate
  1025. sets use techniques that the waypoints are not designed for, but
  1026. it may work great for you anyway.
  1027.  
  1028. Source Code
  1029. ===========
  1030. IMPORTANT NOTE: Keep in mind that the CTF portion of the CTF Bot source
  1031. code is based on ThreeWave CTF 3.5, and any modifications you make to
  1032. the code may be restricted in their distribution and use.  Read the
  1033. ThreeWave server mod readme for more info.
  1034.  
  1035. The source code is in the src directory.  Use the included progs.src
  1036. which handles the different directories for the bot source code.  You
  1037. may have to edit progs.src to compile the progs.dat into the appropriate
  1038. directory.
  1039.  
  1040. The current code may not do super-smart things.  A lot of it is a massive
  1041. hack.  Also there are many routines that could be heavily optimized for
  1042. speed.  The code is constantly evolving so if you think something is
  1043. dumb, it probably is.  Also, don't necessarily trust the comments, as
  1044. the comments may be outdated.
  1045.  
  1046. Note that all of the monsters have been removed by ThreeWave CTF 3.5.  
  1047.  
  1048. If you come up with any cool modifications to this bot, I'd appreciate it 
  1049. if you emailed them to me, so that I can choose to incorporate them into 
  1050. the master CTF Bot code.  I will of course give you credit.
  1051.  
  1052. All changes related to the bot (should be) marked with "CTFBOT", except
  1053. in the new bot files of course.  Changes that are not bot related, but
  1054. are CTF improvements (like drop rune and CTF bug fixes), are marked with
  1055. "CTFBOT EXTRAS".  Of course, I may have missed a few, so do a global
  1056. diff to see what really has changed.
  1057.  
  1058. CTF Bot is very large and you may have trouble compiling the source code
  1059. with most QCC compilers.  I use ADVQCC which is available at:
  1060. http://www.cdrom.com/pub/quake/quakec/utils/  If you are having trouble
  1061. compiling the source with other compilers, you may have to remove
  1062. sections (e.g. waypoints for maps you are not using).  If you know of
  1063. a better compiler than ADVQCC, please let me know.
  1064.  
  1065. If you are working with recompiling the bot source code, you will almost
  1066. definitely want to unpak your pak0.pak and pak1.pak, so that the ctfbot
  1067. directory has no pak files in it.  If there are pak files, Quake may use
  1068. the progs.dat or player.mdl from the pak files instead of the ones
  1069. sitting in the directory.  Without pak files you will know for sure what
  1070. files Quake will be using.  Basically you need the player.mdl from the
  1071. pak1.pak (which has extra red/blue skins required to see the bots as
  1072. different colors) instead of the one from the pak0.pak.  See the
  1073. "Troubleshooting" section above for more info.
  1074.  
  1075. CTF Bot with QuakeWorld
  1076. -----------------------
  1077. I have no plans to convert CTF Bot to QuakeWorld.  It could probably be
  1078. done, but it may not be possible to get good performance.  It was
  1079. several weeks and lots of testing before the grappling hook was
  1080. converted to work properly in QuakeWorld, and the bots are moving around
  1081. in a much more complicated way.  It may take a lot of tweaking and
  1082. testing to make the bots work right with the QuakeWorld prediction
  1083. model.  Then again, perhaps it would be easy.  Regardless, I don't have
  1084. the necessary equipment or time to do a version myself.
  1085.  
  1086. If you would like to try to convert CTF Bot to QuakeWorld, the CTF Bot
  1087. code will have to be merged into the latest ThreeWave CTF QW server mod,
  1088. available at ThreeWave.  You will have to make the bots use the new
  1089. grappling hook routines. QuakeWorld uses the same QCC compiler but the
  1090. defs.qc file is different in QW, so the resulting progs.dat files are
  1091. incompatible between Quake and QuakeWorld.  
  1092.  
  1093. Not Yet Added/Things To Do/Known Bugs
  1094. =====================================
  1095. + bots may be too slow on slower machines, and take up a lot of memory
  1096. + bots don't know how to swim up to avoid drowning (but they try to
  1097.     fire hook)
  1098. + bots sometimes run slightly slower than normal
  1099. + bot water levels are not correct (i.e. bot may be able to fire
  1100.     thunderbolt in water that a human can't, may not be affected by
  1101.     shallow lava, etc.)
  1102. + red bot skins still glow slightly
  1103. + bot's don't know about any teamplay damage modes other than the default 
  1104.     CTF mode (i.e. can't hurt teammates at all) and will probably kill
  1105.     their friends fairly often if teamplay is changed so that teammates
  1106.     can be damaged.
  1107. + bots can't travel over broken ground
  1108. + bots sometimes try to use the hook to get to high places instead of just 
  1109.      walking up the stairs/ramp
  1110. + bots don't know when an item is inaccessible, and continue to try to get it
  1111. + bots get telefragged when entering the game with makebots.cfg
  1112. + sometimes bots move at normal running speed when being pulled by the
  1113.      hook, especially when going parallel to the floor (friction?)
  1114. + bots don't necessarily start firing at an enemy that is firing at them;
  1115.      they have to notice the enemy first... if they are trying to get
  1116.      a good but inaccessible item they are unlikely to turn around and
  1117.      start firing at the enemy
  1118. + bot player model doesn't pitch up/down quite properly when bot aims up/down
  1119. + bots initially spawn in the floor in ctf2 (map problem???)
  1120. + when bots try to talk to team members only, talk beep is heard by
  1121.     everyone
  1122. + bots are not affected by sv_aim (not actually a bug because sv_aim
  1123.     should always be 1.0 anyway)
  1124. + bots are not affected by and don't know about wind tunnels
  1125. + bots jump into lava/slime too much
  1126. + bot names are not saved between levels, or when bots are added/removed,
  1127.     they are always random
  1128. + bots are not very smart about teleporters, buttons, or secrets
  1129. + tons of other stuff of course
  1130.  
  1131. Future Plans
  1132. ============
  1133. + support new releases of ThreeWave CTF as they are created
  1134. + waypoint support for more maps, plus improved waypoint schemes
  1135. + more dynamic CTF map creation/modification support
  1136. + make bots seem more human
  1137. + make bots smarter in general
  1138. + make bots know more about ctf strategy (i.e. don't leave the base
  1139.     undefended to just go exploring)
  1140. + make bots use hook better
  1141. + make bots kill the guy who took their flag with higher priority
  1142. + carry bots over to next level (although this is sort of handled by
  1143.     the auto-even-teams thing)
  1144. + make bots hook you intentionally
  1145. + make bots communicate with other bots on its team... let them ask 
  1146.     for ammo and/or weapons, tell them about a rune on the ground, tell 
  1147.     them to come back to the base, etc.
  1148. + make it so that if you try to play CTF on a map that has a CTF
  1149.     version, the flags etc. are automatically spawned, so there is
  1150.     no need to convert the maps to CTF with QBSP.
  1151.  
  1152. Bug Reporting/Comments/Suggestions
  1153. ==================================
  1154. Send bugs, comments, suggestions, code snippets, ideas, techniques,
  1155. whatever, to drew@interpath.com. For bug reporting, please be as specific
  1156. as possible.  I try to answer all email, but I am doing this in my spare
  1157. time for fun, so sometimes I can fall behind in answering email. If you
  1158. are having trouble, please read through this readme file and/or the
  1159. ThreeWave CTF documentation for help before emailing me.  Most of the time
  1160. your question will be answered in the documentation.  Also, please do 
  1161. *NOT* email me binary files without receiving my permission!
  1162.  
  1163. No Warranty
  1164. ===========
  1165. This software has NO WARRANTY.  Use this software at your own risk.  The
  1166. author or any co-author of this work is NOT RESPONSIBLE for any harm or
  1167. damage done as a result of using this sofware, or following any of the
  1168. procedures described in this document or any documents accompanying this
  1169. software.
  1170.  
  1171. Distribution & Use
  1172. ==================
  1173. The CTF portion of the CTF Bot source code is based on ThreeWave CTF 3.5, 
  1174. and any modification or use of the CTF portion of the code may be 
  1175. restricted.  Read the ThreeWave server mod readme for more info.
  1176.  
  1177. You may NOT modify CTF Bot and distribute your modification, UNLESS (1)
  1178. your modification is publically available on the Internet for free, AND
  1179. (2) the complete source code of your modification is publically
  1180. available on the Internet for free, AND (3) the name of your
  1181. modification is different.
  1182.  
  1183. You may NOT distribute CTF Bot or a modification of CTF Bot as part of
  1184. a commercial product or service (including but not limited to CD-ROMs and
  1185. pay-to-play Quake servers) unless you get prior written permission from
  1186. both Dave 'Zoid' Kirsch at zoid@threewave.com, and Andrew B. Davidson at
  1187. drew@interpath.com before doing anything with CTF Bot.  Please get
  1188. permission from Andrew B. Davidson first before bothering Dave Kirsch.
  1189.  
  1190. This readme file, other included files, and portions of the included
  1191. source code created by Andrew B. Davidson are Copyright (C) 1996-1997
  1192. Andrew B. Davidson.  Other portions of the source code are copyright
  1193. their respective creators.  All rights reserved.
  1194.  
  1195. Acknowledgements & Credits
  1196. ==========================
  1197. First I'd like to thank id software for Quake and Quake C.  
  1198.  
  1199. Thanks to everyone who has sent me email saying that they
  1200. liked the bot!
  1201.  
  1202. Thanks to Dave 'Zoid' Kirsch and the co-creators of CTF for
  1203. ThreeWave CTF and the great maps and models.
  1204.  
  1205. koc1 Chthon's Capture House by Dave 'Zoid' Kirsch <zoid@threewave.com>
  1206. ctf1 McKinley Base by Dave 'Zoid' Kirsch <zoid@threewave.com>
  1207. ctf2 The Kiln by Brian Wight <briwig@odc.net>
  1208. ctf3 DySpHoRiA by Chris 'b0rt' Thibodeaux <chrislt@u.washington.edu>
  1209. ctf4 The Forgotten Mines by Brian Wight <briwig@odc.net>
  1210. ctf5 Da Ancient War Grounds Matthew 'DaBug' Hooper <junebug@linknet.net>
  1211. ctf6 Vertigo by Dale 'Midiguy' B. <midiguy@crl.com>
  1212. ctf7 Tale of Two Cities by Jamie Mactaggart <Maareck@msn.com>
  1213. ctf8 The StrongBox by Brent '[Drizzt]' Mcleod <mcleod@westworld.com>
  1214. CTF Skin man: Ryan 'Grey_Ghost' Lacouture <vallore@wt.net>
  1215. Brian 'Whaleboy' Cozzens for flag models
  1216. See also ThreeWave server mod docs for more CTF credits.
  1217.  
  1218. Thanks to psycho killer Scott 'Fletch' Haynes for testing and 
  1219. invaluable assistance and suggestions.  
  1220.  
  1221. Thanks to Tim Willits for idctf1.
  1222.  
  1223. Thanks to Eric Cherry <EJCherry@aol.com> and 
  1224. James Kupperian <SuicidalManiac@DeathsDoor.com> for graphics help.
  1225.  
  1226. Testing, Converion to CTF of dm1, and waypoints for e1m3, 
  1227. dm1 and dm6 added by Kester 'MadKez' Baird 
  1228. <kes@nbaird.demon.co.uk>.  
  1229.  
  1230. Thanks to the Clan Maniac guys for testing, and especially
  1231. thanks to James Kupperian <SuicidalManiac@DeathsDoor.com> for 
  1232. testing, and for making maniac1, maniac2 and the waypoints also.
  1233.  
  1234. Thanks to Fargo <fargo@planetquake.com> for cool ideas.
  1235.  
  1236. satyr1a designed by Joe 'Satyr' Milton <jcm@worldaccess.com>
  1237. http://www.worldaccess.com/~jcm
  1238. CTF conversion and waypoints by Brian Wight <briwig@odc.net>
  1239.  
  1240. mexx6 designed by Marcus Dromowicz 
  1241. <Marcus.Dromowicz@Informatik.Uni-Oldenburg.DE>
  1242. CTF conversion and waypoints by Brian Wight <briwig@odc.net>
  1243.  
  1244. martim5 designed by:
  1245. Marco van Schriek <m.g.m.vanschriek@iahlvlp.agro.nl>
  1246. Tim van Hal <m.g.m.vanschriek@iahlvlp.agro.nl>
  1247. Roel Tiemessen <roeltiem@pi.net>
  1248. Kees Rosendaal <k.rosendaal@student.kun.nl>
  1249. http://www.dra.nl/~keros/martim
  1250. CTF conversion and waypoints by Brian Wight <briwig@odc.net>
  1251.  
  1252. Thanks to Karl Was <karlw@tic.ab.ca> for creating additional
  1253. waypoints for e1m2 and dm3.
  1254.  
  1255. Thanks to Hoon <hoon@ihug.co.nz> created the waypoints for 
  1256. e1m4 and e2m1.
  1257.  
  1258. Thanks to everyone in the online Quake community providing 
  1259. free stuff to play with. You all kick ass.
  1260.  
  1261. Availability
  1262. ============
  1263. This modification is available from the following URLs:
  1264.  
  1265. HOME: http://www.interpath.com/~davidson/ctfbot.htm
  1266. WWW : http://www.cdrom.com/pub/quake/quakec/bots/
  1267.  
  1268.  
  1269.