home *** CD-ROM | disk | FTP | other *** search
/ Simtel MSDOS - Coast to Coast / simteldosarchivecoasttocoast2.iso / pgmutil / pcrob141.zip / PCROBOTS.DOC next >
Text File  |  1993-01-07  |  80KB  |  2,303 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.             PCROBOTS V1.41 By P.D.Smith (psmithb@CIX) 1992
  8.             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  9.  
  10.             Introduction
  11.             ~~~~~~~~~~~~~
  12.  
  13.             PCROBOTS is an adaptation of CROBOTS by Tom Poindexter. This
  14.             version has more features, and allows for much more
  15.             intelligent robots. It is not limited to any particular
  16.             language; C, Pascal,Compiled Basic, 8086 Assembler etc are
  17.             all possible. The only limitation is that it must be run on
  18.             an IBM PC Compatible.
  19.  
  20.             PCRobots uses 'robots' which are actually MsDos .COM or .EXE
  21.             programs. Each program is allocated 64k for data, program &
  22.             stack requirements. This is the main limiting factor for the
  23.             number of robots being run at once. If only conventional RAM
  24.             is used a maximum of 7-8 robots is possible, depending on
  25.             your system. However, with V1.3 onwards, EMS memory can be
  26.             used. This allows up to 20 robots at once.
  27.  
  28.             PCRobots allows a large user defined arena, with obstacles
  29.             in it, it also allows inter-robot communication to allow
  30.             teamwork between robots. PCROBOTS uses a cooperative
  31.             multitasker to share the processor between the robots, the
  32.             way this works means that robots can do lots of calculations
  33.             and planning without being penalised.
  34.  
  35.             Robots are configurable, this means that if your program
  36.             suits a fast agile robot, but one which doesn't need a long
  37.             cannon range, then you can configure the robot to make use
  38.             of this. Alternatively, you may want a slow robot with lots
  39.             of armour, this is also possible
  40.  
  41.             Hardware Requirements
  42.             ~~~~~~~~~~~~~~~~~~~~~~
  43.             PCROBOTS can only be run on a PC with an EGA or VGA monitor.
  44.  
  45.             A coprocessor is optional, but it will speed up processing
  46.             of functions like scans.
  47.  
  48.             PCROBOTS supports an Adlib compatible soundcard for (very)
  49.             basic sound effects.
  50.  
  51.  
  52.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  53.             ============================================================
  54.  
  55.             How to run PCROBOTS
  56.             ~~~~~~~~~~~~~~~~~~~~
  57.  
  58.             To run the program, use a command line like:
  59.  
  60.             PCROBOTS robot1 robot1 robot2
  61.  
  62.             This will run the 'robot1' program twice, and the
  63.             'robot2' program once.
  64.  
  65.             You can also specify groups of robots to operate as teams.
  66.             To do this you use the name <team>.TM (eg 'myteam.tm')
  67.             instead of a robot name. This file should be a text file
  68.             with a separate line for each robot in the team.
  69.  
  70.             There are also optional parameters which can be used:
  71.  
  72.                  -d - this lets you run PCROBOTS in 'debugging' mode.
  73.                       Normally PCROBOTS will stop running as soon as
  74.                       there is only one robot left. Using this switch
  75.                       will make PCROBOTS keep running until you manually
  76.                       stop it by pressing the ESC key.
  77.  
  78.                  -l<n> - this lets you set the maximum number of 'ticks'
  79.                       that a game will run. A tick is not a fixed time
  80.                       interval, instead it is a complete turn for all
  81.                       the robots. There must not be a space between the
  82.                       'l' and the number to be used. Eg '-l5000' will
  83.                       run the game for 5000 ticks.
  84.  
  85.                  -f<name> - this will append a summary of the game
  86.                       results to the file specified after the 'f'. Again
  87.                       there must be no space between the 'f' and the
  88.                       filename which follows. If no filename is
  89.                       specified, then the name 'PCROBOTS.LOG' is used.
  90.  
  91.                  -s - this will run PCROBOTS in 'slow' mode to help you
  92.                       see what a robot is doing. Pressing the spacebar
  93.                       will toggle 'single step' mode on and off (the
  94.                       'enter' key will single step). Pressing the '0' to
  95.                       '9' keys will set the speed.
  96.  
  97.                  -q - this will run PCROBOTS in 'quick' mode. In this
  98.                       mode, certain features such as explosions, and
  99.                       sound effects are disabled to increase game speed.
  100.  
  101.                  -a - this allows you to specify an alternative arena
  102.                       file, rather than the default of PCROBOTS.RNA.
  103.  
  104.                  -m - this redirects STDOUT output to a monochrome
  105.                       monitor if you have one fitted to your PC (used
  106.                       for debugging robots).
  107.  
  108.  
  109.  
  110.  
  111.  
  112.             ============================================================
  113.                                                                Page No 2
  114.  
  115.  
  116.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  117.             ============================================================
  118.  
  119.                  -v - this gives a 'verbose' output, both at startup,
  120.                       and in the results phase.
  121.  
  122.                  -r - this lets you set the random number generator seed
  123.                       to allow identical runs to be made.
  124.  
  125.                  -i - this enables more interrupt functions, it should
  126.                       only be used during debugging.
  127.  
  128.             The parameters can be placed anywhere on the command line
  129.             following the PCROBOTS name.
  130.  
  131.             Errorlevel values
  132.             ~~~~~~~~~~~~~~~~~~
  133.             When PCRobots exits it sets the DOS errorlevel value to
  134.             allow testing from batch files. The values are:
  135.  
  136.              -1     = Error
  137.              0 -> n = Winning robot
  138.              100    = Draw (>=2 left alive)
  139.              101    = Draw (0 left alive)
  140.              200    = Esc pressed
  141.  
  142.             The PCROBOTS Arena
  143.             ~~~~~~~~~~~~~~~~~~~
  144.  
  145.             The 'Arena' is a large 1000x1000 area. Each robot can move a
  146.             maximum of 1 square per move. This is unlike the original
  147.             CROBOTS where a robot could move 100 square per move.
  148.  
  149.             The arena is displayed as a large white box occupying most
  150.             of the screen.Inside this box you will see any obstacles
  151.             that have been placed on the map (see later section for a
  152.             description of the map file). All obstacles have a white
  153.             border displayed around the square, and are defined as
  154.             below:
  155.                  White - A wall - Robots can see through this, but they
  156.                       can't move or fire shells through it. If a robot
  157.                       collides with a wall it will lose 1 armour point.
  158.                  Red - A damage trap - A robot loses 1 armour point for
  159.                       every turn it is on one of these squares.
  160.                  Green - A refueling point - If a robot comes to rest on
  161.                       one of these points, it will regain some battery
  162.                       power (see later section for more details). There
  163.                       can be up to 10 refueling points per arena.
  164.  
  165.  
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.             ============================================================
  177.                                                                Page No 3
  178.  
  179.  
  180.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  181.             ============================================================
  182.  
  183.             The Robots
  184.             ~~~~~~~~~~~
  185.  
  186.             The robots will be displayed on the arena as small 5x5 pixel
  187.             shapes in a particular colour. The actual shape can be
  188.             defined in the robot program, but the default is a small
  189.             'smiley'.
  190.  
  191.             Down the right hand side of the screen there will be a list
  192.             of robots. For each entry down the right, the robot shape
  193.             and colour match the robot in the arena. Underneath the
  194.             robot are two bars. The top bar indicates the armour level
  195.             of the robot - the longer the bar the more armour there is
  196.             left, the shorter the bar, the more the robot is damaged.
  197.             The bottom bar indicates the battery level of the robot -
  198.             again, the longer the bar, the more battery power exists. A
  199.             rapidly moving robot will quickly exhaust its battery power,
  200.             meaning that it will have to wait a while until the battery
  201.             has been recharged slightly before moving on.
  202.  
  203.             If a robot has fired a cannon shell, this will be displayed
  204.             as a simple white pixel. Cannon shells move twice as fast as
  205.             the fastest robot can go, which is four times as fast as a
  206.             normal robot.
  207.  
  208.  
  209.  
  210.  
  211.  
  212.  
  213.  
  214.  
  215.  
  216.  
  217.  
  218.  
  219.  
  220.  
  221.  
  222.  
  223.  
  224.  
  225.  
  226.  
  227.  
  228.  
  229.  
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.             ============================================================
  241.                                                                Page No 4
  242.  
  243.  
  244.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  245.             ============================================================
  246.  
  247.             Teams
  248.             ~~~~~~~~~
  249.  
  250.             Starting with PCRobots V1.3, proper robot teams are
  251.             supported.
  252.  
  253.             Team starting locations are defined in the arena map - if a
  254.             starting location for a certain team isn't specified, then
  255.             the robots will be placed randomly.
  256.  
  257.             A team is a group of robots which the PCRobots kernel
  258.             recognises as being together. The robots have to work
  259.             together as well, as it's entirely possible for a team to
  260.             wipe itself out without any help from anyone else!
  261.  
  262.             To define a team you make a file with an extension .TM .
  263.             This file should contain a list of robot names with one name
  264.             per line.
  265.  
  266.             All the robots in a specified team will start in the map
  267.             square which is defined in the arena file. Their actual
  268.             positions on that map square are random.
  269.  
  270.             It is possible to mix teams and 'loners' on any run.
  271.  
  272.             Teams will be given a score after a run.
  273.  
  274.             The score is currently obtained from the number of robots
  275.             which are killed by that team.
  276.  
  277.                  100 points - enemy robot killed
  278.                 -500 points - friendly robot killed.
  279.  
  280.             If teams are used, the game will end when only one team is
  281.             left and there are no loner robots alive.
  282.  
  283.             Coordinates
  284.             ~~~~~~~~~~~~
  285.             The arena is defined with the coordinate 0,0 being at the
  286.             top left of the screen, and 999,999 being at the bottom
  287.             right of the screen.
  288.             Angles are defined as 0 degrees pointing to the right and
  289.             angles increase in a clockwise direction - so 90 degrees is
  290.             pointing straight down. (This allows the use of programs for
  291.             the original CRobots - the only difference being that 0,0 is
  292.             at the top left now, instead of the bottom right - this
  293.             means the robot will do a mirror image of its previous
  294.             action.
  295.  
  296.             The Map
  297.             ~~~~~~~~
  298.             The robot combat arena is defined in the file PCROBOTS.RNA
  299.             (if the file doesn't exist, then the arena is empty).
  300.  
  301.  
  302.  
  303.  
  304.             ============================================================
  305.                                                                Page No 5
  306.  
  307.  
  308.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  309.             ============================================================
  310.  
  311.             The arena is divided into 10x10 pixel squares (that's
  312.             100x100 squares in the whole arena). The contents of each
  313.             square are defined by a single character in the PCROBOTS.RNA
  314.             file.
  315.  
  316.             Each line of PCROBOTS.RNA defines a line in the arena, and
  317.             each character defines a square on that line.
  318.  
  319.             Ideally, a complete map will consist of 100 lines of 100
  320.             characters each. However, any lines which are not 100 lines
  321.             long will be assumed to be padded with empty area. If 100
  322.             lines don't exist, then the last lines will be padded with
  323.             empty area.
  324.  
  325.             The possible characters (at the moment) are:
  326.  
  327.              '.' - this is an empty square - internally has the value
  328.             set by 'ARENA_FREE' in pcrobots.h
  329.  
  330.              'X' - this is a wall - internally has the value set by
  331.             'ARENA_WALL' in pcrobots.h
  332.  
  333.              'D' - this is a damaging trap - internally has the value
  334.             set by 'ARENA_DAMAGE' in pcrobots.h
  335.  
  336.              'R' - this is a refueling point - internally has the value
  337.             set by 'ARENA_REFUEL' in pcrobots.h
  338.  
  339.              'A' -> 'C' - these are the starting positions for robot
  340.             teams A -> C. They are not marked on the maps.
  341.  
  342.             The robot's scanner will see straight through walls, so to
  343.             avoid collisions, the robot should periodically call
  344.             'get_local_map' to see a 9x9 area around the robot (this
  345.             will be quite a slow call, so shouldn't be called more than
  346.             necessary).
  347.  
  348.             Shells will not pass through walls, so although another
  349.             robot may see you hiding behind a wall, it will not be able
  350.             to damage you unless it moves around the wall. To see if a
  351.             shell has hit a wall you'll have to call the
  352.             'get_shell_status' routine, which will tell you if the last
  353.             shell to land hit a wall or a robot.
  354.  
  355.  
  356.  
  357.  
  358.  
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365.  
  366.  
  367.  
  368.             ============================================================
  369.                                                                Page No 6
  370.  
  371.  
  372.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  373.             ============================================================
  374.  
  375.             Robot Batteries
  376.             ~~~~~~~~~~~~~~~~
  377.             As of version 0.2 robots are powered by electrical
  378.             batteries.
  379.             These batteries are constantly being charged by a solar
  380.             panel, and are constantly being discharged by robot motion.
  381.  
  382.             The battery starts off being charged with 1000 units of
  383.             energy.
  384.             Each turn the battery will be charged by 4 units. Each turn
  385.             that the robot moves the battery will be discharged by the
  386.             current speed / 10. The battery can not be charged above the
  387.             1000 unit level.
  388.  
  389.             If the battery is flat, the robot will come to a
  390.             standstill,until the battery is charged again. This means
  391.             that the robot must issue a 'move' command to start the
  392.             robot moving again.
  393.  
  394.             Battery power may be traded to buy more shells, or more
  395.             armour.
  396.             Alternatively, armour may be traded to buy more battery
  397.             power.
  398.  
  399.             If a robot is destroyed, any battery power remaining is
  400.             transferred to the robot which dealt the death blow.
  401.  
  402.             Recharging Stations
  403.             ~~~~~~~~~~~~~~~~~~~~
  404.             A map may contain between 0 and 10 refueling stations where
  405.             robots can replenish their batteries.
  406.  
  407.             These refueling stations are simply large quick charging
  408.             batteries themselves. They recharge at a rate of 5 units per
  409.             turn, as long as no robot is currently being recharged from
  410.             them. Recharging units may not acquire more than 2000 units
  411.             of charge.
  412.  
  413.             A robot must be stationary and visible on a refueling
  414.             station in order to recharge its batteries. It will take 10
  415.             units of charge from the refueling station as long as there
  416.             is sufficient charge in the refueling station's batteries.
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.  
  426.  
  427.  
  428.  
  429.  
  430.  
  431.  
  432.             ============================================================
  433.                                                                Page No 7
  434.  
  435.  
  436.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  437.             ============================================================
  438.  
  439.             Robot Configuration
  440.             ~~~~~~~~~~~~~~~~~~~~
  441.  
  442.             Robots may now be customised to suit a specific task, you do
  443.             this by calling the configure routine, with the appropriate
  444.             parameters.
  445.  
  446.             The configuration call *must* be the first call in the
  447.             program. If you do not call it, all the parameters will be
  448.             set to their '2' value in the table below.
  449.  
  450.             Value  Speed Manouevre Range Armour Acceleration
  451.               0      50     20%     300     50      5
  452.               1      75     35%     500     75      7
  453.               2     100     50%     700    100     10
  454.               3     150     75%    1000    150     15
  455.               4     200    100%    1500    200     20
  456.  
  457.             You have a maximum of 10 points to allocate to the robot. If
  458.             you try to allocate more points to the robot, some items
  459.             will have a value of '0'.
  460.  
  461.             It is also possible to buy an 'invisibility' device using
  462.             this function. Normally a robot will start with 1000 shells
  463.             at the beginning of a game. If you take the invisibility
  464.             device this will be reduced to 900 shells.
  465.  
  466.             Invisibility
  467.             ~~~~~~~~~~~~~
  468.  
  469.             Invisibility is a purely defensive system, and will be of
  470.             negligible use in a 'dumb' robot.
  471.  
  472.             When your robot goes invisible it will be undetectable by
  473.             other robots' scanners, however, shells landing in the
  474.             vicinity will still damage the robot.
  475.  
  476.             Also, invisibility places the following limitations on your
  477.             robot:
  478.  
  479.                  - Scanning is not possible
  480.                  - Firing the cannon is not possible
  481.                  - The battery will *NOT* be recharged while invisible
  482.  
  483.             The main use of invisibility would be to hide while running
  484.             to a safer location (to stop some 'chase' robots from
  485.             following you there). When there it would be possible to
  486.             become visible to recharge the batteries.
  487.  
  488.             When the robot is invisible an 'I' will appear next to the
  489.             robot's name.
  490.  
  491.             A robot can only stay invisible for a maximum of 100 turns,
  492.             it will then automatically become visible again. After a
  493.  
  494.  
  495.  
  496.             ============================================================
  497.                                                                Page No 8
  498.  
  499.  
  500.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  501.             ============================================================
  502.  
  503.             robot has become visible it must remain visible for as many
  504.             turns as it was invisible before it can turn invisible
  505.             again. Thus, if a robot was invisible for 50 turns, it must
  506.             be visible for at least 50 turns before it can go invisible
  507.             again.
  508.  
  509.             ROBOT DAMAGE
  510.             ~~~~~~~~~~~~~
  511.             When a robot collides with the outside of the arena, or is
  512.             hit by a shell then it is damaged. The values of damage are:
  513.  
  514.             Collision with edge of arena - 1 point
  515.             Explosion within 50 squares  - 2 points
  516.             Explosion within 25 squares  - 8 points
  517.             Explosion within 5 squares   - 25 points
  518.  
  519.             The explosion displayed on the screen has 3 coloured areas
  520.             corresponding to these radii: 50 squares is red, 25 squares
  521.             is yellow, and 5 squares is white.
  522.  
  523.             Debugging Aids
  524.             ~~~~~~~~~~~~~~~
  525.             There are several features to help you to debug robots.
  526.  
  527.             The most basic is the use of the 'debug flags'. These can
  528.             indicate certain 'modes' of operation of the robot, for
  529.             instance a robot may have a 'running' mode and an 'attack'
  530.             mode. A debug flag indicator could be used to let you see at
  531.             a glance which mode the robot is in.
  532.  
  533.             Writing to files is allowed during the debug stages of
  534.             writing a robot, but any code to do this should be removed
  535.             or disabled before allowing the robot out in public. Reading
  536.             from files is not allowed at any stage.
  537.  
  538.             It is also possible to send output to the 'stdout' file. In
  539.             C you do this by using any of the standard output routine
  540.             such as 'printf'. In Pascal you do it by using
  541.             WRITE/WRITELN, and in Assembler you simply send output to a
  542.             file with handle=1.
  543.  
  544.             This output will be ignored unless you give the '-s' or '-m'
  545.             options on the PCROBOTS command line.
  546.  
  547.             If you use '-m' the output will be displayed on an MDA
  548.             monitor attached to your PC in addition to the EGA/VGA
  549.             display. Don't use this option unless you have an MDA
  550.             adaptor fitted, as it may cause unpredictable results.
  551.  
  552.             If you use '-s' (without '-m') then the first 19 columns of
  553.             the output will be displayed in the right hand column of the
  554.             display (under the robot names and status indicators).
  555.  
  556.  
  557.  
  558.  
  559.  
  560.             ============================================================
  561.                                                                Page No 9
  562.  
  563.  
  564.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  565.             ============================================================
  566.  
  567.             The output drivers understand certain special characters:
  568.  
  569.                  \n = 0ah = 10 - Line feed - the print position goes
  570.                       down a line
  571.                  \r = 0dh = 13 - Carriage Return - the print position
  572.                       goes to the left hand side of the current line
  573.                  \b = 08h = 8  - Backspace - the print position goes
  574.                       back one space
  575.                  \f = 0ch = 12 - Formfeed - the screen is cleared and
  576.                       the print position goes to the start of the screen
  577.                  <Esc>Y<y><x> - This is the VT52 cursor position code. y
  578.                       and x are specified by using the character which
  579.                       has the ASCII character of the required position
  580.                       plus 32. 1,1 is the top left of the screen. Thus
  581.                       <esc>Y!! will move the cursor to the top left of
  582.                       the screen.
  583.  
  584.             Most standard cursor positioning command will also work (for
  585.             instance 'gotoxy(x,y)' in Turbo C).
  586.  
  587.             Special Keys
  588.             ~~~~~~~~~~~~~
  589.             If during operation you wish to stop a game, pressing ESC
  590.             will cause it to stop at the next movement turn.
  591.  
  592.             Pressing Ctrl-Brk will cause all the robots to be killed
  593.             instantly (even if one of them is stuck in an internal
  594.             loop), and the program will exit.
  595.  
  596.  
  597.  
  598.  
  599.  
  600.  
  601.  
  602.  
  603.  
  604.  
  605.  
  606.  
  607.  
  608.  
  609.  
  610.  
  611.  
  612.  
  613.  
  614.  
  615.  
  616.  
  617.  
  618.  
  619.  
  620.  
  621.  
  622.  
  623.  
  624.             ============================================================
  625.                                                               Page No 10
  626.  
  627.  
  628.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  629.             ============================================================
  630.  
  631.  
  632.             The ROBOT programs
  633.             ~~~~~~~~~~~~~~~~~~~
  634.             Each 'robot' program consists of a single .COM or small .EXE
  635.             file. These programs must obey certain rules for the program
  636.             to work correctly.
  637.  
  638.              - no standard I/O functions (such as printf) are allowed.
  639.  
  640.              - The program must *never* finish - the main program should
  641.             consist of an infinite loop. The PCRobots executive program
  642.             will kill the program when the robot is destroyed.
  643.  
  644.              - The program must not use any memory outside the 64k
  645.             segment which it is allocated.
  646.  
  647.              - The PSP is not completely created (and may be erroneous -
  648.             I have to create it in the PCRobots program, and it may not
  649.             match the proper definition - let me know if you find a
  650.             problem).
  651.              The sections which should be correct are:
  652.               - INT 20h
  653.               - Segment of end of allocation block
  654.               - Previous contents of ints 22,23,24
  655.               - Env block pointer (points to offset 0x90 of PSP which
  656.             contains a 00h,00h value).
  657.               - Command tail - contains 00h,0dh,00h.
  658.              The FCBs & Long call to function dispatcher aren't created.
  659.  
  660.              - Floating point maths are not allowed.
  661.  
  662.              - It must make sure that it always passes control back to
  663.             the executive program when it is idling.
  664.  
  665.             DOS Functions
  666.             ~~~~~~~~~~~~~~
  667.             In V1.3 onwards a lot of DOS functions are disabled to
  668.             prevent their use in robot programs (using certain functions
  669.             may be construed as 'cheating'). In V1.4 onwards, this
  670.             checking can be made more lenient by using a debugging
  671.             command line parameter.
  672.  
  673.             Basically all DOS functions will cause the robot to be
  674.             instantly killed, except for the following:
  675.  
  676.             AH=  9h - Display String (as normal)
  677.             AH= 25h - Set Int Vector (filtered)
  678.             AH= 2ah - Get date (as normal)
  679.             AH= 2bh - Set date (dummy - does nothing)
  680.             AH= 2ch - Get time (as normal)
  681.             AH= 2dh - Set time (dummy - does nothing)
  682.             AH= 30h - Get DOS Version (as normal)
  683.             AH= 35h - Get Int Vector (as normal)
  684.             AH= 40h - Write file or device (filtered)
  685.  
  686.  
  687.  
  688.             ============================================================
  689.                                                               Page No 11
  690.  
  691.  
  692.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  693.             ============================================================
  694.  
  695.             AH= 43h - Get/Set file attributes (as normal)
  696.             AH= 44h - I/O Ctl (as normal)
  697.             AH= 4ah - Resize memory block (redefined)
  698.  
  699.             Many of these are allowed so that compiler startup code can
  700.             operate properly.
  701.  
  702.             If you see a message such as
  703.             'killed by System Violation (4c00)' when PCRobots finishes,
  704.             then it means that a robot tried to call int 21h with AX set
  705.             to 4c00h.
  706.  
  707.             A couple of these functions are filtered or redefined. These
  708.             are:
  709.  
  710.             Set Int Vector
  711.             ===============
  712.             In this case all vector changes are ignored, except for
  713.             changes to int e0h (in which case the current robot is
  714.             instantly killed!), or int 34h -> int 3fh (in which case
  715.             alterations are made to a local interrupt vector table for
  716.             that task).
  717.  
  718.             Int e0h is also constantly being checked to prevent direct
  719.             tampering with the interrupt vector table.
  720.  
  721.             Write File or Device
  722.             =====================
  723.             Writes to stdout (file handle 1) are redirected to the
  724.             debugging output routines, other writes pass through as
  725.             normal.
  726.  
  727.             Resize Memory Block
  728.             ====================
  729.             DOS memory blocks are simulated by PCRobots to enforce a 64k
  730.             memory limit per robot. This is necessary for the EMS
  731.             operating mode.
  732.  
  733.             Robot Time Limit
  734.             ~~~~~~~~~~~~~~~~~
  735.             As of V1.3 a time limit is enforced for a move by a robot.
  736.             This time limit adjusts for the speed of the computer, and
  737.             should be around 3 seconds on a 33MHz 386.
  738.  
  739.             This time limit is not meant to seriously limit robots, it
  740.             is merely meant as a protection against robots getting stuck
  741.             in a loop like:
  742.  
  743.              do
  744.              {
  745.               getxy(&x,&y);
  746.              }
  747.              while (x>100);
  748.  
  749.  
  750.  
  751.  
  752.             ============================================================
  753.                                                               Page No 12
  754.  
  755.  
  756.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  757.             ============================================================
  758.  
  759.             Special Functions
  760.             ~~~~~~~~~~~~~~~~~~
  761.             Special 'robot' functions such as movement, scanning,
  762.             statusreports etc, are accessed by using software interrupt
  763.             0E0h.
  764.  
  765.             The function number is placed in the AX register, and
  766.             anyrequired parameters are placed in the BX & CX registers.
  767.             Values are returned in these registers as appropriate.
  768.  
  769.             Function numbers less than 10h cause a task switch to occur.
  770.             This will end the current robot's 'turn' and give the next
  771.             robot a chance.
  772.  
  773.             There are several methods of using the special robot
  774.             functions. These are for Assembler language, C/C++, Turbo
  775.             Pascal and BASIC. There is a section on each of these below,
  776.             C/C++/Pascal/BASIC are all included together as they are
  777.             very similar to use.
  778.  
  779.             C, C++, Pascal and BASIC Functions
  780.             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  781.  
  782.             For C and C++ there are two methods of using these
  783.             functions, via PCROBOTS.LIB or via PCROBOTS.OBJ.
  784.             PCROBOTS.LIB is a Borland Library, so it may not work with
  785.             non-Borland languages, whereas PCROBOTS.OBJ is a standard
  786.             .OBJ file, so it should work with any language which can
  787.             link an object file with the C parameter passing protocol.
  788.  
  789.             To use either of these routine you should
  790.             '#include "pcrobots.h" ' in your C/C++ program. The source
  791.             code for the library is supplied in PCROBOTS.C.
  792.  
  793.             For Turbo Pascal you can use the PCROBOTS.TPU unit. This was
  794.             compiled with Turbo Pascal V5.5, but it should work with
  795.             other versions of Turbo Pascal.
  796.  
  797.             Add 'uses pcrobots;' to your source code.
  798.  
  799.             For BASIC you should '$include: 'pcrobots.bi' in your BASIC
  800.             program. You should also compile pcrobots.bas for linking
  801.             with the object file from your program. You must also
  802.             specify QBX.LIB (MS BASIC 7.1) or QB.LIB (MS Quick BASIC
  803.             4.5) when linking.
  804.  
  805.  
  806.  
  807.  
  808.  
  809.  
  810.  
  811.  
  812.  
  813.  
  814.  
  815.  
  816.             ============================================================
  817.                                                               Page No 13
  818.  
  819.  
  820.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  821.             ============================================================
  822.  
  823.             Function names
  824.             ~~~~~~~~~~~~~~~
  825.  
  826.             void swaptask(void);
  827.             procedure swaptask;
  828.             declare sub SwapTask ()
  829.             =======================
  830.  
  831.                  This procedure will simply end the current robot's turn
  832.                  if it has nothing else to do. Use this if, for
  833.                  instance, you're waiting for the robot to move to a
  834.                  certain location.
  835.  
  836.             void movement(int speed, int angle);
  837.             procedure movement(speed,angle:integer);
  838.             declare sub Movement (byval Fast%, byval Angle%)
  839.             ================================================
  840.  
  841.                  This procedure will cause the robot to start moving in
  842.                  the specified direction at the specified speed.
  843.  
  844.                  speed = 0 - max speed of robot (<=200)
  845.                  angle = 0 - 359 degrees
  846.  
  847.                  The speed will change to the target speed at the
  848.                  maximum acceleration rate specified for this robot.
  849.  
  850.                  If the robot is going above its manouvrability speed,
  851.                  then it will not be able to change direction. It must
  852.                  slow down first.
  853.  
  854.                  This procedure will cause the current robot's turn to
  855.                  end.
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.  
  863.  
  864.  
  865.  
  866.  
  867.  
  868.  
  869.  
  870.  
  871.  
  872.  
  873.  
  874.  
  875.  
  876.  
  877.  
  878.  
  879.  
  880.             ============================================================
  881.                                                               Page No 14
  882.  
  883.  
  884.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  885.             ============================================================
  886.  
  887.             int scan(int angle,int res,int *range);
  888.             Function scan(angle,res:integer;var range:integer):integer;
  889.             declare function Scan (byval Angle%,byval Res%, Range%)
  890.             ===========================================================
  891.  
  892.                  This function will cause the robot to scan for other
  893.                  robots in the specified direction.
  894.  
  895.                  angle = 0 - 359 degrees
  896.                  res   = 0 - 45 degrees
  897.  
  898.                  returns the id number of the robot which was detected,
  899.                  or -1 if no robot was detected.
  900.  
  901.                  The range value is set to the range to the detected
  902.                  robot, if no robot was detected, the range is
  903.                  unspecified.
  904.  
  905.                  The scan function will scan along a specified direction
  906.                  with the specified resolution. For instance a
  907.                  scan(300,5,....) will look at the angles from 295
  908.                  degrees to 305 degrees.
  909.  
  910.                  This function will cause the current robot's turn to
  911.                  end.
  912.  
  913.  
  914.  
  915.  
  916.  
  917.  
  918.  
  919.  
  920.  
  921.  
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.  
  929.  
  930.  
  931.  
  932.  
  933.  
  934.  
  935.  
  936.  
  937.  
  938.  
  939.  
  940.  
  941.  
  942.  
  943.  
  944.             ============================================================
  945.                                                               Page No 15
  946.  
  947.  
  948.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  949.             ============================================================
  950.  
  951.             int shoot(int angle,int range);
  952.             Function shoot(angle,range:integer):integer;
  953.             declare function Shoot% (byval Angle%, byval Range%)
  954.             ====================================================
  955.  
  956.                  This function causes the robot to fire a shell in the
  957.                  specified direction for the specified range. The shell
  958.                  will be fired into the air, so it will not hit any
  959.                  targets before the range is reached.
  960.  
  961.                  angle = 0 - 359 degrees
  962.                  range = 0 - max range of robot's cannon
  963.  
  964.                  if the robot was able to fire a shell then the function
  965.                  will return the shell's Id value (used with the
  966.                  'get_ashell_status' function, if it was unable to fire
  967.                  a shell for any reason, then it will return 0.
  968.  
  969.                  The robot's turret is independant of the robot's
  970.                  heading, so shells can be fired in any direction.
  971.  
  972.                  Seven shells per robot are allowed in the air at once.
  973.                  Also, the cannon takes 50 ticks to reload.
  974.  
  975.                  The robot normally starts with only 1000 shells, if
  976.                  these all run out (very unusual!), then the robot will
  977.                  be unable to fire its cannon, unless it purchases more
  978.                  shells (see 'buy_shells' function).
  979.  
  980.                  This function will cause the current robot's turn to
  981.                  end.
  982.  
  983.             void getxy(int near *x,int near *y);
  984.             procedure getxy(var x,y:integer);
  985.             declare sub GetXY (X%, Y%)
  986.             =================================
  987.  
  988.                  This function will return the current position of the
  989.                  robot.
  990.  
  991.                  The x and y coordinates of the robots are returned in
  992.                  the x and y parameters (possible values are 0 - 999).
  993.  
  994.  
  995.  
  996.  
  997.  
  998.  
  999.  
  1000.  
  1001.  
  1002.  
  1003.  
  1004.  
  1005.  
  1006.  
  1007.  
  1008.             ============================================================
  1009.                                                               Page No 16
  1010.  
  1011.  
  1012.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1013.             ============================================================
  1014.  
  1015.             int transmit(int target,int data);
  1016.             function transmit(target,data:integer):integer;
  1017.             declare function Transmit% (byval Target%, byval Message%)
  1018.             ==========================================================
  1019.  
  1020.                  This function will transmit the specified data to the
  1021.                  specified robot.
  1022.  
  1023.                  target = target robot id - as obtained from the scan
  1024.                            function.
  1025.                  data   = data word to send to the robot.
  1026.  
  1027.                  If the data could not be sent for any reason, the
  1028.                  function will return 0, otherwise it will return 1.
  1029.  
  1030.                  It costs one battery unit to transmit a word of data.
  1031.  
  1032.                  Robots have a 20 word FIFO receive queue where received
  1033.                  data is stored until it is read. If this buffer is
  1034.                  full, or the target robot does not exist, then this
  1035.                  function will return a 0. Success of the call does
  1036.                  *not* mean that the target robot has actually looked at
  1037.                  the received data.
  1038.  
  1039.             int receive(int *source,int *data);
  1040.             function receive(var source,data:integer):integer;
  1041.             declare function Receive% (Source%, Message%)
  1042.             ==================================================
  1043.  
  1044.                  This function allows a robot to see if any data has
  1045.                  been sent to it by another robot.
  1046.  
  1047.                  The function will return 1 if data exists, or 0 if the
  1048.                  receive buffer is empty.
  1049.  
  1050.                  If data exists, then source will be set to the id
  1051.                  number of the sending robot, and data will be set to
  1052.                  the data which was sent.
  1053.  
  1054.                  If the receive buffer was empty, then source and data
  1055.                  will be undefined.
  1056.  
  1057.                  Because this function does not cause the current
  1058.                  robot's turn to end, it is recommended that this
  1059.                  function is called periodicallyto clear up the robot's
  1060.                  input buffer, even if the data is subsequently ignored.
  1061.  
  1062.  
  1063.  
  1064.  
  1065.  
  1066.  
  1067.  
  1068.  
  1069.  
  1070.  
  1071.  
  1072.             ============================================================
  1073.                                                               Page No 17
  1074.  
  1075.  
  1076.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1077.             ============================================================
  1078.  
  1079.             int damage(void);
  1080.             function damage:integer;
  1081.             declare function Damage% ()
  1082.             ===========================
  1083.  
  1084.                  This function will return the current damage status of
  1085.                  the robot.
  1086.  
  1087.                  The lower the value, the more damaged the robot is. The
  1088.                  initial value depends on the robot's configuration, but
  1089.                  is normally 100.
  1090.  
  1091.             int speed(void);
  1092.             function speed:integer;
  1093.             declare function Speed% ()
  1094.             ==========================
  1095.  
  1096.                  This function will return the current speed of the
  1097.                  robot.
  1098.  
  1099.  
  1100.             int battery(void);
  1101.             function battery:integer;
  1102.             declare function battery% ()
  1103.             ============================
  1104.  
  1105.                  This function will return the current status of the
  1106.                  battery.
  1107.  
  1108.             long ticks(void);
  1109.             function ticks:longint;
  1110.             declare function Ticks& ()
  1111.             ==========================
  1112.  
  1113.                  This function will return the number of game ticks
  1114.                  since the beginning of the game. This is not related to
  1115.                  real time, just the number of complete turns that have
  1116.                  elapsed.
  1117.  
  1118.             long l_sin(int angle);
  1119.             function l_sin(angle:integer):longint;
  1120.             declare function lSin& (byval Angle%)
  1121.             ======================================
  1122.  
  1123.                  This function will return the sine of the requested
  1124.                  angle, scaled up by a factor of 100,000.
  1125.  
  1126.                  angle = 0 - 359
  1127.  
  1128.                  This function is supported because it is not advisable
  1129.                  to use floating point numbers in the robot programs.
  1130.                  Scaled integer values should be used instead.
  1131.  
  1132.  
  1133.  
  1134.  
  1135.  
  1136.             ============================================================
  1137.                                                               Page No 18
  1138.  
  1139.  
  1140.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1141.             ============================================================
  1142.  
  1143.             long l_cos(int angle);
  1144.             function l_cos(angle:integer):longint;
  1145.             declare function lCos& (byval Angle%)
  1146.             ======================================
  1147.  
  1148.                  This function will return the cosine of the requested
  1149.                  angle, scaled up by a factor of 100,000.
  1150.  
  1151.                  angle = 0 - 359
  1152.  
  1153.                  This function is supported because it is not advisable
  1154.                  to use floating point numbers in the robot programs.
  1155.                  Scaled integer values should be used instead.
  1156.  
  1157.             long l_tan(int angle);
  1158.             function l_tan(angle:integer):longint;
  1159.             declare function lTan& (byval Angle%)
  1160.             ======================================
  1161.  
  1162.                  This function will return the tangent of the requested
  1163.                  angle, scaled up by a factor of 100,000.
  1164.  
  1165.                  angle = 0 - 359
  1166.  
  1167.                  This function is supported because it is not advisable
  1168.                  to use floating point numbers in the robot programs.
  1169.                  Scaled integer values should be used instead.
  1170.  
  1171.             int l_atan(long ratio);
  1172.             function l_atan(ratio:longint):integer;
  1173.             declare function lAtan% (byval Ratio&)
  1174.             =======================================
  1175.  
  1176.                  This function will return the arctangent of the
  1177.                  requested value.
  1178.  
  1179.                  The value should be scaled up by 100,000 times.
  1180.  
  1181.                  The return value is the angle in the range -90 degrees
  1182.                  to +90 degrees.
  1183.  
  1184.             long l_sqrt(long square);
  1185.             function l_sqrt(square:longint):longint;
  1186.             declare function lSqrt& (byval Value&)
  1187.             ========================================
  1188.  
  1189.                  This function will return the square root of a number.
  1190.  
  1191.  
  1192.  
  1193.  
  1194.  
  1195.  
  1196.  
  1197.  
  1198.  
  1199.  
  1200.             ============================================================
  1201.                                                               Page No 19
  1202.  
  1203.  
  1204.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1205.             ============================================================
  1206.  
  1207.  
  1208.             void set_pattern(const char far *pattern);
  1209.             procedure set_pattern(Buffer:Patbuf_ptr);
  1210.             declare sub SetPattern (Pattern$)
  1211.             ==========================================
  1212.  
  1213.                  This procedure will set the current pattern used to
  1214.                  draw the robot on the display.
  1215.  
  1216.                  C/C++
  1217.                  ======
  1218.                  The pattern array should consist of 5 bytes. The lower
  1219.                  5 bits of each byte will be used as a bit pattern for
  1220.                  the appropriate line of the robot's icon.
  1221.  
  1222.                  PASCAL
  1223.                  =======
  1224.  
  1225.                  There are 2 type definitions:
  1226.  
  1227.                  Pattern_buffer=array[0..5] of shortint;
  1228.                  Patbuf_ptr=^Pattern_buffer;
  1229.  
  1230.                  Pattern_buffer should be filled with 5 bytes. The lower
  1231.                  5 bits of each byte will be used as a bit pattern for
  1232.                  the appropriate line of the robot's icon.
  1233.  
  1234.                  The pointer value of this array should be used as the
  1235.                  parameter to the procedure call.
  1236.  
  1237.                  BASIC
  1238.                  ======
  1239.                  The pattern is a string of 5 characters
  1240.  
  1241.                  dim Pattern as string * 5
  1242.  
  1243.                  Only the least significant 5 bits of the ASCII values
  1244.                  of each character will be used.
  1245.  
  1246.             void debug_flag(int flag_no,int flag_set);
  1247.             procedure debug_flag(flag_no,flag_set:integer);
  1248.             declare sub DebugFlag (byval Flag%, byval Setting%)
  1249.             ===================================================
  1250.  
  1251.                  This procedure allows you to set or clear two flag
  1252.                  markers by the side of the robot's name down the right
  1253.                  hand side of the screen.
  1254.  
  1255.                  flag_no = 0 or 1
  1256.                  flag_set= 0 or 1
  1257.  
  1258.                  These two flags may be used for whatever purpose you
  1259.                  want, but they are often useful for debugging purposes.
  1260.  
  1261.  
  1262.  
  1263.  
  1264.             ============================================================
  1265.                                                               Page No 20
  1266.  
  1267.  
  1268.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1269.             ============================================================
  1270.  
  1271.             void buy_armour(int units);
  1272.             procedure buy_armour(units:integer);
  1273.             declare sub BuyArmour (byval Units%)
  1274.             ====================================
  1275.  
  1276.                  This procedure lets your robot buy or sell armour.
  1277.  
  1278.                  units = number of units to buy.
  1279.  
  1280.                  If 'units' is negative, then armour will be sold.
  1281.  
  1282.                  Armour units currently are worth 50 battery units, so
  1283.                  if a robot has a high battery charge it is possible to
  1284.                  sell some units to repair damaged armour. Also, if a
  1285.                  robot needs some battery power, it can sell armour in
  1286.                  exchange for some more battery power.
  1287.  
  1288.                  The armour rating can not go above the robot's initial
  1289.                  armour rating, any extra purchased units will be
  1290.                  wasted.
  1291.  
  1292.                  NB. It is quite possible to commit suicide using this
  1293.                  call.
  1294.  
  1295.  
  1296.             void buy_shells(unsigned int units);
  1297.             procedure buy_shells(units:word);
  1298.             declare sub BuyShells (byval Shells%)
  1299.             =====================================
  1300.  
  1301.                  This procedure lets you purchase more cannon shells.
  1302.  
  1303.                  units = number of shells to buy.
  1304.  
  1305.                  It is not possible to sell shells in exchange for
  1306.                  battery power. Shells cost 10 battery units each.
  1307.  
  1308.             int shells_left(void);
  1309.             function shells_left:integer;
  1310.             declare function ShellsLeft% ()
  1311.             ===============================
  1312.  
  1313.                  This function lets your robot determine how many cannon
  1314.                  shells it has remaining.
  1315.  
  1316.                  Returns the number of shells remaining.
  1317.  
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324.  
  1325.  
  1326.  
  1327.  
  1328.             ============================================================
  1329.                                                               Page No 21
  1330.  
  1331.  
  1332.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1333.             ============================================================
  1334.  
  1335.             void get_local_map(char far *buffer);
  1336.             procedure get_local_map(ptr:MapBuf_ptr);
  1337.             declare sub GetLocalMap (Buffer$)
  1338.             ========================================
  1339.  
  1340.                  This procedure lets you obtain a map of the area local
  1341.                  to the robot. You will receive a 9x9 square map of the
  1342.                  local area, the robot's current position will be in the
  1343.                  centre square of the map. See the section on the map
  1344.                  for details of the contents of the map.
  1345.  
  1346.                  C/C++
  1347.                  ======
  1348.                  The map array should be 81 bytes long.
  1349.  
  1350.                  PASCAL
  1351.                  =======
  1352.  
  1353.                  There are 2 type definitions:
  1354.  
  1355.                  Map_buffer=array[0..8,0..8] of shortint;
  1356.                  Mapbuf_ptr=^Map_buffer;
  1357.  
  1358.                  Pass the pointer to a type of Map_buffer to the
  1359.                  procedure.
  1360.  
  1361.                  BASIC
  1362.                  ======
  1363.                  The procedure will return with Buffer$ containing a
  1364.                  string 81 characters long.
  1365.  
  1366.             void invisibility(int invis_flag);
  1367.             procedure invisibility(invis_flag:integer);
  1368.             declare sub Invisibility (byval InvisFlag%)
  1369.             ===========================================
  1370.  
  1371.                  This procedure allow the robot to become invisible or
  1372.                  visible.
  1373.  
  1374.                  invis_flag = 0 - robot is visible,
  1375.                             = 1 - robot is invisible.
  1376.  
  1377.                  If the robot isn't capable of becoming invisible, then
  1378.                  this procedure will do nothing.
  1379.  
  1380.  
  1381.  
  1382.  
  1383.  
  1384.  
  1385.  
  1386.  
  1387.  
  1388.  
  1389.  
  1390.  
  1391.  
  1392.             ============================================================
  1393.                                                               Page No 22
  1394.  
  1395.  
  1396.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1397.             ============================================================
  1398.  
  1399.             int get_shell_status(void);
  1400.             function get_shell_status:integer;
  1401.             declare function GetShellStatus% ()
  1402.             ===================================
  1403.  
  1404.                  This function will return a status value reporting what
  1405.                  happened to the last shell to land.
  1406.  
  1407.                  Return value:  0 - shell missed totally
  1408.                                 1 - shell hit a wall
  1409.                                 2 - shell hit a robot within a 50 square
  1410.                                      radius
  1411.                                 3 - shell hit a robot within a 25 square
  1412.                                      radius
  1413.                                 4 - shell hit a robot within a 5 square
  1414.                                      radius
  1415.  
  1416.                  This can be useful to see if a shell is firing at a
  1417.                  robot which is hiding behind a wall.
  1418.  
  1419.             int isinvisible(void);
  1420.             function isinvisible:integer;
  1421.             declare function IsInvisible% ()
  1422.             ================================
  1423.  
  1424.                  This function will return a flag indicating whether the
  1425.                  robot is invisible or not.
  1426.  
  1427.                  Return value:  0 - robot is visible,
  1428.                                 1 - robot is invisible.
  1429.  
  1430.             int l_atan2(int y,int x);
  1431.             function L_atan2(y,x:integer):integer;
  1432.             declare function lAtan2% (byval Y%, byval X%)
  1433.             =============================================
  1434.  
  1435.                  This function will return the arctangent of y/x, giving
  1436.                  the correct value even if x is near 0. If both x and y
  1437.                  are 0, then this function will return 0.
  1438.  
  1439.             int get_robot_id(void);
  1440.             function get_robot_id:integer;
  1441.             declare function GetRobotId% ()
  1442.             ===============================
  1443.  
  1444.                  This function will return the robot ID of the current
  1445.                  robot.
  1446.  
  1447.  
  1448.  
  1449.  
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456.             ============================================================
  1457.                                                               Page No 23
  1458.  
  1459.  
  1460.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1461.             ============================================================
  1462.  
  1463.             void register_iff(char far *iff_string);
  1464.             declare sub RegisterIFF (IFFname$)
  1465.             =============================================
  1466.  
  1467.                  This function will inform PCRobots of the 'IFF' string
  1468.                  for this particular robot. The IFF string may only be
  1469.                  set once.
  1470.  
  1471.                  The 'iff_string' parameter is a C format zero-
  1472.                  terminated string.
  1473.  
  1474.             int check_iff;(int id);
  1475.             function check_iff(id:integer):integer;
  1476.             declare function CheckIFF% (byval Id%)
  1477.             =======================================
  1478.  
  1479.                  This function will check to see if the robot with id
  1480.                  'id' has the same 'IFF' string as the current robot. It
  1481.                  will return 1 if the strings match, or 0 otherwise.
  1482.  
  1483.             void register_name(char far *name_string);
  1484.             declare sub RegisterName (rName$)
  1485.             ==============================================
  1486.  
  1487.                  This function will inform PCRobots of the name of this
  1488.                  robot. The name may only be set once.
  1489.  
  1490.                  The 'name_string' parameter is a C format zero-
  1491.                  terminated string.
  1492.  
  1493.             int find_name(int id,char far *name_string);
  1494.             ddeclare function FindName% (byval StartId%, Name$)
  1495.             ==================================================
  1496.  
  1497.                  This function will search for a specified name. The
  1498.                  search will start at 'id' and end when there are no
  1499.                  more robots to check.
  1500.  
  1501.                  If no robot is found, it will return -1, otherwise it
  1502.                  will return the robot id.
  1503.  
  1504.                  The 'name_string' parameter is a C format zero-
  1505.                  terminated string.
  1506.  
  1507.             int get_team_id(void);
  1508.             function get_team_id:integer;
  1509.             declare function GetTeamId% ()
  1510.             ==============================
  1511.  
  1512.                  This function will return the team which the current
  1513.                  robot is on. -1 will be returned if it is a 'loner',
  1514.                  otherwise the team number (0-2) will be returned.
  1515.  
  1516.  
  1517.  
  1518.  
  1519.  
  1520.             ============================================================
  1521.                                                               Page No 24
  1522.  
  1523.  
  1524.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1525.             ============================================================
  1526.  
  1527.             int get_ashell_status(int shellid);
  1528.             function get_ashell_status(ShellId:integer):integer;
  1529.             ====================================================
  1530.  
  1531.                  This function will return the status of a shell which
  1532.                  was fired in the past. Only the 10 most recent shells
  1533.                  are remembered (including those currently in flight).
  1534.  
  1535.                  The return value is similar to that obtained from
  1536.                  'get_shell_status', but with these extra possibilities:
  1537.  
  1538.                       5 - The shell is unknown (it hasn't been fired
  1539.                  yet, or it is more than 10 shells old).
  1540.                       6 - The shell is still in flight
  1541.  
  1542.                  The shellid value is obtained from the 'shoot'
  1543.                  function.
  1544.  
  1545.             int register_x(int *X);
  1546.             function register_x(X:Int_ptr):integer;
  1547.             =======================================
  1548.  
  1549.                  This function sets up a memory area to receive
  1550.                  automatically updated reports of the robot's current x
  1551.                  coordinate (this saves having to constantly use the
  1552.                  'getxy' function).
  1553.  
  1554.                  The return value is 1 if it was carried out OK,
  1555.                  otherwise it is 0 (possible problems are if the address
  1556.                  of X is not in the robot's valid address space).
  1557.  
  1558.             int (int *Y);
  1559.             function register_y(Y:Int_ptr):integer;
  1560.             =======================================
  1561.  
  1562.                  This function sets up a memory area to receive
  1563.                  automatically updated reports of the robot's current y
  1564.                  coordinate (this saves having to constantly use the
  1565.                  'getxy' function).
  1566.  
  1567.                  The return value is 1 if it was carried out OK,
  1568.                  otherwise it is 0 (possible problems are if the address
  1569.                  of Y is not in the robot's valid address space).
  1570.  
  1571.  
  1572.  
  1573.  
  1574.  
  1575.  
  1576.  
  1577.  
  1578.  
  1579.  
  1580.  
  1581.  
  1582.  
  1583.  
  1584.             ============================================================
  1585.                                                               Page No 25
  1586.  
  1587.  
  1588.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1589.             ============================================================
  1590.  
  1591.             int configure(int speed,int manouevre,int range,int
  1592.                            armour,int acceleration,int invisibility);
  1593.             function configure(speed,manouevre,range, armour,
  1594.                            acceleration,invisibility:integer):integer;
  1595.             declare function Configure% (byval Fast%, byval Manouevre%,
  1596.                            byval Range%, byval Armour%, byval
  1597.                            Acceleration, byval Invisible%)
  1598.             ==========================================================
  1599.  
  1600.                  This function allows you to configure the robot to suit
  1601.                  the program. It *must* be called as the first thing in
  1602.                  the program.
  1603.  
  1604.                  For values of the parameters, look at the 'robot
  1605.                  configuration' section.
  1606.  
  1607.                  This function returns 0 if it was not the first
  1608.                  PCRobots call in the program (in which case it was
  1609.                  ignored).
  1610.  
  1611.                  If this function was called as the first thing in the
  1612.                  program, then it will return the PCRobots version
  1613.                  number in the two bytes of the return value. The high
  1614.                  byte will be the 'major' version number, and the low
  1615.                  byte will be the 'minor' version number. For instance
  1616.                  V1.30 will return 0x0130.
  1617.  
  1618.  
  1619.  
  1620.  
  1621.  
  1622.  
  1623.  
  1624.  
  1625.  
  1626.  
  1627.  
  1628.  
  1629.  
  1630.  
  1631.  
  1632.  
  1633.  
  1634.  
  1635.  
  1636.  
  1637.  
  1638.  
  1639.  
  1640.  
  1641.  
  1642.  
  1643.  
  1644.  
  1645.  
  1646.  
  1647.  
  1648.             ============================================================
  1649.                                                               Page No 26
  1650.  
  1651.  
  1652.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1653.             ============================================================
  1654.  
  1655.             Assembler functions
  1656.             ~~~~~~~~~~~~~~~~~~~~
  1657.  
  1658.             An 8086 assembler program will normally call the functions
  1659.             directly, via an INT 0E0h software interrupt.
  1660.  
  1661.             The details below specify what parameters to place in which
  1662.             registers, and what the returned values are.
  1663.  
  1664.             Look at the C/C++ and Pascal functions above for
  1665.             descriptions of the functions themselves.
  1666.  
  1667.             The PCROBOTS.INC file may be used to specify t
  1668.             he values to place in AX.
  1669.  
  1670.             SWAPTASK
  1671.             ========
  1672.  
  1673.             Call with:     AX = 00
  1674.  
  1675.             MOVEMENT
  1676.             ========
  1677.  
  1678.             Call with:     AX = 01
  1679.                            BX = speed 0-100
  1680.                            CX = direction 0-359
  1681.  
  1682.             SCAN
  1683.             =====
  1684.  
  1685.             Call with:     AX = 02
  1686.                            BX = direction 0-359 degrees
  1687.                            CX = resolution 0-45 degrees
  1688.  
  1689.             Returns value  AX = -1 if nothing detected
  1690.                               = robot id if a robot is detected
  1691.                                 (robot id's are 0-19)
  1692.                            BX = range to the detected robot.
  1693.  
  1694.             SHOOT
  1695.             ======
  1696.  
  1697.             Call with:     AX = 03
  1698.                            BX = direction 0-359
  1699.                            CX = range 0-700
  1700.  
  1701.             Returns value in AX = 1 if shell fired, 0 otherwise.
  1702.  
  1703.  
  1704.  
  1705.  
  1706.  
  1707.  
  1708.  
  1709.  
  1710.  
  1711.  
  1712.             ============================================================
  1713.                                                               Page No 27
  1714.  
  1715.  
  1716.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1717.             ============================================================
  1718.  
  1719.             GETXY
  1720.             ======
  1721.  
  1722.             Call with:     AX = 10h
  1723.  
  1724.             Returns values BX = Current X coordinate (0-999)
  1725.                            CX = Current Y coordinate (0-999)
  1726.  
  1727.             TRANSMIT
  1728.             =========
  1729.  
  1730.             Call with:     AX = 11h
  1731.                            BX = target robot ID
  1732.                            CX = data to be sent
  1733.  
  1734.             Returns value  AX = 0 if data could not be sent,
  1735.                               = 1 otherwise.
  1736.  
  1737.             RECEIVE
  1738.             ========
  1739.  
  1740.             Call with:     AX = 12h
  1741.  
  1742.             Returns values AX = 1 if data exists,
  1743.                               = 0 if the buffer is empty
  1744.                  If AX=1
  1745.                            BX = sender's ID ('reply to' address)
  1746.                            CX = data
  1747.  
  1748.             DAMAGE
  1749.             =======
  1750.  
  1751.             Call with:     AX = 13h
  1752.  
  1753.             Returns value  BX = damage status
  1754.  
  1755.             SPEED
  1756.             ======
  1757.  
  1758.             Call with:     AX = 14h
  1759.  
  1760.             Returns value  BX = current speed
  1761.  
  1762.             BATTERY
  1763.             ========
  1764.  
  1765.             Call with:     AX = 15h
  1766.  
  1767.             Returns value  BX = battery charge
  1768.  
  1769.  
  1770.  
  1771.  
  1772.  
  1773.  
  1774.  
  1775.  
  1776.             ============================================================
  1777.                                                               Page No 28
  1778.  
  1779.  
  1780.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1781.             ============================================================
  1782.  
  1783.             TICKS
  1784.             ======
  1785.  
  1786.             Call with:     AX = 16h
  1787.  
  1788.             Returns value  BX = Most significant 16 bits
  1789.                            CX = Least significant 16 bits
  1790.  
  1791.             L_SIN
  1792.             ======
  1793.  
  1794.             Call with:     AX = 17h
  1795.                            BX = angle (0-359 degrees)
  1796.  
  1797.             Returns value of 100,000 x the sine of the angle
  1798.                            BX = Most significant 16 bits
  1799.                            CX = Least significant 16 bits
  1800.  
  1801.             L_COS
  1802.             ======
  1803.  
  1804.             Call with:     AX = 18h
  1805.                            BX = angle (0-359 degrees)
  1806.  
  1807.             Returns value of 100,000 x the cosine of the angle
  1808.                            BX = Most significant 16 bits
  1809.                            CX = Least significant 16 bits
  1810.  
  1811.             L_TAN
  1812.             ======
  1813.  
  1814.             Call with:     AX = 19h
  1815.                            BX = angle (0-359 degrees)
  1816.  
  1817.             Returns value of 100,000 x the tangent of the angle
  1818.                            BX = Most significant 16 bits
  1819.                            CX = Least significant 16 bits
  1820.  
  1821.             L_ATAN
  1822.             =======
  1823.  
  1824.             Call with:     AX = 1Ah
  1825.                            BX = Most significant 16 bits
  1826.                            CX = Least significant 16 bits
  1827.  
  1828.             Returns value  AX = angle (-90 to +90 degrees)
  1829.  
  1830.                  The BX,CX parameters make up a 32 bit value that is
  1831.                  scaled up by 100,000. Hence a BX,CX of 100,000 will
  1832.                  return an angle of 45 degrees.
  1833.  
  1834.  
  1835.  
  1836.  
  1837.  
  1838.  
  1839.  
  1840.             ============================================================
  1841.                                                               Page No 29
  1842.  
  1843.  
  1844.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1845.             ============================================================
  1846.  
  1847.  
  1848.             SQRT
  1849.             =====
  1850.  
  1851.             Call with:     AX = 1Bh
  1852.                            BX = Most significant 16 bits of value
  1853.                            CX = Least significant 16 bits of value
  1854.  
  1855.             Returns value  BX = Most significant 16 bits of square root
  1856.                            CX = Least significant 16 bits
  1857.  
  1858.             SET_PATTERN
  1859.             ============
  1860.             his call will change the robot's displayed picture.
  1861.  
  1862.             Call with:     AX = 1Ch
  1863.                            BX = segment of pattern array
  1864.                            CX = offset of pattern array
  1865.  
  1866.             The pattern array should consist of 5 bytes. The lower 5
  1867.             bits of each byte are used as a bit pattern for the
  1868.             appropriate line of the robot's picture.
  1869.  
  1870.  
  1871.             DEBUG_FLAG
  1872.             ===========
  1873.  
  1874.             Call with:     AX = 1Dh
  1875.                            BX = flag number to set (0 or 1)
  1876.                            CX = set/reset flag (0=reset, 1=set)
  1877.  
  1878.             BUY ARMOUR
  1879.             ===========
  1880.  
  1881.             Call with:     AX = 1Eh
  1882.                            BX = number of armour units to buy.
  1883.  
  1884.             BUY SHELLS
  1885.             ===========
  1886.  
  1887.             Call with:     AX = 1Fh
  1888.                            BX = number of shells to buy
  1889.  
  1890.             SHELLS LEFT
  1891.             ============
  1892.  
  1893.             Call with:     AX = 20h
  1894.  
  1895.             Returns value  BX = number of shells remaining
  1896.  
  1897.  
  1898.  
  1899.  
  1900.  
  1901.  
  1902.  
  1903.  
  1904.             ============================================================
  1905.                                                               Page No 30
  1906.  
  1907.  
  1908.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1909.             ============================================================
  1910.  
  1911.             GET LOCAL MAP
  1912.             ==============
  1913.  
  1914.             Call with:     AX = 21h
  1915.                            BX = segment of map buffer
  1916.                            CX = offset of map buffer
  1917.  
  1918.                  The map buffer must be at least 81 bytes long, and will
  1919.                  be filled with a 9x9 area of the map, with the robot's
  1920.                  position in the centre.
  1921.  
  1922.             INVISIBILITY
  1923.             =============
  1924.  
  1925.             Call with:     AX = 22h
  1926.                            BX = 0 - become visible
  1927.                               = 1 - become invisible
  1928.  
  1929.              GET_SHELL_STATUS==================
  1930.  
  1931.             Call with:     AX = 23h
  1932.  
  1933.             Returns value  BX = 0 - shell missed totally
  1934.                                 1 - shell hit a wall
  1935.                                 2 - shell hit a robot within a 50 square
  1936.                                      radius
  1937.                                 3 - shell hit a robot within a 25 square
  1938.                                      radius
  1939.                                 4 - shell hit a robot within a 5 square
  1940.                                      radius
  1941.  
  1942.             IS_INVISIBLE
  1943.             =============
  1944.  
  1945.             Call with:     AX = 24h
  1946.  
  1947.             Returns value  BX = 0 - robot is visible
  1948.                                 1 - robot is invisible
  1949.  
  1950.             L_ATAN2
  1951.             ========
  1952.  
  1953.             Call with:     AX = 25h
  1954.                            BX = y
  1955.                            CX = x
  1956.  
  1957.             Returns value  AX = angle - arctangent of y/x.
  1958.  
  1959.  
  1960.  
  1961.  
  1962.  
  1963.  
  1964.  
  1965.  
  1966.  
  1967.  
  1968.             ============================================================
  1969.                                                               Page No 31
  1970.  
  1971.  
  1972.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  1973.             ============================================================
  1974.  
  1975.             GET_ROBOT_ID
  1976.             =============
  1977.  
  1978.             Call with:     AX = 26h
  1979.  
  1980.             Returns value  AX = robot id
  1981.  
  1982.             REGISTER_IFF
  1983.             =============
  1984.  
  1985.             Call with:     AX = 27h
  1986.                            BX = segment of iff_string
  1987.                            CX = offset of iff_string
  1988.                                 (string is zero terminated)
  1989.  
  1990.             CHECK_IFF
  1991.             ==========
  1992.  
  1993.             Call with:     AX = 28h
  1994.                            BX = Robot Id to test
  1995.  
  1996.             Returns value  AX = 1 - IFF strings match
  1997.                                 0 - IFF strings don't match (or invalid
  1998.                                      robot ID)
  1999.  
  2000.             REGISTER_NAME
  2001.             ==============
  2002.  
  2003.             Call with:     AX = 29h
  2004.                            BX = segment of name_string
  2005.                            CX = offset of name_string
  2006.                                 (string is zero terminated)
  2007.  
  2008.             FIND_NAME
  2009.             ==========
  2010.  
  2011.             Call with:     AX = 2Ah
  2012.                            BX = segment of name_string
  2013.                            CX = offset of name_string
  2014.                                 (string is zero terminated)
  2015.                            DX = Start ID
  2016.  
  2017.             Returns value  AX = Found Robot ID (-1 if no robot with that
  2018.                                 name)
  2019.  
  2020.             GET_TEAM_ID
  2021.             ============
  2022.  
  2023.             Call with:     AX = 2Bh
  2024.  
  2025.             Returns value  AX = Team ID value (0-2) or -1 if a 'loner'.
  2026.  
  2027.  
  2028.  
  2029.  
  2030.  
  2031.  
  2032.             ============================================================
  2033.                                                               Page No 32
  2034.  
  2035.  
  2036.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  2037.             ============================================================
  2038.  
  2039.             GET_ASHELL_STATUS
  2040.             ==================
  2041.  
  2042.             Call with:     AX = 2Ch
  2043.                            BX = Shell ID
  2044.  
  2045.             Returns value  AX = 0 - shell missed totally
  2046.                                 1 - shell hit a wall
  2047.                                 2 - shell hit a robot within a 50 square
  2048.                                      radius
  2049.                                 3 - shell hit a robot within a 25 square
  2050.                                      radius
  2051.                                 4 - shell hit a robot within a 5 square
  2052.                                      radius
  2053.                                 5 - shell is not known (not yet fired,
  2054.                                      or too old)
  2055.                                 6 - shell is still in flight
  2056.  
  2057.             REGISTER_X
  2058.             ===========
  2059.  
  2060.             Call with:     AX = 2Dh
  2061.                            BX = Segment of X word variable
  2062.                            CX = Offset of X word variable
  2063.  
  2064.             Returns value  AX = 0 - problem with address of X word
  2065.                               = 1 - OK
  2066.  
  2067.             REGISTER_Y
  2068.             ===========
  2069.  
  2070.             Call with:     AX = 2Eh
  2071.                            BX = Segment of Y word variable
  2072.                            CX = Offset of Y word variable
  2073.  
  2074.             Returns value  AX = 0 - problem with address of Y word
  2075.                               = 1 - OK
  2076.  
  2077.  
  2078.  
  2079.  
  2080.  
  2081.  
  2082.  
  2083.  
  2084.  
  2085.  
  2086.  
  2087.  
  2088.  
  2089.  
  2090.  
  2091.  
  2092.  
  2093.  
  2094.  
  2095.  
  2096.             ============================================================
  2097.                                                               Page No 33
  2098.  
  2099.  
  2100.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  2101.             ============================================================
  2102.  
  2103.             CONFIGURE
  2104.             ==========
  2105.  
  2106.             Call with:     AX = 80h
  2107.                            BX,CX = configuration details:
  2108.  
  2109.                            BX bits    0-3  = max speed
  2110.                                       4-7  = manouevrability
  2111.                                       8-11 = cannon range
  2112.                                      12-15 = robot armour
  2113.  
  2114.                            CX bits   0-2   = robot acceleration
  2115.                                      3     = invisiblity capability
  2116.  
  2117.             Returns value  AX = 1 - Configuration OK
  2118.                               = 0 - Call was not first thing in program
  2119.  
  2120.             Values of BX,CX bitmapped values:
  2121.  
  2122.             Value  Speed Manouevre Range Armour Acceleration
  2123.               0      50     20%     300     50      5
  2124.               1      75     35%     500     75      7
  2125.               2     100     50%     700    100     10
  2126.               3     150     75%    1000    150     15
  2127.               4     200    100%    1500    200     20
  2128.  
  2129.                  You have a maximum of 10 points to allocate to the
  2130.                  robot. If you try to allocate more points to the robot,
  2131.                  some items will have a value of '0'.
  2132.  
  2133.  
  2134.  
  2135.             ============================================================
  2136.  
  2137.  
  2138.  
  2139.  
  2140.  
  2141.  
  2142.  
  2143.  
  2144.  
  2145.  
  2146.  
  2147.  
  2148.  
  2149.  
  2150.  
  2151.  
  2152.  
  2153.  
  2154.  
  2155.  
  2156.  
  2157.  
  2158.  
  2159.  
  2160.             ============================================================
  2161.                                                               Page No 34
  2162.  
  2163.  
  2164.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  2165.             ============================================================
  2166.  
  2167.  
  2168.             Introduction                                           1
  2169.  
  2170.             Hardware Requirements                                  1
  2171.  
  2172.             How to run PCROBOTS                                    2
  2173.                  -d command line option                            2
  2174.                  -l command line option                            2
  2175.                  -f command line option                            2
  2176.                  -s command line option                            2
  2177.                  -q command line option                            2
  2178.                  -a command line option                            2
  2179.                  -m command line option                            3
  2180.                  -v command line option                            3
  2181.                  -r command line option                            3
  2182.                  -i command line option                            3
  2183.  
  2184.             Errorlevel values                                      3
  2185.  
  2186.             The PCROBOTS Arena                                     3
  2187.  
  2188.             The Robots                                             4
  2189.  
  2190.             Teams                                                  5
  2191.  
  2192.             Coordinates                                            5
  2193.  
  2194.             The Map                                                5
  2195.  
  2196.             Robot Batteries                                        7
  2197.  
  2198.             Recharging Stations                                    7
  2199.  
  2200.             Robot Configuration                                    8
  2201.  
  2202.             Invisibility                                           8
  2203.  
  2204.             ROBOT DAMAGE                                           9
  2205.  
  2206.             Debugging Aids                                         9
  2207.  
  2208.             Special Keys                                           10
  2209.  
  2210.             The ROBOT programs                                     11
  2211.  
  2212.             DOS Functions                                          11
  2213.  
  2214.             Robot Time Limit                                       12
  2215.  
  2216.             Special Functions                                      13
  2217.  
  2218.             C, C++, Pascal and BASIC Functions                     13
  2219.  
  2220.             Function names                                         14
  2221.  
  2222.  
  2223.  
  2224.  
  2225.  
  2226.                  swaptask                                          14
  2227.                  movement                                          14
  2228.                  scan                                              15
  2229.                  shoot                                             16
  2230.                  getxy                                             16
  2231.                  transmit                                          17
  2232.                  receive                                           17
  2233.                  damage                                            18
  2234.                  speed                                             18
  2235.                  battery                                           18
  2236.                  ticks                                             18
  2237.                  l_sin                                             18
  2238.                  l_cos                                             19
  2239.                  l_tan                                             19
  2240.                  l_atan                                            19
  2241.                  l_sqrt                                            19
  2242.                  set_pattern                                       20
  2243.                  debug_flag                                        20
  2244.                  buy_armour                                        21
  2245.                  buy_shells                                        21
  2246.                  shells_left                                       21
  2247.                  get_local_map                                     22
  2248.                  invisibility                                      22
  2249.                  get_shell_status                                  23
  2250.                  isinvisible                                       23
  2251.                  l_atan2                                           23
  2252.                  get_robot_id                                      23
  2253.                  register_iff                                      24
  2254.                  register_name                                     24
  2255.                  find_name(int id,char far *name_string);          24
  2256.                  get_team_id                                       24
  2257.                  get_ashell_status                                 25
  2258.                  register_x                                        25
  2259.                  register_y                                        25
  2260.                  configure                                         26
  2261.  
  2262.             Assembler functions                                    27
  2263.                  SWAPTASK                                          27
  2264.                  MOVEMENT                                          27
  2265.                  SCAN                                              27
  2266.                  SHOOT                                             27
  2267.                  GETXY                                             28
  2268.                  TRANSMIT                                          28
  2269.                  RECEIVE                                           28
  2270.                  DAMAGE                                            28
  2271.                  SPEED                                             28
  2272.                  BATTERY                                           28
  2273.                  TICKS                                             29
  2274.                  L_SIN                                             29
  2275.                  L_COS                                             29
  2276.                  L_TAN                                             29
  2277.                  L_ATAN                                            29
  2278.                  SQRT                                              30
  2279.                  SET_PATTERN                                       30
  2280.  
  2281.  
  2282.             PCROBOTS V1.41 - P.D.Smith 7 November, 1992
  2283.             ============================================================
  2284.  
  2285.                  DEBUG_FLAG                                        30
  2286.                  BUY ARMOUR                                        30
  2287.                  BUY SHELLS                                        30
  2288.                  SHELLS LEFT                                       30
  2289.                  GET LOCAL MAP                                     31
  2290.                  INVISIBILITY                                      31
  2291.                  GET_SHELL_STATUS                                  31
  2292.                  IS_INVISIBLE                                      31
  2293.                  L_ATAN2                                           31
  2294.                  GET_ROBOT_ID                                      32
  2295.                  REGISTER_IFF                                      32
  2296.                  CHECK_IFF                                         32
  2297.                  REGISTER_NAME                                     32
  2298.                  FIND_NAME                                         32
  2299.                  GET_TEAM_ID                                       32
  2300.                  GET_ASHELL_STATUS                                 33
  2301.                  REGISTER_X                                        33
  2302.                  REGISTER_Y                                        33
  2303.                  CONFIGURE                                         34