Skip to content

Add possibility to add actions for hotkeys.#51

Open
EgzoT wants to merge 1 commit intootland:masterfrom
EgzoT:master
Open

Add possibility to add actions for hotkeys.#51
EgzoT wants to merge 1 commit intootland:masterfrom
EgzoT:master

Conversation

@EgzoT
Copy link

@EgzoT EgzoT commented Jun 2, 2020

System for binding predefined actions with hotkeys module.

Api for external mods/modules.

Add action to action list:
modules.game_hotkeys.addAction(moduleName, actionName, function)

Remove action from action list:
modules.game_hotkeys.removeAction(moduleName, actionName)
or for all module actions:
modules.game_hotkeys.removeAction(moduleName)

How it's look in game_hotkeys module (new buttons "Add action" / "Clear action", new hotkey type "Action"):
image

List with actions:
image

  • Added first action - [game_hotkeys] [toggle] - toggle hotkeys window.

Limitations:

  • To add action, mod/module must be load after game_hotkeys module.
  • Module game_hotkeys works only after login to game.

Related with:
edubart#217

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

Successfully merging this pull request may close these issues.

1 participant