Ricardo
Member
Hi there!
Since I discovered draw_texture_flush() is not implemented in GMS' JS engine, I have serious doubts if GMS is a viable option to make a big HTML5 adventure game. In theory, with the texture flush function working (and using audio groups), I could make a 1 GB HTML5 game without problems, as I could clean unused assets to keep the memory usage in acceptable levels.
However, without the possibility of clean the VRAM, the game will use more and more memory and ocasionally crash. This problem is even worse when we consider mobile devices. I know that JS programs are garbage-collected, but my tests shown that GMS' programs NEVER release memory, no matter what.
Has someone managed to create a really big HTML5 game using GMS and found a way to clean the VRAM without use draw_texture_flush()? I've spent a lot of time searching about this, but as GMS' JS engine is ofuscated, is hard to find a workaround by myself.
The closest I've ever gotten to a solution is through simulating a WebGL context loss using a extension with .loseContext(), but I had no luck to get the game run again properly with .restoreContext() since, apparently, GMS does not has a loss/restore context management system (or maybe I haven't found the way of call it manually).
Any thought, idea or opinion about this problem is really welcome, as well as names of big GMS's HTML5 games that managed to workaround this difficulty (I haven't found any yet).
Since I discovered draw_texture_flush() is not implemented in GMS' JS engine, I have serious doubts if GMS is a viable option to make a big HTML5 adventure game. In theory, with the texture flush function working (and using audio groups), I could make a 1 GB HTML5 game without problems, as I could clean unused assets to keep the memory usage in acceptable levels.
However, without the possibility of clean the VRAM, the game will use more and more memory and ocasionally crash. This problem is even worse when we consider mobile devices. I know that JS programs are garbage-collected, but my tests shown that GMS' programs NEVER release memory, no matter what.
Has someone managed to create a really big HTML5 game using GMS and found a way to clean the VRAM without use draw_texture_flush()? I've spent a lot of time searching about this, but as GMS' JS engine is ofuscated, is hard to find a workaround by myself.
The closest I've ever gotten to a solution is through simulating a WebGL context loss using a extension with .loseContext(), but I had no luck to get the game run again properly with .restoreContext() since, apparently, GMS does not has a loss/restore context management system (or maybe I haven't found the way of call it manually).
Any thought, idea or opinion about this problem is really welcome, as well as names of big GMS's HTML5 games that managed to workaround this difficulty (I haven't found any yet).