quilt-standard-libraries icon indicating copy to clipboard operation
quilt-standard-libraries copied to clipboard

Key Binds API

Open EnnuiL opened this issue 2 years ago • 4 comments

A built-from-scratch API that covers Fabric Key Binding API's functionality and more

The PR was planned in two stages: Blue and Pink. The implemented feature set of Blue was:

  • Key binds now support being dynamically disabled, making them completely invisible to the game's eyes
  • The Key Binds screen now shows a tooltip on conflicting keys showing the other key binds that use the same key, and adds a (!) indicator to the key text itself for accessibility reasons
  • The API exposes some methods meant to help with mod intercompatibility

Currently, work is being done on the Pink feature set:

  • [ ] A custom config file at ./config/qsl/key_binds.json allowing for our own key bind extensions (WIP)
  • [ ] Key binds now accepts key chords, expanding the possibilities for modded key binds (WIP)
  • [ ] Key binds will contain key predicates, which essentially points all the use cases where it will be used. This will allow multiple key binds that never overlaps to share the same key

Outdated but relevant information about the stages is available in #61

EnnuiL avatar Dec 02 '21 21:12 EnnuiL

Now is the time for any last-minute bikesheds on where to put the keybindings API, since I know people are unhappy with gui

TheGlitch76 avatar Dec 02 '21 22:12 TheGlitch76

gui isn't perfect, but its the closest large group in my opinion.

you could make an input or client group, but then we end up with 30 different modules

OroArmor avatar Dec 02 '21 22:12 OroArmor

A custom config file at ./config/qsl/key_binds.json allowing for our own key bind extensions (WIP)

Now that I'm thinking of it, probably should be ./config/quilt/key_binds.json.

LambdAurora avatar Mar 12 '22 17:03 LambdAurora

A custom config file at ./config/qsl/key_binds.json allowing for our own key bind extensions (WIP)

Now that I'm thinking of it, probably should be ./config/quilt/key_binds.json.

I thought about it (after all, FAPI used ./config/fabric/), however, I don't know; I'd think ./config/quilt/ would instead be used by something like the Quilt Loader, and not QSL

EnnuiL avatar Mar 13 '22 02:03 EnnuiL