-
-
Notifications
You must be signed in to change notification settings - Fork 97
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
Implement directional gamepad vibration #11642
Comments
As far as I can see general controllers don't support this, they usually have two motors of different type, vibrating with high or low intensity On windows the high low magnitude arguments are passed to the left and right motors (see the XINPUT documentation on this What controllers support directional vibration (I assume Switch JoyCons can possibly be vibrated separately) |
|
Took apart the xbox controller to see how it behaves. It seems it behaves even stranger. weak_magnitude affects the right body motor while the strong_magnitude affects the left body motor. under no circumstance trigger motors rotates. i thought weak magnitude would rotate the trigger motors as the name suggest. |
Update: It seems the XInputOnGameInput.h header for the xinput_vibration_ex is xbox only. However I found that SDL does exactly what I am trying to do in a platform agnostic manner. |
Update 2: Implemented SDL. It works like a charm. I am still not sure what I am doing with SConstruct but it was relatively easy to make it work lol. |
This will likely have to wait on that proposal to be implemented. |
Describe the project you are working on
A game uses gamepad
Describe the problem or limitation you are having in your project
Godot doesn't allow left and right side of the gamepad to vibrate independently
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Make it possible to determine the direction of vibration while calling start_joy_vibration function
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
either change the signature of start_joy_vibration or add a start_directional_joy_vibration function with following signature
start_directional_joy_vibration(device: int, left_weak_magnitude: float, left_strong_magnitude: float, right_weak_magnitude: float, right_strong_magnitude: float, duration: float = 0)
If this enhancement will not be used often, can it be worked around with a few lines of script?
no
Is there a reason why this should be core and not an add-on in the asset library?
It is about Input core
The text was updated successfully, but these errors were encountered: