So I create a 3D endless game and build it for Webgl and you can check it here (run the game and take a look at the memory usage from the task manager)
https://dl.dropboxusercontent.com/u/103586730/RollBall!/index.html
The problem is its using 450+MB of memory it even reaches 500 and more that’s 0.5GB what is wrong is it my code note that if you checked the game out I did try to stop the generation of the floors and still it only dropped less than 50MB, So I tried to disable every thing in the scene (Except the camera) and still it uses about 300MB
then I tried to only enable the generation of the floors and now it uses 390MB so it could possibly be the generation of the floors is what causing it to use that much so I’ll figure out another way to generate the floor but an empty scene using 300MB that is a big problem.
I have read an article here WebGL Roadmap - Unity Engine - Unity Discussions and it said that JavaScript require a lot of memory and since I use JavaScript for this game could it be the reason and if I spend my next 2 weeks to translate it to C# all of this issue can be from the past? What do you think can be the reason? And how to fix it?
Basically how to properly optimize an WebGl game?
Using Unity 5.3.4p6