Melkhior’s Mansion – Project Update #5

Welcome to the regular Sunday night project update for the conversion of Melkhior’s Mansion Spectrum Next!

Progress has been rather slow this week due to a trip to the dentist leaving me with a lot of discomfort and unable to concentrate. I’ve also been feeling rather grotty and tired. I’m due back at the dentist soon so the best option has been to rest and ride it out…

I have started the conversion early before the original is finished so it’s not going to be a problem to lose a week.

I am currently about half way into development of my memory space optimizing sprite cutting system that I mentioned last update. The Barrel animation used by one of the secret passages is now around 10K which is much better than 42K using the previous method of storing the sprites as I find them on the texture pages.

My improved cutting system includes the output of source code include files providing auto-generated Spectrum Next attributes used to display each sprite.

Here is an example of Spectrum Next sprite attributes needed to define a 32×32 pixel shape using four anchored 16×16 sprites:

db 00,00,0×00,11000000b+00,10000000b
db 00,16,0×00,11000000b+00,01100001b
db 16,00,0×00,11000000b+01,01000001b
db 16,16,0×00,11000000b+01,01100001b

As you can see, it’s not something one would wish to type in by hand for each frame of animation. My automated process will save many man hours of work and ensure that all assets are defined error free and optimal.

The cutting process also outputs a computer generated DMA (Direct Memory Access) list used by the game engine to transfer the 16×16 pixel sprites required for each frame of animation to FPGA BRAM. Sprites on the Next are stored in 16K of special high speed block RAM (BRAM) that is similar to video memory (VRAM) used by other computer systems. The sprite data is split across several memory banks and stored in a non-linear order so having the system take care of pixel art textures saves me time and stress.

Once implemented, the result will allow the game to easily display pixel art assets with very little Z80 code. I am looking forward to this system as I will be able to progress with the conversion at a faster pace!

Sadly, that’s it for this week. I will be back late next Sunday night, UK time (GMT) with another update.

KevB aka 9bitcolor.

https://twitter.com/9bitcolor
https://twitter.com/EricRetro
https://twitter.com/hot_piping

Leave a Reply

Your email address will not be published.

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