New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rapid inputs consistently crash Android build #626
Comments
What operating system are you developing from? I'm pretty busy and wouldn't have a lot of time to develop a solution but hopefully I can take a look at this soon |
I'm developing on Fedora Linux. I did some more testing, and by modifying the while loop to remove the touch input if it's null I can reliably avoid crashes:
This doesn't exactly fix the underlying problem, but it will avoid crashing. I'm not doing anything with multitouch inputs in my game, so this serves my purposes well enough. I can make a pull request out of this if you wish, but I'm not sure that this won't cause problems in something requiring multitouch inputs or gestures. |
I can't say it will get merged, I'm not entirely in charge of those kinds of decisions right now. We don't really except "Patch" fixes though. We're also really not trying to add more features to the legacy branch right now if that ends up being the fix (IE some sort of "last input detected" feature). I do want to take a look into it as soon as possible, I don't know when I'll have a chance to get a setup going for Android presently but hopefully soon. Have you tried testing this on multiple Android OS's and devices or just one? Also, if you do submit a pull-request I can potentially see where your fix starts and see if I can investigate from that point on if you prefer not to. |
It's hard to test various versions with so much under the hood changing between OpenFL, Lime, and HaxePunk, so I am currently only able to confirm that this issue occurs with the versions I have listed.
While developing my Android game, I found that repeatedly tapping the screen will crash the app. It's easy to reproduce; I found that drumming two fingers on the screen rapidly for a few seconds will cause the crash, but sometimes it takes a little longer. Here is the stack trace:
From the testing I was able to do, it seems that the same touch (judging by the touchID) is being handled twice during my rapid tapping. I think the first time it's handled it gets removed when my finger leaves the screen, but then it is handled again and it's null.
The text was updated successfully, but these errors were encountered: