Hi all. I'm hoping someone can lend me a hand. I'm placing sprites on my layout using data from an array using the miner method. All is fine and dandy, except for the amount objects loaded to memory once the screen is drawn. Right now, I load each "page" from the array in approximately 30x16 sprites at a time to avoid the CPU load issues, which works for now... However I would like to use the Scroll To behavior and load the tiles on the fly, as the player moves around the screen.
Here's my work in progress to get an idea. Use the arrow keys to move around and mine through the terrain.
Here is the scrolling method I'm using now:
Here is how I populate the sprites using an array and draw only the area necessary. ( see the "between values")
I'm in the process of trying lerp/scrollxy, however I would have to load 8 times the number of tiles to make the scene ready to scroll to...