Integrating Ps4 controller support in games

Hi all,

Is there a way to let players use Ps4 controllers to play games made with PlayCanvas?

Browsers will have a gamepad API. There aren’t any tutorials for gamepads but there is a PlayCanvas API

By default, the PlayCanvas engine has created the gamepad objects already at (

1 Like

Thanks. Actually I was wondering whether it was possible to make a Ps4 game using PlayCanvas.

Off hand, I haven’t heard of any web games being made to be available as a downloadable PS4 game.

A quick google search shows being able to play web games through the browser though. I don’t know how the controller will map to the gamepad API if at all or if you need a separate library for input.

1 Like

I wasn’t thinking of anything complex like a game that would be available as a Blu Ray disc. I was just wondering of the Playcanvas game could be converted to native similarly to PC and then published on the PlayStation Store. The aforementioned game will have the controller support built in. Will this work out?

Making a PlayCanvas or any web app/game to a standalone PC program generally involves using a HTML 5 wrapper like It’s effectively a standalone browser.

On a separate note. Going from PC -> PS4 still requires porting work. It won’t work ‘as-is’.

If you must use PlayCanvas, going through the internet browser is your best bet to have it playable on the PS4. It won’t cost you anything, you don’t have to register as a PS4 developer nor require a dev kit.

1 Like

So the game will work if the Ps4 player types the url in his browser and loads the game?

Let me answer that question. For HTML5 games, the runtime is a web browser and not a platform (PC, mobile or console). Web browser provides translation of all commands to a lower level (operating system level and hardware). In other words, you write the code once and it can run on all platforms where it is possible to install a web browser. But there are problems - it supports WebGL technology in browsers. WebGL 1.0 version is supported almost everywhere, WebGL 2.0 only works in Google Chrome and Mozilla Firefox, as far as I know. You also need to look at the version of the operating system, for example, WebGL only works on Android 4.4 and higher. As for consoles, WebGL support on them is quite low, on this site you can see specific statistics. In addition, I heard that on the PS4 WebGL is specifically disabled in the browser so that players play games only from the official store.

1 Like

Thanks a lot @MasalovAndreey & @yaustar.

That’s a shame. I saw some videos of HTML5 games working in the PS4 browser, I’m going to assume they are canvas only games with no WebGL?

If that’s the case, you probably can use Phaser.js instead of PlayCanvas to make a 2D game.

On a side note, it looks like Xbox One browser supports WebGL.

1 Like

Yes, I saw that Babylon.js engine works on Xbox One. As for PS4, I have not seen games that work on WebGL. Here is a site that is divided by platform. For fun, I ran a few games for PS4 and looked at their source code. They all using 2D context of canvas.

So are the 3D games on Ps4 made with Unreal Engine and/or Unity?

They are made from a variety of engines/code base. Unity and Unreal are common among smaller teams and companies due to accessibility. The larger AAA titles tend to use their own in house custom engine and/or code base for a variety of reasons.

1 Like

Then the best possible way for me to implement it is to design the game in Playcanvas and then convert the scripts to Unreal.

Could you also let me know a good way to monetize my non console games? Portals like CrazyGames aren’t offering me very good revenue…

You can do (I personally wouldn’t) or just use Unreal or Unity to begin with. Given that Unity can build to WebGL (I don’t know if it still has trouble with mobile browsers), that might be your best bet if you want to go multi-platform across web and console.

Not really my area of experience unfortunately. Portals web share, hosting your own server/portal and use incentivised video ads (eg, IAP is another route to go through although you would need to setup player accounts and payment systems, use places like or Kongregate which will help get your game in front of people.

I would also seriously consider creating Facebook Instant Games or other similar messenger games (eg WeChat, Line etc). They have a more captive market (especially on mobile) and you can worry less about rev-share with large name portals.

My biggest concern with releasing a game (especially F2P) is how to get the game in front of people. How will people know about it? And will they keep playing it after the first day?

@devMidgard Did a lot of this type of work in the last year or so: Some of his posts may give you some ideas. Same with True Valhalla

Looking at the rates for CrazyGames, they don’t seem too bad at $1.5-$3 per 1000 plays.

1 Like

Thanks a lot again @yaustar, this is extremely helpful and exactly the advice I needed.

Could you also let me know a good way to monetize my non console games? Portals like CrazyGames aren’t offering me very good revenue…

Your best option is to integrate video ads in your games. I only know of one ad network which lets you implement them without directly having to be enabled by Google Ads (almost impossible for games that aren’t greatly successful), that is - been working a lot with them in the past 2 years and they’re great and will help you on any problem.

Also, you can try out CPMStar’s Anchor Ads. Some clients of mine have had nice results, they’re very easy to implement and test out.

However keep in mind your overall revenue will depend on the amount of traffic you manage to generate. Also, it will be greatly impacted by the main countries that compose your traffic. USA users are the best paid.

1 Like

Thanks a lot @devMidgard. However, CrazyGames doesn’t allow any third party ad services. Could you please suggest another website in which I can just upload my game files and publish? I would greatly appreciate it if you could also advise me as to how to get more players as well.

CrazyGames does allow third party ads, some of my games are in there and they have integrated ads for which they aren’t earning nothing from.