Paraphore Blog 9/27/16 - Initialization time problems
Short version: In Paraphore version 0.1.1 we're having some reports of users getting a black screen after pressing the play button. This has been fixed on both the live Inkbunny version of the game and the Patreon dev version of the game.
The issue is that I forgot about some of the first bits of code I wrote in the game, the passage parsing code, which even survived the the port to 0.1.0 mostly intact.
The although that by itself isn't that much faster of an operation, it's just much more memory optimal. The old method using substring() requires creating a new string for each character by repeatedly pulling the first character off like: Hello ello llo lo o
And with over a quarter million characters this is extremely bad for memory, taking over 300mb of RAM at some points. This is temporary though and the memory is returned within one second, although it jostles memory around enough for you to feel it for a couple seconds afterwards if you don't have a lot of memory.
The real problem though is if you run out of memory, due to simply not having enough total, or having other applications using it. If so, Windows' default behaviour is to start to use random parts of the C drive called the pagefile. The drive is hundreds of times slower than RAM, so if this happens it's almost always going to take more than 15 seconds. This is no longer a problem, on any current version of the game with the simpler array loop. I've also raised the script timeout limit to 60 seconds in case such an issue gets away from me again. If you have an extremely low spec machine please let us know if the game has any other large problems like this, sometimes random parts of the code rot with out my notice and brutally punish random configurations.