Hi everybody. I’m Dan from team Gamefroot. I’m new to these forums but hopefully you’ll see more of me as me and my team start working with Phaser more and more
My message is about Cocoon JS and mobile wrappers. I was not surprised to see Cocoon JS shut down but pretty sad that it did.
In their absence I am wondering whether the Phaser community has had any thoughts or has plans to support a specific mobile wrapper going forward. I’ve seen people talking about Capacitor and Phone Gap but are there any examples of games running performant using these wrappers.
Any thoughts / reassurances on publishing to iOS / Android (and beyond) would be awesome.
I meant “just” in the sense that the same platform (Cordova) is still around, either with the CLI or other free/paid services. In my experience Cocoon’s Canvas+ performance was comparable to Cordova with WKWebview.
At the time (2 years ago), the fastest for Phaser 2 games was Cordova/PhoneGap with the Crosswalk Project (custom WebView) or Coccon with the Canvas+ WebView.
It was necessary to use a custom WebView, since Phaser Games did not work well on all mobile phone with their default WebView. Also I used Phaser.CANVAS to render all my games, since it worked faster than WEBGL.
Nowadays, the default webview on all phones (iOS and Android) are very good. Phaser 3 games work out of the box very fast on all devices. Also the support for WEBGL is now much better.
So today I use PhoneGap (Phaser.AUTO) with no additional webview.
No need for a custom webview, since the defaults are very good.
And you can not use Cocoons Canvas+ if you render the game with WEBGL.
Capacitor is something different, although you can use Cordova plugins with it. Theoretically the performance should be equivalent with PhoneGap.
Hi Yannick, I have an android studio application which I want to add some Phaser 3 games too. The application is made in android studio. Would phonegap be a good solution to convert my HTML5 games to android??
Where I am confused is whether phonegap can be used within another android studio project, or does phonegap create the infrastructure for a solely independent application?
From your response I am guessing it will work fine, as you mention using a webView. I assume this means connecting a webview to the index.html file stored in your android assets?!
Any help to this new android game developer would be of great help!
I’m using cordova and planning to make some plugins in future.
Even if one day cordova will decide to die. I’m planning to make something like it for just android and ios. So I think we won’t have any problems with porting games to native webviews.
One little card game was launched without any problems. But another one has some problems with ios webview. The main issue is that after playing game over 2 minutes phone starts burning. As we found out, it’s result of socket cluster that is being used in project. On Android devices everything is just fine.