A brand new game
for Windows, Linux, Mac, HTML5, 3DS Homebrew and more
16th April, 2018
Yeah, I really don't have a lot of RAM to play with in the 3DS, do I!?!
You know what's big and lumbering!?
That giant Grid array that I've been using in the past 100-or-so games.
The one that holds tilemaps, enemy movements and more.
One of two multi-purpose arrays that I tend to leave in memory because I've found that it's typically easier on systems to have a static array than to keep shuffling and freeing and re-requesting chunks of memory to be used.
That's a neat idea, but when the array is as bloody huge as it's grown to be, over the past few years, the 3DS really doesn't like it!!
Today I'll be playing with my memory management a little.
Having a massive 1024x1024x10 array is great for generating massive levels, but in all honesty, most of my games tend to use about 128x128x10 at most, so it's probably a good idea to trim that down a little.
The accompanying Obj[1024x10] array could probably also do with a bit of a trim, but things like Player, Score[1024*20], Particles and Stars [both 256*10] are probably ok as they are.
It's just the REALLY big ones that I need to worry about.
On top of that, I'm having a bit of an issue with generating images internally. I think it's down to me trying to do too many things at once, and the 3DS falling over itself. I need to add some sort of frameskip whenever I'm doing buffer drawing, or something to that effect, to stop it from trying to draw things that aren't quite yet ready to be drawn.
So, that's probably what today's tasks will all be about. Managing memory, finding odd quirks that I need to fix, and getting the framework running on 3DS again.. Because it's currently insta-crashing on the hardware!
Doesn't help that the emulator runs this stuff without skipping a beat, so it's a case of tweak-compile-test, over and over, to figure things out.
This should've been done, by now!!!