Drew Posted April 18, 2017 Share Posted April 18, 2017 I haven't been able to find this anywhere else yet, but I've noticed that touch events in Phaser are no longer working as of iOS 10.3. I've tested in many browsers and many environments, and it seems to be specific to iOS. Does anybody know if this is known issue in Phaser, and if there are plans to create a fix, or if Apple will be fixing this? Link to comment Share on other sites More sharing options...
rich Posted April 19, 2017 Share Posted April 19, 2017 I just tested several of the input examples on the phaser site on a new 2017 iPad running iOS 10.3.1 and they all worked fine, so I don't believe this is iOS specific - maybe something else? I was using Safari. Link to comment Share on other sites More sharing options...
Drew Posted April 25, 2017 Author Share Posted April 25, 2017 Rich, Thank you for your response. My experience was this. I went to test my application on my iPhone 7, and input events would not work. The code I'm using is: this.mySprite.events.onInputDown.addOnce(this.myFunction, this); myFunction is not called at all, instead I receive the following error: TypeError: this._unlockSource.noteOn is not a function. (In 'this._unlockSource.noteOn(0)', 'this._unlockSource.noteOn' is undefined) unlock — phaser.js 45464 onTouchStart --- phaser.js:22989 _onTouchStart --- phaser.js:22931 To troubleshoot, I tested this on many devices with the following results: 3 different android phones run this application just fine. Ubuntu 16.4 PC - Works fine in Chrome and Firefox MacOS 10.12.3 (Sierra) - Works fine in Chrome, Firefox and Safari Windows 7 PC - Works fine in Chrome and Firefox iPhone 7 running OS X 10.3.1 input events do not fire - This is true in both Safari and Chrome. iPhone 6s running OS X 10.3.1 input events do not fire. iPhone 7 running OS X 10.2 works fine iPad (2nd generation?) OS X 10.2 works fine - Then updated to OS X 10.3.1 and input events would not fire. In short, the ONLY devices I can't get input events to work on are OS X 10.3.1, everything else that I've tested seems to work just fine. Inputs in this same application worked on every one of the 10.3.1 devices prior to update to 10.3.1 I also found this other post, which may be related? I'm curious if anybody else is having similar issues. This seems very clearly related to some issue with OS X 10.3.1 to me. Oddly enough though, I am also able to use the phaser examples just fine on my OS X 10.3.1 devices, including this one, which uses onInputDown: https://phaser.io/examples/v2/input/pixelpick-atlas Link to comment Share on other sites More sharing options...
rich Posted April 26, 2017 Share Posted April 26, 2017 The error above is coming from the SoundManager. It is waiting for the first touch event so it can unlock the sound system. You must have some audio waiting to be played somewhere, which is where the error is coming from, not the input event itself. This is why the input examples work, because they don't have any sound. I'd strongly recommend opening this as an issue on the Phaser CE GitHub repo, and someone can pick it up from there (I will if I get time). Link to comment Share on other sites More sharing options...
Drew Posted April 27, 2017 Author Share Posted April 27, 2017 I just opened up an issue on the Phaser CE GitHub. Thanks for the help Rich! Link to comment Share on other sites More sharing options...
khacthanh244 Posted May 9, 2017 Share Posted May 9, 2017 @Drew I see same issue . How to fix it ? Link to comment Share on other sites More sharing options...
rich Posted May 11, 2017 Share Posted May 11, 2017 This issue was caused by using an outdated version from phaser. Use a recent one and it's fine on iOS 10.3 Lucas Rodrigues 1 Link to comment Share on other sites More sharing options...
Recommended Posts