Thousand tiles based maps - "How to" using SGDK?
Posted: Sat Jul 17, 2021 5:22 pm
Greetings,
I am trying to port my recently released Metal Slug port for Atari STE, to Sega Genesis/Megadrive
https://youtu.be/gyRBcTnn-5M
Its the first mission...
But the map is very detailed to load 4096 tiles into limited VRAM of this console.
Obviously a way to store, such example, 512 tiles, and dinamically modify these 512 tiles is needed to succesfully display the map on the screen for a Megadrive system.
I was thinking on a way, via C coding, of load the first 512 tiles, and when the map advances one column... check if the new column tiles are already present on the 512 loaded tiles, if not -> search for a free place on the 512 tile list and load the new one.
As well, each "discarded" column at left is being checked, if its tiles are not already present anymore on the screen, in order to mark these no more used tiles as free in order to be loaded when new columns at right demands.
Obviously, this is intended only for horizontal scroller, but it is a really complex tile dynamic loading code, but useful due to it is restricted to a maximum number of tiles on the VRAM.
Complexity can be crazy when 8 way scrolling is take into account,
Is there already a set of functions implemented in SGDK in order to effectively use thousand tiles based tilemaps?
Without require many hard to code very long functions?
Can be the BMP load functions useful due to these have the ability to specify VRAM tile starting?
Are these functions performance effective?
Atari Game Tools (Atari ST/STE) and Scorpion Engine (Conmodore A500 - A1200) have these capabilities already present, you can use these massive tile number based maps. And I am searching for similar functionalities such dinamically loading of VRAM tiles for Genesis/Megadrive
Thanks in advance,
If you can provide code samples, these will be more than welcome!
I am trying to port my recently released Metal Slug port for Atari STE, to Sega Genesis/Megadrive
https://youtu.be/gyRBcTnn-5M
Its the first mission...
But the map is very detailed to load 4096 tiles into limited VRAM of this console.
Obviously a way to store, such example, 512 tiles, and dinamically modify these 512 tiles is needed to succesfully display the map on the screen for a Megadrive system.
I was thinking on a way, via C coding, of load the first 512 tiles, and when the map advances one column... check if the new column tiles are already present on the 512 loaded tiles, if not -> search for a free place on the 512 tile list and load the new one.
As well, each "discarded" column at left is being checked, if its tiles are not already present anymore on the screen, in order to mark these no more used tiles as free in order to be loaded when new columns at right demands.
Obviously, this is intended only for horizontal scroller, but it is a really complex tile dynamic loading code, but useful due to it is restricted to a maximum number of tiles on the VRAM.
Complexity can be crazy when 8 way scrolling is take into account,
Is there already a set of functions implemented in SGDK in order to effectively use thousand tiles based tilemaps?
Without require many hard to code very long functions?
Can be the BMP load functions useful due to these have the ability to specify VRAM tile starting?
Are these functions performance effective?
Atari Game Tools (Atari ST/STE) and Scorpion Engine (Conmodore A500 - A1200) have these capabilities already present, you can use these massive tile number based maps. And I am searching for similar functionalities such dinamically loading of VRAM tiles for Genesis/Megadrive
Thanks in advance,
If you can provide code samples, these will be more than welcome!