-
Notifications
You must be signed in to change notification settings - Fork 7.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
creating multiple games and deleting them #1260
Comments
Hmmm I've done some further digging into this and even calling the Pixi renderer destroy methods in a local build, but it still happens, so I'm suspecting the Pixi destroy doesn't actually work. I'll need to confirm in a Pixi specific build and file as an issue there if true. |
I'm putting this down as a bug for now, because it definitely happens in my local test case, but I'm still convinced it's a Pixi level bug. Need more time to investigate. |
sure! I'm pretty sure it worked before bumping to 2.1.3. Thanks for the quick response (: |
It did, but Pixi changed massively in 2.1.3 |
…Id` and remove it from the PIXI.instances global. `Game.destroy` now hooks into this. This now means that you can now delete and create your Phaser game over and over without it crashing WebGL after the 4th attempt (#1260)
Thanks for your test case, it really helped me isolate and fix this! |
Hi. I probably use phaser in a way it's not meant to be used, but since the 2.1.3 release I've been getting an issue where if I dynamically create more than 4 games, they only render as totally black when I use WebGL. If I use the canvas renderer everything is fine.
here's a (shitty) codepen to illustrate the issue:
http://codepen.io/hankeypancake/pen/oHgxb
Am I not destroying the games properly or is this a totally wrong way of doing this?
Chrome console tells me:
'WARNING: Too many active WebGL contexts. Oldest context will be lost.'
The text was updated successfully, but these errors were encountered: