Input combination / modifier keys abstraction
- Dominant language
- Rust
- Stars
- 48.2k
- Forks
- 4.8k
- Avg merge
- 3d 16h
- Merged PRs (30d)
- 171
Description
## What problem does this solve or what need does it fill?
Modifier keys are very commonly used in both games and applications. The existing approach to this is very manual, and heavy on boilerplate. See the [cheatbook page](https://bevy-cheatbook.github.io/cookbook/input-handling.html) for a good overview of how to work with input right now.
## What solution would you like?
Expose a first-class solution for modifier keys in bevy_input. I'm not immediately sure what this would look like, so suggestions are very welcome.
## What alternative(s) have you considered?
Use match statements everywhere, repeatedly. Iterate through eventreader (because that says it is in order) and maintain my own modifier key state as a local resource (credit to `@mattdm` on [Discord](https://discord.com/channels/691052431525675048/742884593551802431/820691893318713344).
## Additional context
None.
Contributor guide
Research direction
Start by reviewing the existing input-handling approach described on the linked cheatbook page and the bevy_input module. Determine a first-class modifier-key API that reduces repeated match statements and local state management, then validate the design against common game and application input use cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- game-dev
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100