The Many-Sprites Interpretation Of Amiga Mechanics

The invention of sprites triggered a major shift in video game design, enabling games with independent moving objects and richer graphics despite the limitations of early video gaming hardware. As a result, hardware design was specifically built to manipulate sprites, and generally as new generations of hardware were produced the number of sprites a system could produce went up. But [Coding Secrets], who published games for the Commodore Amiga, used an interesting method to get this system to produce far more sprites at a single time than the hardware claimed to support.

This hack is demonstrated with [Coding Secrets]’s first published game on the Amiga, Leander. Normally the Amiga can only display up to eight sprites at once, but there is a coprocessor in the computer that allows for re-drawing sprites in different areas of the screen. It can wait for certain vertical and horizontal line positions and then execute certain instructions. This doesn’t allow unlimited sprites to be displayed, but as long as only eight are displayed on any given line the effect is similar. [Coding Secrets] used this trick to display the information bar with sprites, as well as many backgrounds, all simultaneously with the characters and enemies we’d normally recognize as sprites.

Of course, using built-in hardware to do something the computer was designed to do isn’t necessarily a hack, but it does demonstrate how intimate knowledge of the system could result in a much more in-depth and immersive experience even on hardware that was otherwise limited. It also wasn’t free to use this coprocessor; it stole processing time away from other tasks the game might otherwise have to perform, so it did take finesse as well. We’ve seen similar programming feats in other gaming projects like this one which gets Tetris running with only 1000 lines of code.

Thanks to [Keith] for the tip!

20 thoughts on “The Many-Sprites Interpretation Of Amiga Mechanics

    1. And the Atari 2600 for more than 2 sprites before that. It’s why the Packman “ghosts” flicker – one place in one frame and another the next.

      1. The horrible flicker in Pac-Man is because it did NOT use any of the techniques discussed in this article.

        An actual example of these techniques would be 2600 Space Invaders, which employed both horizontal and vertical sprite reuse to render an entire formation of invaders, flicker-free, using only two sprites.

    2. Yeah I did this on a 64 to get 32 “virtual” sprites, 8 in each of 4 horizontal bands. I tried alternating them every other screen refresh to get 16 per band, but the flashing was pretty bad. And the computer was spending so much time in the raster interrupt routine it could do very little else.

  1. Yes. But the coprocessor (copper) was programmed seperately so the main cpu was free to do other stuff (sort of as memory was shared between copper and cpu, like badlines on the c64) On the c64 all was done by the cpu.

      1. I’ll take it further…the Amiga line’s got a specific ability to support operations timed to arbitrary beam location, independent of the CPU. The types of operations supported put a power in your hand that’s only hinted at by tricks like this. The possibilities go deeper.

    1. Hm. Does it matter that much, considering that the Amiga hardware itself has an biblical age of 40+ years (in computing).
      A decent documentary about Apollo 11 doesn’t have to be made recently, either, I mean..

        1. Um, there are already some recent ones made or aired by ARTE, I think.
          That’s a French-German TV channel that has a culturual/political focus.
          Here in Germany, the TV channel NTV (a news channels) sometimes airs WW2 (WK2), Third-Reich and military documentaries during night-time.
          I once watched a Hitler documentary with color footage, it was both interesting and frightening.
          Both TV stations can be received via satellite TV in Europe via Astra satellites. And via web stream or YouTube.
          That being said, to my knowledge, there’s not sugarcoating on German TV about the matter. No glorification whatsoever. Just saying..
          Some documentaries are dubbed, you can hear the English original voices in background.
          For example, during interviews with historians.

  2. Cue 1980’s demoscene before 3d vectors drowned everything else out. This is where the game industry got their best ideas from, and indeed friends moved between groups and the industry as time went on…
    You could also make sprites the height of the screen, or higher and change their colors per line from to make parts of them invisible and visible selectively.
    And as someone else mentioned you could do this with the copperlist to appear have more & many other funky tricks, but even more interesting was overwriting tagged chunks of the copperlist wholesale in memory from itself using the bit blitter to copy from preprepared tables with less resource usage and preparing the tables during the vertical blanking interrupt time.
    And with all that saved cpu time, you could spend it on masking blitter objects into a background image (that could be waving or scrolling if you liked) to have even more. Even during screen display if you were using dual plane switching to draw on a inactive copy then switching to that next start of raster while you redrew the last one.
    After the c64 the amiga was amazing once you got your head around how the arch worked and to offload jobs to the other custom chips besides the m68k, and what you could make it do as a result.

    1. Speaking of the Amiga Blitter, the Atari ST had one, too! 😃👍
      It was an optional item in the original Atari ST line, but was standard in Mega ST.
      The Blitter was supported at operating system level beginning with TOS 1.02, nicknamed Blitter-TOS.
      It was the predecessor to the famous Rainbow-TOS (1.04) which had excellent compatibility with MS-DOS formatted floppies. 😃

      https://en.wikipedia.org/wiki/Blitter#History
      https://www.atari-wiki.com/index.php?title=Blitter
      https://en.wikipedia.org/wiki/Atari_TOS#Versions

      1. Every version of TOS was compatible with MS-DOS’s formatted floppy disks. The earlier versions had a slight tweak to the boot sector that made them incompatible when formatted by TOS, but the later TOS formatted them with the proper value in the boot sector. You could also update the boot sector on earlier TOS disks to make them compatible. The earliest TOS had horrendous performance with hard drives, where searching for free space took about 1 second per megabyte stored on the drive! It was strange that they actually required ROM chip swaps to upgrade the TOS version.

  3. Since the HW producing the raster was also controlled by a copper list we did all sorts of tricks to produce animations. There could be multiple copper lists that the CPU could switch so the possibilities were almost endless. It encouraged thinking outside the norm which admittedly we were craving :-). As pointed out the root of that creativity can be traced to the 2600 and other early game consoles where HW was extremely limited. Long live the Amiga.

  4. It wasn’t coding secrets (Jon Burton) who figured this out on the Amiga. I showed him it working in a demo of the technique when he and Andy Ingram (Travellers Tales cofounder) came over to my house. He asked me how it was done, so I let him know do he could use it in Leander, I was also using it in Superhero (unreleased). If you look on his YouTube video comment, you will see he confirmed it.

    Near the end of this video you should see the full screen 16 colour on 16 colour scrolling demonI made that he saw.

    https://youtu.be/V9uUAnmOIP8?si=Hl0Kfa4YoydjNIpF

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.