mirror of
https://github.com/bevyengine/bevy
synced 2024-11-14 00:47:32 +00:00
1fccb99d3a
# Objective - Enable the `axis_dpad_to_button` gilrs filter to map hats to dpad buttons on supported remotes. - Fixes https://github.com/Leafwing-Studios/leafwing-input-manager/issues/149 - Might have fixed the confusion related to https://github.com/bevyengine/bevy/issues/3229 ## Solution - Enables the `axis_dpad_to_button` filter in `gilrs` which will use it's remote mapping information to see if there are hats mapped to dpads for that remote model. I don't really understand the logic it uses exactly, but it is usually enabled by default in gilrs and I believe it probably leads to more intuitive mapping compared to the current situation of dpad buttons being mapped to an axis. - Removes the `GamepadAxisType::DPadX` and `GamepadAxisType::DPadY` enum variants to avoid user confusion. Those variants should never be emitted anyway, for all supported remotes. --- ## Changelog ### Changed - Removed `GamepadAxisType::DPadX` and `GamepadAxisType::DPadY` in favor of using `GamepadButtonType::DPad[Up/Down/Left/Right]` instead. ## Migration Guide If your game reads gamepad events or queries the axis state of `GamePadAxisType::DPadX` or `GamePadAxisType::DPadY`, then you must migrate your code to check whether or not the `GamepadButtonType::DPadUp`, `GamepadButtonType::DPadDown`, etc. buttons were pressed instead. |
||
---|---|---|
.. | ||
src | ||
Cargo.toml |