User-agent: Mediapartners-Google Disallow: User-agent: * Disallow: /search Allow: / Sitemap: http://nano7mobile.blogspot.com/sitemap.xml Nano Mobile: [Q] App not responding to all taps topic

[Q] App not responding to all taps topic






Hi,

I have been programming a little game and have run into an issue: When I load the game onto my Nexus 5 (Kitkat), not all the taps on the screen are registered.

I have the Android debug option to show taps, so I can see that the OS responds to all taps, but my game only responds to about 50% of them. The AVD in Android Studio responds perfectly to all taps in the game. Has anyone run into this issue before?


Here is the code I use to detect taps:

Code:


List<TouchEvent> touchEvents = game.getInput().getTouchEvents();
. . .
        int len = touchEvents.size();
        for(int i = 0; i < len; i++) {
            TouchEvent event = touchEvents.get(i);
            if(event.type != TouchEvent.TOUCH_UP)
                break;
. . .           
            touchPoint.set(event.x, event.y);
            guiCam.touchToWorld(touchPoint);
. . .








Aucun commentaire:

Enregistrer un commentaire