Hello.
In our game, we have several different menu scenes and one big gameplay scene. In the menu scenes, memory consumption remains, according to Instruments, around 25MB. But when we move from a menu scene to the gameplay scene, the memory consumption climbs to 45MB during the loading of the scene, then immediately drops back down to 37 when the loading is complete. The problem is that the 45MB spike causes some devices to run out of memory and crash.
So my question is: Is it normal for Unity to allocate a lot of memory during the loading of a scene, even though the scene doesn’t need that much memory when running? My other theory was that some things from the menu scenes remain in memory during the loading, but when I added a very light scene between the menu and gameplay scenes, the problem didn’t go away. (I even called System.GC.Collect() in that lightweight scene.)
There doesn’t seem to be such a memory spike with all scenes, just this one…