Hello everyone! We hope you are surviving the spring allergy season (we sure aren’t). Here’s what we were up to during April!
Our main focus for the last month was on improving loading times for levels/rooms/screens of which you can see above. We had noticed for a while now that loading times seemed to be just a little too long.
We previously expected that if a transition would take 1 second animation-wise, then the actually loading of the screen shouldn’t take more than a second. Yet on average we were seeing screens take 4-7 seconds just to load – weird. Was it perhaps a recent GameMaker update that broke something? Is it our recent work to add in more assets? Are we reaching the limit of the engine?
A mystery was afoot.
So we debugged and fixed a few things here and there that seemed like they were causing issues but it was still taking a REALLY long time to load. And so we did more debugging, and more, and more and found… that it was GameMaker’s draw events taking up all the time.
So we poked around on the internet. Surely someone must’ve run into this before, right? Nope. And then we started to poke other people. Did they ever see anything like this? Not quite.
We were given a handy hint to take a look at texture_debug_messages and we found that with each screen transition the textures were being wiped from memory – so it had to unpack them all over again. The function that was causing this was draw_texture_flush. We had added it at some point over the years. With a quick delete we were suddenly loading MUCH faster.
We did still notice that the initial load of the files were taking a while – anywhere from 1-5 seconds. The cause was the overworld texture pages being unpacked into memory. We changed that to preload on game start (where a splash screen will eventually be) and now it’s as speedy as can be.
How speedy? 0.03 – 0.2 seconds.
Now that we’re loading faster, we also sped up the speed of the room transitions going from an average of 1 second long to 0.5 seconds.
And all of this is to say that the game is thankfully in good shape (phew) and now better than ever. In the future you’ll be able to play at maximum speed.
Crafting New Skills
In addition to our performance improvements, we made some progress on skills and more animations. Above is a wonderful cauldron animation made for the crafting screen and a future craft skill! Yes – that’s right – you can craft items to fill up your inventory in case you run out mid battle! Assuming you have the materials that is… We’ll go into more details about this handy little skill in the future~
Now that performance woes are over and we don’t have to worry about the content updates causing issues, we’ll be heading right on back to adding them in and focusing on:
- TTBattle Skills and Balancing
- Adding Cutscenes
- Adding Overworld Interiors