Newsletter
Published on 26th February 2019
Welcome to Issue 142 of Phaser World
Here we are with the final issue of February. This year has been pretty awesome, so far. We've had a big Phaser release, amazing games, and some really, really good tutorials. And this issue is no different! Check out the Paper Plane Physics tutorial, for example, play the wonderfully bizarre Goat Detective or the insanely cute Guinea Jump :)
I'm pleased to say that I'm now sold out of Phaser Stickers. It's been really good fun mailing hundreds of them out and seeing the reactions as they arrived. My hope is to one day see a laptop at an event with one on :) I still have some stickers left in reserve for new patrons but won't be selling them again for a few months.
As usual, be sure to so you don't miss anything.
Got a game or tutorial you'd like featured? Simply reply to this email, or message me on Slack, Discord or Twitter. Until the next issue, keep on coding!
The Latest Games
Game of the Week
Help Detective Goatman solve the murder of a Supah K-Star! as you investigate and track culprits in this point-and-click adventure.
Staff Pick
Are you reflexes quick enough to help the adorable pixel-art guinea pigs leap through hoops to collect the treats they love so much?
Enjoy a game of mahjong set among gentle falling cherry blossom, with 3 levels of difficulty to choose from.
A barren space station. Something has gone wrong. Power failing. A lone survivor in hypersleep. You are the lone survivor. You need to escape.
Guide the constantly spinning bird towards the fruit and avoid the spikes.
What's New?
A great in-depth tutorial on building a paper plane glider with Phaser 3 and Arcade Physics.
The complete session on building games in Phaser 3 from the ThunderPlains 2018 conference.
Prefer using Parcel to Webpack? This is a complete Phaser 3 game template for painless set-up.
Don't Touch the Spikes Tutorial
In this tutorial the prototype is evolved from using basic debug graphics to proper art assets.
Getting Started with Phaser Part 2
A new beginners tutorial series of animated videos on getting started with Phaser 3.
Phaser 3 Game Development Course
A complete Phaser 3 and JavaScript Game Development package. 9 courses, 119 lessons and over 15 hours of video content. Learn to code and create a huge portfolio of cross platform games.
Help support Phaser
Because Phaser is an open source project, we cannot charge for it in the same way as traditional retail software. What's more, we don't ever want to. After all, it's built on, and was born from, open web standards. The core framework will always be free, even if you use it commercially.
You may not realize it, but because of this, we rely 100% on community backing to fund development.
Your support helps secure a constant cycle of updates, fixes, new features and planning for the future. There are other benefits to backing Phaser, too:
Click to see the full list of backer perks
I use Patreon to manage the backing and you can support Phaser from $1 per month. The amount you pledge is entirely up to you and can be changed as often as you like.
Please help support Phaser on Patreon
Thank you to these awesome Patrons who recently joined and make continued development of Phaser possible:
Alexander Friedmann
Anto Nito
Breno Polanski
Carlos Alberto Arizpe Mendoza
Gamma
Jadden
Joseph Laquinte
Krzysztof Antoszek
Manolis Perrakis
Richard Ashkettle
Zhuliyan Paskov
Also, thank you to Jeffrey Revesz for backing via PayPal :)
Dev Log #142
Welcome to Dev Log 142. I spent the majority of the week carrying on my work with the new docs. I'm aware they are taking a while, but it's a pretty huge and important project. However, to avoid Phaser getting stale I have split my week up to do both docs and work on the next release. Let's dive in ...
3.16.3 Development
At the moment, 3.16.3 is focusing specifically on addressing issues from GitHub, along with a handful of important features. The biggest new addition came about as a result of a side-effect from the Input Manager changes in 3.16. In order to provide the ability for Phaser to tell if you mouse up outside of the canvas, it has to listen to DOM events from outside of the canvas too. So in 3.16 it now binds itself to the window object. This works in lots of cases, but when you've got another layer in the mix, like Vue, that also intercepts DOM events, things can get a bit messy.
To address this I've made a couple of changes in 3.16.3. First, the window listeners can be disabled entirely. Use the new game config property 'input.windowEvents' and set it to false. Then the listeners won't ever be created. This is a trade-off, as it means that events like 'POINTER_UP_OUTSIDE' can never be dispatched, either. Yet depending on your needs that might be just fine. At least you now get the choice.
Related to this, I've also changed how the Mouse and Touch managers handle window level events (if you've left them enabled). Before, they would use the same handler as the canvas events. In hindsight, this was wrong, as they need slightly different event paths and shouldn't ever fire if the event target is the actual canvas. This was causing input events to fire twice, once for the window and once for the canvas, as it flowed through the DOM. It didn't manifest in Phaser Game Objects because they were handled internally, but it was still redundant and no longer occurs.
More Tweaks
I've removed all references to Cocoon from the API, as now they have closed down it isn't worth keeping. There are (yet more) fixes for users exiting Fullscreen mode, too. There is a handy new event to tell when a Scene finishes being created, some tweaks to allow animation frames to be specified in reverse and lots of fixes and improvements to the docs.
Ideally, I'll get 3.16.3 out before the end of the month, but it depends entirely on how testing goes, so it may need to slip into early March. Either way, it won't be long before it's out and then I can focus on 3.17. If you'd like to help test you can find the latest version in GitHub master branch, like usual.
Translation Help Needed
Last week I wrote that I would love to have the Phaser getting started guides translated into languages other than English. Thank you to those who have stepped forwards! So far, we've got translations into Bulgarian, Czech, Greek, Spanish, German, Turkish, French and Chinese. This is an amazing start!
Are you able to help translate the guides into a language not already covered? If so, please email me (rdavey@gmail.com) and I'll send you the details. The guides are plain markdown files and quite short, so hopefully won't take too much of your time.
You will be credited as the translator which can include a link to whatever site you like (your own site, a game you've released, etc). These guides have a lot of monthly readers so it'll be brilliant to offer them in languages other than English.
Phaser 3 Docs Work
Last Dev Log I talked about the work I was doing on the Phaser docs. I alluded to how it's entirely unglamorous, but essential, which seemed to resonate with a number of you. If you didn't read it, please do so here before continuing.
I carried on refining the JSON to SQL process and I'm now happy that it has every feature I currently need, so the majority of the work was spent on the actual docs interface. I've been a big fan of Bootstrap for years, so it made sense to utilize it for the docs. I spent a lot of time working on the layout, refining it, improving and tweaking all over the place. Here's a screen shot of a class method in the new layout (click the shot for a larger version):
Because I have 100% control over the template I can decide which parts of the docs are most important. I can give priority to certain elements, such as method signatures, while making features such as the link to the source code line number less visually important, while still keeping them. Each method has its own unique URL, too, which means I'll be able to deep-link direct to a method and have just that appear on the page, without any extra content around it that may otherwise be confusing, which is will be especially helpful for beginners guides.
I've also built in an option for you to toggle inherited methods and properties on and off. Most Game Objects, for example, inherit a whole bunch of properties from the components, and you can now hide them all to see exactly just what that Game Object does on its own.
Methods and Properties can also be hidden at will and easily searched, data types are links to details about that type, source code is properly formatted and colored and everything just has better spacing and alignment than before.
Another feature that's only possible because of the move to SQL is the ability to compare docs between versions. Every property and method in the API has, since the very first 3.0.0 version, been marked to say when it was added. This means it's possible to show the evolution of a class, or part of one, by comparing version numbers. Automatic lists of things that were deprecated or added is now possible without needing to consult the Change Log. It's the sort of feature that is only useful to a select number of devs, but I'm one of those, so you all get to benefit from it :)
One thing that I'm keen to do, once the new docs are live, is to go through and link docs to source code examples. JSDoc actually has a tag for this built-in, so we can make use of it to provide direct links from methods to code showing how to use them. There is also the ability to link methods to tutorials and long-form content, the sort of content too large to have in JSDoc blocks directly, but can be held elsewhere. Obviously, there are lots of methods across the whole API, so it will take ages to do them all, but I feel it's the sort of endevor that can be chipped away at, bit by bit, over the rest of the year and beyond.
For now, I'm heading off back into the depths of CSS and coming up for breath by tackling more GitHub issues. If you'd like to help, please test the master branch or submit PRs (especially ones that help complete docs). Until next issue, keep coding actual games, you lucky people!
Vixel is a WebGL path tracing voxel renderer.
Chrome now supports hardware media keys.
In less than a year, Microsoft will terminate Internet Explorer 10. Thank goodness.
Phaser Releases
Phaser 3.16.2 released February 11th 2019.
Phaser CE 2.12.0 released 6th February 2019.
Please help support Phaser development
Have some news you'd like published? Email support@phaser.io or tweet us.
Missed an issue? Check out the Back Issues page.