Join GitHub today
Gamepad API stopped working as of NW.js 0.33 #6792
NWJS Version : 0.33.0 - 0.33.2
Sample package.nw: https://www.dropbox.com/s/6y74d9e7f479pq4/package.nw?dl=0
The gamepad API worked in NW.js 0.32 and before, but seems to have stopped working in NW.js 0.33.
As of NW.js 0.33, navigator.getGamepads() returns nothing even if you have a gamepad connected and press buttons on it. It still works in Chrome. It also works in NW.js if you simply load http://html5gamepad.com/ in NW.js, so the problem seems specific to using the gamepad API in a local packaged app.
How to reproduce
Drop the linked package.nw in to a fresh download of NW.js 0.33.x and run it. Press a button on a gamepad; it should indicate the gamepad name and allow you to control the space ship. Instead nothing happens. Press F12 and run navigator.getGamepads() - it returns an empty list.