Navigation

House keeping, ES6 Issues and Filters

Published on 16th September 2016

image

This week has been an interesting mixed-bag of development. Felipe has been cracking through some issues with filters and multi-texture support, ready for the Phaser 3 release. While I've been splitting my time between:

▪ Planning Phaser 3 API changes
▪ Literally filling an entire notebook with plans for a Phaser magazine
▪ Working on porting the Beam Renderer to ES6
▪ Swearing at the convoluted build processes involved for ES6
▪ Loving the clean code that ES6 provides
▪ Swearing at node packages that work on OS X but not on Windows
▪ Loving the speed of our new Transform class
▪ Probably a bit more swearing

As you can probably tell, it's been a bit of a rollercoaster week. On the plus side I've completed a huge chunk of work getting our new Transform system ported to ES6, and it's working really nicely. This under-pins pretty much everything, as it controls the new display list. Any object (such as a Sprite) can extend our Transform class, and instantly inherit all of the properties it needs, such as x, y, rotation, scale and so on. You can immediately read the world values, and they'll be perfectly correct, regardless if the renderer has run or not. Updates intelligently propagate down to children, but only as needed. It's something I started last year in fact, in the Lazer code base, and have finally finished off.

All of the hard work that Pete did on Beam, back in 2015, (Beam being the code-name we gave our new renderer) is being ported to ES6. This, and the Transform Manager, are two vital pieces of work. It feels like lots of loose-ends are coming together. All of those technical tests, and pieces of code we worked on over the past year, finally being put to use.

What does this mean for Phaser? I'm still undecided. My gut instinct tells me that this will all form the basis of Phaser 4, a pure ES6 module based release. And that we use that release, and the experience gained from it, to help shape Lazer development next year. Whatever the outcome, wheels are now turning, and I'm looking forward to sharing early releases with you all soon.