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

Support multiple joysticks #37

Merged
merged 1 commit into from
Nov 24, 2023

Conversation

brollin
Copy link
Contributor

@brollin brollin commented Jun 29, 2022

I saw the other pull request for fixing this same problem, but I think this solution may be cleaner.

Support multiple joysticks by saving the ID of the touch point when a canvas is touched. Then when a touch is ended anywhere in the document, each joystick compares the ended touch ID with the touch ID associated with its canvas to know whether to honor that touch end event.

By the way, didn't see a way to generate the minified JS. Would recommend including a command to do so somewhere, perhaps as a npm script.

Support multiple joysticks by saving the ID of the touch point when a
canvas is touched. Then when a touch is ended anywhere in the document,
each joystick compares the ended touch ID with the touch ID associated
with its canvas to know whether to honor that touch end event.
@nguterresn
Copy link

nguterresn commented Dec 22, 2022

Absolutely agree with you. This one looks like an easy and clean fix.

Is anyone maintaining this repo? Would like to fix this officially on my side as well!

They probably use this website to minify the js code.

@top-kat
Copy link

top-kat commented Nov 22, 2023

@bobboteck any plans on merging this ? This would be very helpful :)

@bobboteck bobboteck merged commit 7be970e into bobboteck:master Nov 24, 2023
@bobboteck
Copy link
Owner

@top-kat @nguterresn @brollin sorry for late merge, but I'm too busy in this period of my life, can you test if all is ok?

@top-kat
Copy link

top-kat commented Nov 24, 2023

Tested everything is working fine :) Thanks a lot @bobboteck and good luck to handle everything ;)

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.

4 participants