@samme thanks for sharing, and of course it works fine.
but what problem are you trying to solve?
this is a very useful language construct.
By changing it to a global, you lose core strengths of Phaser’s architecture:
the independence of scene instances, and the facile inheritance of scene classes.
You can no longer, for example, craft a basic scene:for your game (
and then extend the scene to create your levels.
I am surely missing something. Please explain.
I think the reason for posting it was that
this was referring to and I just assumed it was some magical keyword that made everything work. It took me at least a few weeks to finally google what it was .