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.
http://www.imgfeed.co/c2proj/PocGen32x32/index.html
Here is the scrolling method I'm using now:
[attachment=1:2dpesfrz][/attachment:2dpesfrz]
Here is how I populate the sprites using an array and draw only the area necessary. ( see the "between values")
[attachment=0:2dpesfrz][/attachment:2dpesfrz]
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...