SP1 Scrolling: Multiple Directions
I finished one of my last posts “SP1 Scrolling: Updated Performance Review” saying that my next scrolling experiments would not be SP1 related. But then I had some new ideas about how to do multidirectional scrolling… so I set myself for a new article series :-)
I have continued my SP1 scrolling quest, now with multidirectional scroll… and so far, the baseline looks good! See for yourself:
The demo above scrolls a 128x128 pixel viewport in 1-pixel increments over a 768x384 pixel map, following a predetermined path. The map is built as a 48x24 grid of 16x16-pixel tiles.
With no optimizations (brute force scrolling and SP1 update of full area), the framerate seemed good enough to try on some optimizations and more serious map management.
So I spent some time developing a real scroll-map system (the code that decides when and where to draw new graphics while we are scrolling in any direction). This, and some new tiles specially designed for this kind of map, have made the examples much more nicer to view. But still, the animated GIF files do not do justice to the real effect, I encourage you to download the TAP files and see for yourself in your favourite emulator.
In a future post I’ll describe the mapping system in detail, but anyway, here is the meat for the impatient:
1-pixel scrolling (TAP file here):
2-pixel scrolling (TAP file here):
4-pixel scrolling (TAP file here):
8-pixel scrolling (TAP file here):
Multidirectional scrolling starts to look good indeed!