About this mod
Quickly display your keybinds. Instantly updates when you change keybinds. Supports many popular mods. Includes a simple framework for mod authors to add support.
- Requirements
- Permissions and credits
- Changelogs
While I am hoping mod authors will add support on their end going forward, I have included built in support for the following mods to get the ball rolling.
- Just Assorted Mods
- Enhanced Movement
- B42 Quick Throw
- B42 Bash
- B42 Inspect
- B42 Wristwatch
- B42 Realtime Weapon Modding
- B42 True Leaning
- B42 Firemode
- B42 ISControl*
- B42 Hip Control*
- B42 Optics*
- lStewieAl's Tweaks and Engine Fixes
My own mods with keybinds have already been updated to add support.
* The hotkey for these mods are hardcoded, and there is no good way for me to discover them in a script, so if you have customized it, you will need to update the ini file that gets generated by this mod, in order to match your key. The path to the generated ini file is Data\Config\kbqd\KBQuickDisplay.ini, for MO2 users, this will be in your overwrite folder.
Simply set a public Auxiliary variable on the RedKeyCard base form. The name of your variable will determine the category it gets put into and the name of the action as it is shown. Use "::" to separate the category name from the action name. The float that you assign should be the DirectX scancode if it is a single keybind.
AuxVarSetFlt "*_J.A.M::Bullet Time" 45 0 RedKeyCard
Will display as:
Bullet Time X
Further entries with the same category will be grouped together, for example, if you added:
AuxVarSetFlt "*_J.A.M::Visual Objectives" 49 0 RedKeyCard
You would now see:
Visual Objectives N
Bullet Time X
For key combos (meaning users need to press 2 keys to trigger your action) simply add a second float at the next index under an identical name.
AuxVarSetFlt "*_B42::Optics" 157 0 RedKeyCard
AuxVarSetFlt "*_B42::Optics" 54 1 RedKeyCard
Would display as:
Optics R-Shift+R-Ctrl
To display a game control + key combo, include "**" at the end of your variable name.
AuxVarSetFlt "*_B42::IS Control**" 6 0 RedKeyCard
AuxVarSetFlt "*_B42::IS Control**" 54 1 RedKeyCard
Will display as:
IS Control Mouse2+R-Shift
To display a control + control combo, include "++" at the end of your combo. Example:
AuxVarSetFlt "*_My Group::My Action++" 8 0 RedKeyCard
AuxVarSetFlt "*_My Group::My Action++" 27 1 RedKeyCard
Will display as:
My Action L-Ctrl+Z
To display a game control keybind, include "--" at the end of your AuxVar name. Example:
AuxVarSetFlt "*_My Group::My Action--" 6 0 RedKeyCard
Will display as:
My Action Mouse 2
Displaying arbitrary strings (Added in 2.0)
To display an arbitrary string, use "$$". To display a string + game control combo, use "$+". To display a string + key combo, use "$*".
AuxVarSetStr "*_Examples::Arbitrary String$" "Hello World" 0 RedKeyCard
AuxVarSetStr "*_Examples::String & Control$+" "Hold" 0 RedKeyCard
AuxVarSetFlt "*_Examples::String & Control$+" 6 1 RedKeyCard
AuxVarSetStr "*_Examples::String & Key$*" "String +" 0 RedKeyCard
AuxVarSetFlt "*_Examples::String & Key$*" 258 1 RedKeyCard
Will display as:
Arbitrary String Hello World
String & Control Hold Mouse 2
String & Key String + Mouse Wheel
The list of keybinds to display will get built when the "QueryKeybinds" event is called via DispatchEventAlt. Your Auxiliary Variables need to be set inside an event handler that will run via DispatchEventAlt "QueryKeybinds". This is because all of these AuxVars will get erased after Quick Display is shown.
Setting the event handler should be done in the GetGameLoaded portion of your main script. Example:
if GetGameLoaded
SetEventHandlerAlt "QueryKeybinds" (begin function {}
if eval bAction1Enabled ; Only set up the AuxVar if the corresponding action is enabled
AuxVarSetFlt "*_My Category::Action1" MyQuest.iKeycode1 0 RedKeyCard
endif
if eval bAction2Enabled
AuxVarSetFlt "*_My Category::Action2" MyQuest.iKeycode2 0 RedKeyCard
endif
; etc.
end)
endif
For the sake of consistency, if you wish the category name to be 'Miscellaneous', or 'Misc', write it just as an all caps capital 'ZZZ'. For example:
AuxVarSetFlt "*_ZZZ::Open Journal" 199 0 RedKeyCard
Will display as:
Open Journal Home
This is to avoid creating 'Misc.', 'Misc', 'Miscellaneous' etc. categories from different mods. It will also ensure that it is the last category displayed.
You can find a bunch of examples already included to provide support for the mods listed at the top. If you are the author of one of the mods that is already supported and you want me to remove them so you can add support on your end, just send me a DM.