I’ve done nothing so far today. I need a good kick up the backside.
Yesterday I achieved a lot, today I am distracted and tired.
I really must get a room table format sorted out, one that is easy to sort, or is pre-sorted by the editor. I probably need to find a way of inserting moving objects in the right position in the display list. I’m aware that this is easy stuff and that several algorithms exist to solve this simple problem, so I’ll have a look at them.
For the Spectrum version, it was just a case of having the blocks in the room drawn from back to front, inserting the correct animated sprites in the right position on the way to the front of the screen. It was a slow, brute-force method. When I did the C64 version, that would never have worked. I was switching to a really slow 1MHz 6502. So for that, I drew the rooms once – and then used masking tables to obscure the sprite data where blocks overlapped the player or “enemy” position. I called that “DPA” or “Dynamic Priority Allocation”. Stupid name, but David and I were always laughing about silly TLAs, so I made this one up. It did pretty much the same thing that Christ Stamper did for his Filmation technique.
A year later, I was to see the source code for Nightshade on the Spectrum as I got contracted to do the C64 version of that game. That’s what you call coming full circle.