Animator ======== Introduction ------------ The Animator from Screenplay is a comprehensive graphics package which allows you to define and move a number of sprites on the screen. The program gives you the power to quickly and easily design your oown fast arcade-type games or other complex animation sequences. The package consists of two programs. The first of these is called the "Generator" and is used to define your characters. A second program called the "Animator" takes the output from the first program and produces a piece of machine code which will allow you to move these characters around the screen using either a Basic or machine code program. This manual describes each of these programs in turn and gives additional information on how the package can be used to create your own games. Loading The Programs -------------------- Either program can be loaded by typing the following command into your machine and, when loaded, will run automatically: CLOADM (ENTER) The "Generator" can be found on side A of the cassette and is followed by the Sprite definition pages for the demonstration program. The "Animator" can be found on side B of the cassette and is followed by the demonstration game and its associated machine code animation routines. Using The Sprite Generation Routine ----------------------------------- Sprites are created using the "Generator" program in the following manner: First, you need to define a grid, which will be used to design your sprite. Having defined the grid size, etc, the user-defined character can be created by setting points within the grid. The newly created sprite can then be manipulated using the commands listed in the next section of this manual. The sprites can then be saved on tape for processing using the "Animator" program which is the second part of this package. Installation Of Sprite Grid --------------------------- The "Generator" program allows you complete freedom in sprite definition. This is achieved in any colour mode by means of a user-defined grid. Each square on the grid represents a pixel on the high resolution graphics screen. Therefore to begin it is necessary to initialise the grid in the required mode, foreground and background colours, and in the size necessary for the sprite envisaged. The initialisation sequence requires the following information: 1. Colour mode (0-4) 2. Colour set (0-1) 3. Foreground colour (0-8) 4. Background colour (0-8) 5. Grid width 6. Grid height 7. Scale The maximum size of sprite that can be generated using the "Animator" depends on the mode selected and is described below. In modes 1, 3 and 4 the maximum size is 40 x 40 pixels, however in modes 0 and 2 the maximum size is 32 x 40 pixels. After the grid width, height, and scale have been entered you may be asked to supply amended information if the grid dimensions are out of range. (It is advised to use a lower scale if this is required.) Defining The Sprite Within The Grid ----------------------------------- "Generator" Operating Instructions ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Once the grid required has been generated, you are now in the position to begin a sprite definition. The flashing cursor is controlled by means of the arrow direction keys. If the cursor is moved off the grid it will "wrapround" and appear on the opposite site. This will be found very useful, allowing you to move rapidly to opposite sides of the grid. Setting A Point On The Grid ~~~~~~~~~~~~~~~~~~~~~~~~~~~ The cursor may be halted at any square position on the grid and that square may be filled in the foreground colour by pressing the Z key or, if you are in a four colour mode (i.e. modes 1 and 3) then the square may also be filled in a specific colour by pressing the Space Bar followed by the number code of the colour required, 0-8. 0 - Black 1 - Green 2 - Yellow 3 - Blue 4 - Red 5 - Buff 6 - Cyan 7 - Magenta 8 - Orange The actual colours that can be used will of course depend on the mode and colour set chosen. When a square on the grid is filled with a chosen colour, a point on the real size sprite image is PSET in a similar colour, the real size sprite image is shown to the lower right of the grid. Erasing Or Resetting A Point ~~~~~~~~~~~~~~~~~~~~~~~~~~~~ It is possible to rease a coloured ssquare on the grid by pressing the ENTER key, when the cursor is in the position required. This also resets the respective point on the real size sprite image back to the background colour. The entire grid may be cleared and the current real size sprite copy erased by pressing the CLEAR key. Amending The Sprite Design ~~~~~~~~~~~~~~~~~~~~~~~~~~ There are also a number of key options to allow grid and sprite copy manipulation. These options are listed and described below. Invert Sprite Colours ~~~~~~~~~~~~~~~~~~~~~ By pressing the I key the grid and sprite copy colours can be inverted from foreground colour on background colour to background colour on foreground colour. It should be noted that when operating in a four colour mode, this option is not available. Reflect Sprite ~~~~~~~~~~~~~~ By pressing the R key the grid and sprite copy may be reflected on either the horizontal or vertical axes. After pressing the R key, the V key should be pressed for reflection on the vertical axis and the H key should be pressed for reflection on the horizontal axis. Translate Sprite ~~~~~~~~~~~~~~~~ By pressing the T key the grid and sprite copy can be translated clockwise or anticlockwise. After pressing the T key the C key should be pressed for clockwise rotation or the A key should be pressed for anticlockwise rotation. It should be noted that in modes 2 and 3, i.e. modes in which the point size is non-uniform, this option is not available. Move Sprite Within Grid ~~~~~~~~~~~~~~~~~~~~~~~ By pressing the M key the grid and sprite copy may be scrolled upward, downward, left or right. After pressing the M key the U key should be pressed for an upward scroll. Similarly the D, L and R keys should then be pressed for downward, left and right scrolls respectively. Copy Sprite Definitions ~~~~~~~~~~~~~~~~~~~~~~~ A number of real size sprite copies (up to a maximum of six) may be stored along the top of the screen by pressing the C key. These copies are stored sequentially from left to right and need not be similar. They may also be deleted sequentially from right to left by pressing the D key. Saving And Loading The Sprite Definitions ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Pressing the S key will allow you to save a sprite definition page to cassette, once you have selected this function you will be asked to enter a filename for the page you wish to save. Press Play and Record keys on your cassette recorder and the machine will save the page to tape and return to the screen automatically. If your cassette recorder does not have a remote connection point there are delays before and after saving during which you will be prompted to press the Play and Record plus Stop switches. Loading Previously Defined Sprites ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Pressing the L key will allow you to load a previously saved sprite definition page from cassette, after you have selected this option you will be asked to enter the filename of the page you wish to reload. Press the Play switch on your cassette recorder and the machine will load the page automatically, again there are prompts before and after loading to assist this process. All variables from the time of saving the page will also be reloaded. This means that you will be in exactly the same position, in the same mode and colour set, and with the cursor at the exact same location you left it, when you continue after loading a page. In other words all the attributes of the saved page will be restored and these will override your current attributes. Help ~~~~ If you require a breakdown of the key functions that are available in your current mode then press the H key for a list of these options. Quit ~~~~ The final key is Q. This key quits the current sprite definition and takes you back to the initial menu. This may be used at any stage to change, mode, colour set, etc, if you have selected them incorrectly. However, be warned as it also clears the screen completely and restarts the program. After this key has been pressed the program will ask if you are sure you want to quit before returning to the initial display. Hint On Saving Sprites ~~~~~~~~~~~~~~~~~~~~~~ You are advised to save sprite definitions more than once in case of bad tape or saving problems. If you are using the Generator and you encounter input/output problems during reloading, simply type RUN and try again at a different volume setting. Formatting Sprite Definition Pages ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ So now you can define your own sprite images and save and load the definition pages to and from cassette. What about the animation? OK, let's discuss that... The Animator program also has the capability to load previously saved sprite definition pages. However, it is rather fussy on the format it requires from the Generator. There are two types of sprite available in the animation routine. Their functions will be discussed later in the Animator section of this manual. However, it is necessary to understand that a strict format is required in the generated sprite definition pages if the animation routine is to function properly. The first type of sprite is the "Principal" sprite, which is controlled automatically by the joystick or arrow or direction keys. This sprite requires two sprite definition pages, one each for horizontal and vertical movement. The horizontal movement requires three images for movement to the left and another three for movement to the right, thus a total of six images of the sprite need to be stored along the top of this page. These images are stored in the following sequence: Positions 1, 3 and 5 hold the first, second and third left-facing sprite images. Positions 2, 4 and 6 hold the first, second and third right-facing sprite images. This feature of the Animator allows you to change the shape of your principal sprite as it moves around the screen. Creating A Principal Sprite ~~~~~~~~~~~~~~~~~~~~~~~~~~~ Horizontal Page To define the principal sprite horizontal animation sequence the following sequence of instructions should be carried out. 1. Define the first left-facing image on the grid and store in the first position at the top of the page by pressing the C key. 2. Press the R and V keys to obtain the respective right-facing image and store this sprite copy at the second position on the page by pressing the C key. 3. Now press the R and V keys to return to the initial image, amend the image to image number 2 and repeat the sequence described above to store the left and right facing images in positions 3 and 4 at the top of the page. 4. Finally repeat the procedure for image number 3 and once again store the left and right facing images in positions 5 and 6 at the top of the page. You can now save the sprite definition to cassette by typing S on the keyboard. Note: Remember when saving more than once use the same filename. Vertical Page The vertical movement page requires only two sprite images, therefore, define the two images and store them in positions 1 and 2 at the top of the page. Press the S key and save the page to cassette. You may find it useful to use the same filename as you used for the horizontal animation page adding a V to the end of the name. This may avoid confusion when loading into the Animator program. You have now defined the two sprite definition pages necessary for complete principal sprite animation. However, if you wish your principal sprites movement to be restricted to one direction only then it is only necessary to define the appropriate sprite page. Creating A Secondary Sprite The second type of sprite is the "secondary" sprite. Eight different types of sprite can be loaded in the Animator program, each of which can be duplicated twice giving a total of 24 program driven sprites. A secondary sprite requires only one image which should be stored in position 1 at the top of the screen. The page can then be saved to tape using the S key. Using The Animator ------------------ Introduction ~~~~~~~~~~~~ The animation routine which is the product of this program is a 100% machine code program which has maximum flexibility when in use. The output from this program can be saved on tape and is the basis for your own games. The routine incorporates pixel accurate screen movement and uses the sprite images that you created using the Generator program. As previously mentioned there are two different types of sprite available in the animation routine. The Principal Sprite ~~~~~~~~~~~~~~~~~~~~ This sprite is unique and is automatically controlled by either the cursor control keys or the right hand joystick. Users will find that the speed of animation is slightly faster when the joystick option is selected. The following section contains detailed information concerning the use of several important memory locations. Sprite Movement Speed Flag (32472) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The principal sprite has pixel accurate screen movement and the speed of animation may be changed during animation by poking a value in the range 0-255 into this location. This address is a permanent flag and always holds the pixel distance between principal sprite positions on the screen. Sprite Movement Restriction Flag (32473) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ The principal sprite movement may also be restricted by poking a value into location 32473. Once again this is a permanent flag and is used to store the type of movement that the principal sprite is allowed to make. Value Type of movement 0 All directions 1 Horizontal only 2 Vertical only The contents of this location may be changed during animation to change the type of movement allowed. Principal Sprite On/Off Flag (32475) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ If this address holds the value 1, then the principal sprite will appear on the screen; if 0 is poked into this location then the principal sprite will disappear. Principal Sprite Location Flags (32476/32477) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Finally, these two addresses hold the horizontal and vertical screen co-ordinates of the top left hand pixel of the principal sprite. These addresses may be peeked at any time during the animation for collisions with either part of the screen or other sprite co-ordinates. These locations can also be poked with predetermined screen co-ordinates if certain conditions are met. Address 32476: Horizontal location Address 32477: Vertical location The addresses described above are permanent controlling addresses for principal sprite animation and form the backbone for principal sprite movement in arcade game design or other complex animation sequences. Secondary Sprites ~~~~~~~~~~~~~~~~~ As described earlier there can be up to eight different classes or definitions of secondary sprite used in the animation routine. Each of these sprites can be duplicated twice more giving a total of 24 sprites. These sprites are not controlled by either cursor keys or by joystick, but are controlled by user-written software. Secondary Sprite Locations ~~~~~~~~~~~~~~~~~~~~~~~~~~ Secondary Sprite On/Off Flags Like the principal sprite, each secondary sprite has associated with it an On/Off flag which may be poked with 1 to switch in *on* or 0 to switch it *off*. Secondary Sprite Dimensions Each secondary sprite has associated with it two addresses which contain its horizontal width in bytes, and vertical height in rows. These addresses can be found in the Secondary Sprite Control Address Table given in Appendix 1. Secondary Sprite Class Flags Each secondary sprite has one address which contains the class or definition type of the sprite as loaded into the Animator program from your defined sprite pages. Therefore, the animation routine has the capability to "swap" sprites instantly. This is achieved by poking the sprite class location of the sprite to be swapped with the value of the sprite class to which it is to be changed. For example, if you wish to change sprite class 1 to sprite class 8, then the sprite class flag of sprite 1 should be poked with value 8. It should be remembered that if the dimensions of sprite 8 are different from those of sprite 1 then the height and width of sprite class 8 should be poked into the sprite dimension addresses for sprite 1. This problem can be overcome by ensuring that sprites that may be swapped at some stage in your game are designed on grids having similar dimensions. Secondary Sprite Location Flags The current horizontal and vertical position of the top left pixel of each secondary sprite can be found in two locations which are unique to that sprite and must be poked with the required co-ordinates during animation. If a particular sprite's addresses are poked only once, then the sprite will appear to be stationary. If, however, the addresses are poked with a variable which changes during program execution then the sprite will appear to move on the screen. The exact locations of the sprite flags described above are given in the Secondary Sprite Control Address Table contained in Appendix 1. Using The Animator Program -------------------------- The Animator program is completely menu-driven, and this section of the manual describes each of these menus in turn. The primary function of the Animator routine is to receive sprite definition pages for "principal" and "secondary" sprites and to pass vital parameters to the animation routine which can be saved to or loaded from tape. The Main Menu ~~~~~~~~~~~~~ This menu gives the following options: 1. Principal Sprite Definition 2. Secondary Sprite Definition 3. Save Animation Routine 4. Load Animation Routine When any one of these options is selected you will be asked to verify your selection before proceeding to the next stage. 1. Principal Sprite Definition ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ When the Principal Sprite Definition option is chosen then you will enter the Principal Sprite menu. Sprite Speed The first option on this menu asks you to select a pre-defined sprite speed from the list provided, i.e. 2, 4, 8 or 16 pixels movement. However, as explained earlier, it is not necessary to adhere to these speeds during the animation routine. Sprite Movement The second option asks you to select a type of movement for the principal character. As with option 1, above, this may be changed during the execution of the program by poking the relevant location. Sprite Location You will also be asked to provide an initial screen location for the principal sprite. Load "Principal" Sprite Horizontal Definition Page This is similar to loading a page into the "Generator" program. You will be asked to provide the filename of the page you wish to load and you will be prompted to press the appropriate buttons on your tape recorder. Load "Principal" Sprite Vertical Definition Page This option is similar to the option described above and should be used when loading the vertical Sprite definition page. Return to Main Menu This option returns control to the main Animator menu. 2. Secondary Sprite Definition ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ After selecting this option from the main menu you will be asked to select the following information. Select Sprite Class You will be asked to select the class of sprite to allocate to this definition. The answer to this question should be a character in the range A-H. This describes the position in the secondary sprite table when the sprite control addresses will be located. Loading Sprite Data You will then be asked for the name of the file containing the sprite definitin page to be loaded from tape. Once again you will be prompted to start and stop the tape at the appropriate time. When the page has loaded you will be asked if you wish to duplicate this sprite. At this point you have the option of making up to two additional copies of the sprite being loaded. The control addresses for these sprites follow immediately after the original sprite in the Sprite Control Table. Any More Sprites To Load? This final option gives you the opportunity to load another sprite definition page from tape, and you may do so by responding to this prompt with a Y. Note: Should you wish to create more than three copies of the same object, this can be done simply by loading the same sprite definition page choosing a different class. Note: If you encounter input/output problems while loading Sprite Definitions then these can be overcome by typing RUN 40 and trying again at a different volume setting. 3. Save Animation Routine ~~~~~~~~~~~~~~~~~~~~~~~~~ You have now created the animation routine and are in a position to save the machine code generated to tape. Make sure that you computer is connected to your cassette player before attempting to save the code. When you have selected this option, then you will be asked to provide a name for the routine to be saved. The program will then save the machine code to tape. At the end of the save routine, you will be prompted to stop the tape. At this point you will be given a number of further options, i.e. 1. Start A New Routine 2. Amend Present Routine 3. Exit Program If you wish to make a second copy of the animation routine then select the amend routine at this point. This will restart the program with your current data intact and will allow you to select the save routine to tape option. If you wish to clear memory in order to load another set of sprite data then you should select the "Start A New Routine" option at this stage. If the "Exit Program" option is selected then the expected happens. 4. Load Animation Routine ~~~~~~~~~~~~~~~~~~~~~~~~~ This option allows the user to load a previously defined animation routine. The program will then ask you to enter the name of the file to be loaded and will prompt you to start and stop the tape at the appropriate times. When this sequence is completed then the software returns you to the Main Menu, and at this point you may choose to amend sprite definitions. Note: If you encounter input/output problems while loading animation routines into the Animator then these can be overcome by typing RUN 40 and trying again at a different volume setting. At this point, you should be able to design and generate your own sprites. However, you need to know how to use them... Using Animations In Your Routines --------------------------------- The animation routine that you have developed and saved to tape may be used in your own BASIC or machine code programs. This can be simply done as follows: 1. Reserve the amount of space you require by: 10 CLEAR 200,20600 This line (which should be the first line of your program) reserves all memory from 20600 upwards in RAM, and ensures that your basic program does not overwrite the machine code routine which will be loaded above this address. If you are writing your own machine code routines you will have to lower this address to your own specification, but ensure that your machine coode is loaded below this and that it does not overwrite the animation routine. 2. Load The Animation Routine The second line of the program should be: 20 CLOADM "Filename" Machine code authors should include the next line: 30 CLOADM "User Program" 3. Select The Correct Graphics Mode It is now necessary to initialise the required graphics mode and colour set. You should run the program in the same graphics mode as the animation routine was defined otherwise you may encounter some strange effects. 40 PMODE X,1:SCREEN 1,Y:PCLS Z where X,Y,Z have the values set in the Generator routine. 4. Draw Background You should now draw the background for the game before execution of the animation routine. 5. Execute The Animation Sequence To execute the animation routine then type: 100 EXEC 20601 110 EXEC 20658 You may now insert your game algorithm at this point in the program by PEEKing and POKing the principal and secondary sprite flags and addresses described earlier. Machine code programmers should EXEC their program start address at this stage. Your final line of program should always loop back to the line containing "EXEC 20658" command line, i.e. line 110 in our example. 1000 GOTO 110 How To Use The Sprite Control Table ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ At this point we will explain the user of the secondary sprite control table during execution of the main loop. As explained earlier, the principal sprite is automatically controlled by either the cursor keys or the joystick. However, the secondary sprites are positioned on the screen by your own program via the Control Table. Columns 1 and 2 of the table show the permanent locations for each sprite's horizontal and vertical position on the screen. Column 1 will hold values between 0 and 255 which relates to the distance in pixels from the left hand edge of the screen, while column 2 holds values between 0 and 191 which gives the pixel distance of the sprite from the top the screen. Thus to position a sprite at any position on the screen you simply poke the locations given in the table for that sprite with the values that you require. Example 1: How do we position sprite A's first member 50 pixels from the top of the screen and 100 pixels from the left hand edge? Examination of the Table will show theat sprite A's first member horizontal position is stored at location 26520 and its vertical position is stored at address 26521. Thus the following commands will place the sprite at the desired position: POKE 26520,100:POKE 26521,50 However, poking the addresses with fixed values will not allow the sprite to move, rather it will remain stationary at the specified position. To make the sprite move the locations should be POKEd with values which change during execution of the main loop. Example 2: How do we make the sprite move horizontally 50 pixels from the top of the screen? Once again we will consider the first copy of sprite A. The locations in question are 26520 and 26521. To move horizontally only we need to POKE the vertical address outside the main loop, i.e. POKE 26521,50 will position the first sprite in the table 50 pixels from the top of the screen. We can now move the sprite by POKing location 26520 with a value that changes during each loop. 90 POKE 26521,50 100 EXEC 20601 110 EXEC 20658 120 POKE 26520,A:A=A+2 1000 GOTO 110 This will make the sprite move horizontally two pixels at a time. A quicker method is to discard the variable A and replace it with the sprite's position in the previous loop, e.g. 120 POKE 26520,PEEK(26520)+2 The same method can be applied to vertical movement and if diagonal movement is required both addresses can be varied within the loop. Making Sprites Disappear ------------------------ The column marked on/off flag contains the permanent addresses of the on/off flag for each sprite. These addresses hold a value of either 0 or 1. If the flag is set to 1 then the sprite will appear on the screen and if the location is set to 0 then the sprite will disappear. Initially, all of these flags contain 0 however they are automatically set to 1 when a sprite definition is loaded into the Animator. Therefore, each sprite may be turned off by poking its on/off flag with 0 when certain conditions occur. Example 3: How do we switch off sprite A when it reaches a point 200 pixels from the left hand edge of the screen? 90 POKE 26521,50 100 EXEC 20601 110 EXEC 20658 120 POKE 26520,A:A=A+2 130 IF PEEK(26520)=200 THEN POKE 26526,0 1000 GOTO 110 Using these flags it is possible to switch off sprites if they collide with other sprites. This can be done by peeking the relevant locations for each sprite and comparing them. One of the sprites can then be switched off if these values are the same or within a given range. Sprite Types ~~~~~~~~~~~~ The final column of the sprite table gives the addresses of the locations which hold the sprite type. These locations hold a value between 1 and 8. When a sprite is loaded into the Animator it is loaded under a sprite class in the range A-H. If loaded under class A it will occupy position 1 in the sprite control table and the sprite type flag will be set to 1. Subsequent duplication of the sprite will also generate a type 1 sprite which will be positioned in the next available row of the sprite table. The maximum number of sprites of the same class that may be defined is 3. In a similar fashion if the sprite is loaded under class B the sprite type flag will be set to 2, etc. Thus if you wish to *swap* sprites then you should POKE the type address of the sprite to be changed with the value of the type to which it is to be changed. Example 4: How do we make type 1 sprite change to become a type 2 sprite? 90 POKE 26521,50 100 EXEC 20601 110 EXEC 20658 120 POKE 26520,A:A=A+2 130 IF PEEK(26520)=200 THEN POKE 26527,2 1000 GOTO 110 This method works perfectly so long as the sprites to be swapped are the same size. However, if this is not the case, then we must make use of the last two columns of the Sprite Control Table which are marked Height and Width. These columns hold the width and height of the sprite in pixels and it is essential that these dimensions of the sprites to be swapped are similar. Example 5: Swap sprite type A (first copy) with sprite type B (first copy). Sprite number 1's type address is 26527 and normally holds the value 1. The width and height of sprite number 1 are held at addresses 26524 and 26525. The width and height of sprite number 4 are held at addresses 26548 and 26549. Therefore, to swap sprites the following commands should be used: POKE 26527,2 POKE 26524,PEEK(26548) POKE 26525,PEEK(26529) The swapping of sprites is tedious and time-consuming and can be avoided by program planning, i.e. by ensuring that sprites to be swapped are defined on similar grids. The Missing Columns ~~~~~~~~~~~~~~~~~~~ Readers may have noticed that there appear to be two unused columns in the Sprite Control Table between the vertical position column and the sprite width column. This is correct; these columns hold vital information which is continually accessed by the animation routine. Note: These addresses should never by POKEd by the user! Demonstration Program --------------------- This final section describes an animation routine which was developed using this package. The demonstration game may be loaded by entering CLOADM and, once loaded, will run automatically. The game has two versions; one written in Basic and one written in machine code. You may choose either version. Documented listings of the programs are included and readers may compare the listings and hopefully gain some insight into machine code programming. In the demonstration gamme, the principal sprite is a hungry shark which is controlled by using the cursor keys or joystick. The secondary characters are five fish and one large crab which are software-controlled using the Secondary Sprite Control Table. The object of the game is to eat all the fish which appear on the screen. The sprite definition pages are also included on the tape so that you can see how the characters are defined. These may be loaded into the Generator for sprite amendment or into the Animator if you wish to amend the animation routine. The files are stored on tape directly after the Generator program in the following order: Filename Comment SHARKH Principal Sprite Horizontal SHARKV Principal Sprite Vertical FISH1 Secondary Sprite Class A FISH2 Secondary Sprite Class B FISH3 Secondary Sprite Class C FISH4 Secondary Sprite Class D FISH5 Secondary Sprite Class E CRAB Secondary Sprite Class F There now follows two listings of the game algorithm which are situated in the main loop of the program i.e. between the line which includes EXEC 20658 and the end of the program. The first listing gives the Basic program and the second gives the same program written in machine code. Appendix A ---------- Sprite Horizontal Vertical Width Height On/Off Sprite Class Class 26520 26521 26524 26525 26526 26527 A 26528 26529 26532 26533 26534 26535 26536 26537 26540 26541 26542 26543 26544 26545 26548 26549 26550 26551 B 26552 26553 26556 26557 26558 26559 26560 26561 26564 26565 26566 26567 26568 26569 26572 26573 26574 26575 C 26576 26577 26580 26581 26582 26583 26584 26585 26588 26589 26590 26591 26592 26593 26596 26597 26598 26599 D 26600 26601 26604 26605 26606 26607 26608 26609 26612 26613 26614 26615 26616 26617 26620 26621 26622 26623 E 26624 26625 26628 26629 26630 26631 26632 26633 26636 26637 26638 26639 26640 26641 26644 26645 26646 26647 F 26648 26649 26652 26653 26654 26655 26656 26657 26660 26661 26662 26663 26664 26665 26668 26669 26670 26671 G 26672 26673 26676 26677 26678 26679 26680 26681 26684 26685 26686 26687 26688 26689 26692 26693 26694 26695 H 26696 26697 26700 26701 26702 26703 26704 26705 26708 26709 26710 26711