If you read my note at the end of the post when I released Sodom & Gomorrah two and a half weeks ago, you'll recall that I was having an issue with the map taking an extra long time to load. Well, I have some good news - I've figured out what was causing the delay, because I encountered the same issue on the Purgatory map I am currently working on, and I was able to isolate the problem this time. And it turns out, it's my old nemesis, the RPG Maker MV BGM Delay, rearing its ugly head again.
The thing that these two maps have in common is that they call a BGM file to be played (most of this game relies on silence and sound effects as opposed to having a running soundtrack), and BGM files are significantly larger than shorter sound effect files and images (which have a smaller file size compared to audio). So what's happening is the Preload Manager is hanging while loading those large BGM files.
And before you say, "just disable the Preload Manager", this is exactly the reason I started using it in the first place. RPG Maker MV loads files on the fly (I'm honestly wondering what VX Ace did differently, and why MV is so utterly incapable of performing such a basic function that its predecessor had no issue with), so when you call a BGM, it takes a couple seconds for it to load and then start playing. The Preload Manager doesn't load it any faster, it just opts to load the file ahead of time when you transfer to the map that uses it, so it will be ready the second it's called. It's a tradeoff.
The bad news is that there isn't a whole lot I can do about it. Moving the loading to the front of the map is preferable to waiting until you need the file for it to load. What I can do is bump it all the way to the start of the game, when it's booting up, and players are expecting to wait a few seconds. So far, this seems to work pretty well (the affected map transfers are much quicker), although if I had more than a few BGMs throughout my game, it might make the boot load itself unwieldy.
In fact, I'm wondering if the Preload Manager is any use at all for anything other than BGMs, since - unless I'm mistaken - that's the only thing I recall having loading problems with. In any case, I've modified it so that now it only performs boot loading of predesignated BGM files and not its usual preload on map transfer, so we'll try it out that way and see if any problems arise...
Followup: It looks like I may have to revert to between-map loading after all. There's a question of how long a given file remains in memory after being pre-loaded, and I'm concerned that if the BGM is loaded at startup, it may be purged long before the player, during the regular course of playing the game (and not going directly to the parts I'm working on, as I do when I'm testing), gets to the point where the file is needed.
I haven't been able to test that yet (as it requires longer periods of play-testing), but there's also another problem involving a graphical glitch when switching characters to their damage sprites (to make them appear slouched or fallen over) - a momentary blip, presumably due to the program loading the image on demand.
Prior to investigating the load lag issue, I had replaced the "Now Loading" screen with a blank screen, because I thought it was annoying and disrupts the player's immersion into the game. This actually contributed to my confusion, because when the map hung before loading, I didn't immediately recognize what it was doing. I think I might ultimately just put the "Now Loading" screen back in, and learn to live with it (even though it annoys me when it only shows up for a fraction of a second, as on most maps - better off not showing up at all, if you ask me...).
No comments:
Post a Comment