Skip to content
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

Bug/touchscreen launch objects #4737

Merged
merged 2 commits into from
Oct 14, 2021
Merged

Conversation

johnshaughnessy
Copy link
Contributor

Might fix #4036

@yakyouk
Copy link
Contributor

yakyouk commented Oct 14, 2021

Would it make sense to change this to be time-based instead of frame-based?
On a poorly optimized scene and/or an older device, responsiveness might be bad - tho arguably, even at 15fps, 8 frames would be just half a second.

@johnshaughnessy
Copy link
Contributor Author

johnshaughnessy commented Oct 14, 2021

@yakyouk

Would it make sense to change this to be time-based instead of frame-based?

I think the correct behavior depends not on time or app-aware-touchscreen ticks, but on having two (worker-thread) physics world ticks with the cursor in the same spot. So the correct fix is probably to have the countdown tied to those physics world ticks instead of the app-aware-touchscreen's ticks.

This PR is not the correct fix, but it is not any more harmful than what we had before. It's bad because it avoids the problem instead of actually solving it.

Copy link
Contributor

@takahirox takahirox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested with this change on Android Chrome, iOS Safari, and iPad. I confirmed that this change improves a lot. I still rarely throw objects but very rare.

Downside of this change may be response time can be a little bit slow. But slow response should be much better than unexpectedly throwing objects.

We might want to fix the root issue at some point, but this workaround is easy and worth. I would like to vote for going with this change so far.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Mobile][Intermittent] The objects are "thrown" away when trying to tap on them
3 participants