home *** CD-ROM | disk | FTP | other *** search
/ Run Magazine ReRun 1991 November & December / rerun-1991-11-12a.d64 / use.txt < prev    next >
Text File  |  2022-09-20  |  11KB  |  86 lines

  1. Ultimate Sprite Editor
  2.  
  3. By Mark Jordan
  4.  
  5.      Recently, RUN's editors asked me if I would update the sprite editor, named Sprite Artist, that I wrote for RUN several years ago. It had been a while since I'd used the program myself, so I loaded it up and thought, "Nice program...for 1985."  Forget the update, it was time to do a brand new sprite editor. Ultimate Sprite Editor is the result. Lest you think the title a bit presumptuous, take a look at what it lets you do:
  6. *Create and edit eight super sprites.
  7. *Animations up to 25 frames long, with
  8. adjustable speed and sequence.
  9. *Type directly from the keyboard
  10. into your sprite design.
  11. *"Fold" sprites to get symetrical designs.
  12. *View all eight sprites at once, and
  13. arrange them in different ways for
  14. multiple-sprite creations.
  15. *Draw up, down, right and left by
  16. setting the cursor appropriately.
  17. *Rotate sprites 90 degrees.
  18. *Copy and paste sprite shapes and
  19. undo changes.
  20. *Load sprite files via a simple,
  21. error-proof cursor/return method.
  22. *Create Data statements that attach to
  23. whatever program you have in memory.
  24.      Plus expand, flip, invert, multicolor, move, and do everything the other editors do . . . all at machine language speed. Actually, I would have loved to put in even more features, but there's a limit to what a RUN reader will type, and this program already approaches that limit. It's approximately 4K (4000 bytes) long and resides in a safe region of memory ($C000--$CFFF) that's also 4K long---another reason I had to quit when I did.
  25.  
  26. Getting Things Going
  27.  
  28.      Whenever you want to use Ultimate Sprite Editor, simply load and run the boot program. Any program you have in the Basic portion of memory will remain unharmed when you load and run Ultimate Sprite Editor. Therefore, you can develop your sprites concurrently with Basic programs.
  29.      You can jump in and out of the editor with ease. In fact, if you ever saw the need, you could include Ultimate Sprite Editor itself within a Basic program and use the command SYS 49152 to jump into it while the program is running.
  30.      Using Ultimate Sprite Editor should be quite intuitive for those who have worked with previous sprite editors. A large grid, 24 columns by 21 rows, is on the right side of the screen, and the eight sprites show up on the left. Use the cursor keys to move about the grid.
  31.      When you first enter the program, sprite 1 will be the active sprite, which you can edit. The function keys let you jump from sprite to sprite (F1 activates sprite 1; F2, sprite 2; and so forth).
  32.      Drawing is done using the number keys, 1 to 4, in this way: 1 sets a given point to the background color (in other words, it erases), 2 draws with the existing sprite color, 3 draws with multicolor 1, and 4 draws with multicolor 2. If you're editing in single-color mode (the default), keys 3 and 4 function the same as key 2. The space bar also draws like key 2. One important note that you might overlook in the explanation of features below: To change sprite color or either of the multicolors, simply press shift while pressing the 2, 3, or 4 key.
  33.  
  34. Features & Functions
  35.  
  36.      Ultimate Sprite Editor's features are accessed by pressing keys. All 26 alphabetic keys, as well as several nonalphabetic keys, have a function. What follows is a key-by-key listing of all the features:
  37.      A---Animate. This powerful feature requires a little explanation. First you must understand that you will animate only one sprite at a time---the one that's active when you first press A and enter the animation mode. That sprite may take on any of the eight sprite shapes viewable on the screen, and in any order. It may also take on the same shape several times. The only limit is 25 shape changes before the animation repeats.
  38.      Number keys 1--8 correspond to sprites 1--8. Therefore, to set the animation sequence all you must do is press the keys in the order you want the sprite shapes to occur.
  39.      To illustrate, if you're editing sprite 1 and want to have it go through the entire eight sprite shapes that you've developed, just press 1, 2, 3, 4, 5, 6, 7, 8.  Press return to start the animation. If you'd like to have it cycle forward then backward through the sequence, just enter 1, 2, 3, 4, 5, 6, 7, 8, 7, 6, 5, 4, 3, 2. (You can leave off the last 1, because the animation cycle will repeat beginning with 1.)
  40.      Once the animation begins, you can use the less-than (<) and greater-than (>) keys---or comma (,) and period (.)---to speed it up or slow it down. The current speed is indicated by a number that increases as the animation slows. While a speed-change key is being pressed, the actual speed doesn't change but the displayed speed does.
  41.      Performing animations is great fun in itself, but you'll probably want to use your creations inside a program at some point. It's outside the scope of this article to describe all the details of using sprites within a Basic program, but the concept of animation can be simply stated: Change the sprite pointer located at 2040--2047 to point to the sprite shapes in memory in the same sequence as with Ultimate Sprite Editor.
  42.      B---Background Color. This key cycles the background color of your screen.
  43.      C---Sprite Color. This key (or its alternative, shift/2) cycles the active sprite color. You'll discover that it cycles through only 14 colors. This is because the program doesn't let the sprite color be the same as either of the two multicolors. If you want a color it skips over, just change the multicolor first (see below).
  44.      D (shifted)---Data statements. This option attaches Data statements to whatever program is in memory, starting with line 60000. It refuses to let you attach data twice---you must exit Ultimate Sprite Editor first and then reenter to do that. The reason is to keep you from inadvertently attaching several sets of data to a single program (one popular sprite editor had this flaw).
  45.      E---Type Mode. This novel function lets you manipulate sprite shapes directly from the keyboard. Because sprites are only 24-by-21 pixels, they can contain a maximum of six characters. However, by creative use of this command you can squeeze more in. Just type a row of characters (three), exit Type mode with the back-arrow key, use the scroll keys (see below) to move the characters up or down six or seven pixels, then reenter and type some more.
  46.      F---Fold Sprite. This feature treats whatever is on the left half of your grid as "wet ink." Press F and you'll fold this wet side onto the right. It's very handy for designing symetrical shapes---just draw half and fold.
  47.      G---Group Sprites. The sprites default into a two-column, four-sprite-deep arrangement. Press G once and they group tightly together vertically; press it again and they group tightly horizontally; press one more time and they cycle back to the default.
  48.      H---Horizontal Flip. Say no more.
  49.      I---Invert. Turns all the "off" pixels on, and vice versa.
  50.      J---Jump. Activates the next sprite (an alternative to the function keys).
  51.      K---Walk Left. After you press a color key (or the space bar), it's usual for the cursor to move to the right, as in a word processor. But sometimes you'll want to draw the other way. K does that by moving the cursor left.
  52.      L---Walk Right. Just the opposite of K. See also O and comma (,) for walking up and down. (L and K advance to the next row when you hit the end of the frame. However,  O and comma don't advance to the next column.)
  53.      L (shifted)---Load. Lets you load previously-saved sprite files without any typing---just cursor to the filename and press return. Up to 48 files can be viewed. The sprite data is loaded into memory beginning at location 15808. If your needs call for data in a different section of memory, you'll need to adjust accordingly.
  54.      M---Move Sprite. Permits moving the active sprite anywhere on the screen using the cursor keys. Press R (in move mode) to reset the position.
  55.      O---Walk Up. See K and L above.
  56.      P---Rotate Twice. Rotates a sprite 180 degrees. This differs from a horizontal flip because the sprite pivots on its center, rather than reversing itself.
  57.      Q---Quit. Drops you bac