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

How do I release the DPAD without gamepad.reset() ? #9

Closed
ANTONIOPSD opened this issue Mar 1, 2022 · 3 comments
Closed

How do I release the DPAD without gamepad.reset() ? #9

ANTONIOPSD opened this issue Mar 1, 2022 · 3 comments

Comments

@ANTONIOPSD
Copy link

Is there any function to release the DPAD? I'm currently using gamepad.reset() specifically for that, but of course that releases all the buttons that are pressed at the same time.

Can the 0 and 1 values be passed to the DPAD?

Anyways, thanks for your work.

@yannbouteiller
Copy link
Owner

Hi, are you using X360 or DS4? Because they call DPAD different things.

With X360 it should be, e.g.:

gamepad.release_button(button=vg.XUSB_BUTTON.XUSB_GAMEPAD_DPAD_LEFT)

And with DS4 it should be:

gamepad.directional_pad(direction=vg.DS4_DPAD_DIRECTIONS.DS4_BUTTON_DPAD_NONE)

Doesn't that work?

@ANTONIOPSD
Copy link
Author

ANTONIOPSD commented Mar 2, 2022

Hi, are you using X360 or DS4? Because they call DPAD different things.

With X360 it should be, e.g.:

gamepad.release_button(button=vg.XUSB_BUTTON.XUSB_GAMEPAD_DPAD_LEFT)

And with DS4 it should be:

gamepad.directional_pad(direction=vg.DS4_DPAD_DIRECTIONS.DS4_BUTTON_DPAD_NONE)

Doesn't that work?

OMG, seriously? It works... I feel dumb right now😅 , thanks for your work.

@yannbouteiller
Copy link
Owner

Haha no worries, enjoy ;)

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

No branches or pull requests

2 participants