User:Taz/Scratchpad-lotro.keymap Reference
lotro.keymap Reference
The LotRO game client stores keybindings in the lotro.keymap file in the game's preferences folder. If this file is missing when the game client starts, one with default contents will be created.
Most players will change keybindings on the game client's Options/Keymapping panel. Changes made in-game will update this file as they are made, and the file will be rewritten when the game client closes.
Copying this file from one computer to another is often enough to recreate a custom keymap on the second system.
The key bindings associate keypresses with in-game actions, such as opening a window or using an object. The action names (referred to herein as "function names") can be used by plugins to sense the associated keypresses via KeyUp and KeyDown events[1].
File Locations
- PC client: %USERPROFILE%\Documents\The Lord of the Rings Online\lotro.keymap
- PC client under WINE: ~/Documents/The Lord of the Rings Online/lotro.keymap
- Mac Client: ~/Library/Application Support/com.turbine.lotroclient/lotro.keymap
Editing (Handle with Care)
Use the game client's Options/Keymapping panel to set keybindings whenever possible. Unfortunately, some changes cannot be made with the options panel. If you must edit this file by hand:
- 1. copy the file to a backup location (eg lotro.keymap.backup)
- 2. copy the file to a new name for editing (eg lotro.keymap.changes)
- 3. edit with Notepad or your favourite text editor
- 4. while the game client is closed, copy the changed file to the original location (lotro.keymap)
- 5. start the game client and test your changes
If the game doesn't accept all of the changes, compare the live version to the attempted changes to help find syntax mistakes or other issues. You can always copy the lotro.keymap.backup file to lotro.keymap to restore the earlier version.
lotro.keymap File Layout
The keymap file is well commented regarding its subsections and keybinding syntax. As a brief overview:
- 1. Devices: gives each input device an index for reference in later sections.
- 2. MetaKeys: assigns each modifier key (shift, ctrl, alt, etc) an index in a bitfield for reference in keybinding sections.
- 3. Bindings:
- a. Main: primary game functions. Most of the functions configurable ingame through the Options/Keymapping panel are in this subsection.
- b. EditControls: typical cursor-movement functions for text input (search fields, biography, chat window, etc).
- c. SelectionUI: (?)
- d. MusicUI: music playing functions.
- e. MapPanel: (empty)
- f. VendorBuyUI: functions for purchasing multiple items at a vendor.
- g. ScrollableControls: (empty)
- h. ScrollableControls_Mouse: page-scrolling functions.
- i. CopyAndPasteControls: typical Ctrl-C, Ctrl-X, Ctrl-V support functions for text input.
- j. DialogBoxes: (?) (seems to be for moving input focus between in-game panels, but unknown if this is functional. perhaps in-game browser?)
- k. DebugConsole: (?) (suspect inactive in live game client)
- l. StringTokenDebugger: (?) (suspect inactive in live game client)
The following will touch on each of the main sections. Comment lines from the lotro.keymap file are included to provide context to the breakdown for each section.
Devices
This section of the file is a simple list of devices that can be referenced in later sections. The keyboard is always device 0 and the mouse is always device 1; they do not need to be listed. Other devices are indexed in the order listed in this section.
lotro.keymap File Comments |
---|
This section gets filled out on end-user machines if they have additional input devices connected. The keyboard is ALWAYS device 0 and the mouse is ALWAYS device 1 so these don't have to be listed, but I support listing them anyway since that tends to make things clear when figuring out what index to use in your control. |
MetaKeys
MetaKeys are the modifier keys used in a keybinding. The MetaKeys section itself defines the modifier's value by it's location in a bitfield. In the Bindings section, the combination of values for all modifiers used in a binding gives the MetaKeyValue. MetaKeyValues are in hexadecimal.
lotro.keymap File Comments |
---|
To define your own meta keys you can edit the following table. The first entry is which meta-key bit you are defining, this number must be between 1 and 32. The second number is a device index from the table above, for example 0 is your keyboard and 1 is your mouse. The third number is the identifier for which button is used for the key. Note that multiple keys can toggle the same meta-key bit, for example both the left and right keyboard keys toggle the same bit. Later in the Bindings table you can specify that one or more meta-keys are required by combining the bits from the MetaKeys table, for example Control+Alt would use a value of 0x06. Note that only buttons can be used as meta-keys, you cannot use Axis, Slider, or POV controls as meta-keys. |
Syntax Reference
MetaKey Syntax Expanded |
---|
<Bit> [ <Device> <KeyIndex> ]
|
Default MetaKeys
The following table shows the default MetaKey bit location assignments and their corresponding values, and provides examples of user-defined MetaKeys.
Default MetaKeys | |||
---|---|---|---|
Bit | Key(s) | base MetaKeyValue (hex) | bit view |
1 | LShift, RShift | 0x001 | 0000 0001 |
2 | LCtrl, RCtrl | 0x002 | 0000 0010 |
3 | LAlt, RAlt | 0x004 | 0000 0100 |
4 | LWin, RWin | 0x008 | 0000 1000 |
5 | Mouse3 | 0x010 | 0001 0000 |
6 | Mouse4 | 0x020 | 0010 0000 |
7 | Mouse0 (Left Mouse) | 0x040 | 0100 0000 |
8 | Mouse1 (Right Mouse) | 0x080 | 1000 0000 |
this scheme supports up to 32 different modifiers | |||
9 | UserMeta9 | 0x100 | 0001 0000 0000 |
10 | UserMeta10 | 0x200 | 0010 0000 0000 |
32 | UserMeta32 | 0x80000000 | 1000 0000 0000 0000 0000 0000 0000 0000 |
MetaKeyValue Examples
The following table shows the resulting MetaKeyValues for each combination of the default keyboard MetaKeys.
MetaKeyValue Examples | |||
---|---|---|---|
MetaKey(s) | base values (hex) | combined MetaKeyValue (hex) | bit view |
None | 0x00 | 0x00 | 0000 0000 |
Shift | 0x01 | 0x01 | 0000 0001 |
Ctrl | 0x02 | 0x02 | 0000 0010 |
Shift+Ctrl | 0x01 + 0x02 | 0x03 | 0000 0011 |
Alt | 0x04 | 0x04 | 0000 0100 |
Shift+Alt | 0x01 + 0x04 | 0x05 | 0000 0101 |
Ctrl+Alt | 0x02 + 0x04 | 0x06 | 0000 0110 |
Shift+Ctrl+Alt | 0x01 + 0x02 + 0x04 | 0x07 | 0000 0111 |
Win | 0x08 | 0x08 | 0000 1000 |
Shift+Win | 0x01 + 0x08 | 0x09 | 0000 1001 |
Ctrl+Win | 0x02 + 0x08 | 0x0a | 0000 1010 |
Shift+Ctrl+Win | 0x01 + 0x02 + 0x08 | 0x0b | 0000 1011 |
Alt+Win | 0x04 + 0x08 | 0x0c | 0000 1100 |
Shift+Alt+Win | 0x01 + 0x04 + 0x08 | 0x0d | 0000 1101 |
Ctrl+Alt+Win | 0x02 + 0x04 + 0x08 | 0x0e | 0000 1110 |
Shift+Ctrl+Alt+Win | 0x01 + 0x02 + 0x04 + 0x08 | 0x0f | 0000 1111 |
Bindings
The Bindings section of the lotro.keymap file is where individual keybindings are defined. Each subsection consists of a number of lines that map a control combination to a function.
- Generally, control combinations must be unique within a subsection, but the same control combination can be reused in other subsections. For example, the Shift+1 control is used for Quickslot 37 in the Main subsection, and again for Note C4 in the Music subsection.
- Functions can be used multiple times within a subsection as long as the control combinations differ. For example, Note C4 in the Music subsection is bound once to 8 and again to Shift+1.
lotro.keymap File Comments |
---|
Device is an index from the device table. KeyIndex is a matching DIK_*, DIMOFS_*, or DIJOFS_* define (see DInput.h for possible values) depending on whether the device is a Keyboard, Mouse, or Joystick/Gamepad. Controls can be modidied by an optional MetaKey value, this value is an integer which combines any number of the bits defined in the MetaKeys table. The same button can be defined with different meta-key values but not with exactly the same meta-key modifiers. When selecting an action in response to user input the action that matches the largest number of modifiers is the action that gets selected. For example, if I define an action for X, Shift+X, and Control+X and then I enter Alt+Shift+X this will match the Shift+X action. If two or more actions match the same number of bits then the action with the lowest index wins. Using the previous example, if I pressed Ctrl+Shift+X it will match Shift+X and not Control+X because shift is assigned a lower index in the MetaKeys table above (shift is index 1, control is index 2). ActivationType is a modifier for how the button is pressed, for example you can say Up, Down, DblClick, Tap, or Analog. You can modify DblClick with the keyword Nearby to indicate that you only want a double click to count if the mouse cursor hasn't moved very far. You can combine these bits to get notifed of multiple events. By default you get Down and Up. Note that a "Tap" is also a ButtonUp, the tap is just a modifier. Also note that DblClick is also a ButtonDown. No two controls can register for the exact same Activation of the same control but you can have different actions for ButtonDown and DblClick, or ButtonUp and Tap. Oh, SubControl is used for forming virtual buttons from sub-ranges of an analog control, valid values are POVUp, POVRight, POVDown, POVLeft, AxisPositive, and AxisNegative. |
Basic Syntax
The basic syntax of a binding is:
Function [ <Status> [ <Device> <KeyIndex> ] <MetaKeyValue> ]
MetaKeyValue is optional; the other parts are required. As examples, here are the default bindings for move forward (W), which uses no MetaKeyValue, and toggle lantern (Alt+F10):
MovementForward [ Old [ 0 DIK_W ] ] ADMIN_LIGHT [ Old [ 0 DIK_F10 ] 0x00000004 ]
A more complete syntax looks like the following. SubControl, MetaKeyValue, and ActivationType are all optional.
Function [ <Status> [ <Device> <KeyIndex> <SubControl> ] <MetaKeyValue> <ActivationType> ]
Here are two default bindings for zoom out (mousewheel down) showing SubControl, and a selection function (mouse button0 doubleclick) showing ActivationType use:
CameraInstantMoveAway [ Old [ 1 DIMOFS_Z AxisNegative ] ] SelectDblLeft [ Old [ 1 DIMOFS_BUTTON0 ] 0x00000000 MouseDblClick ]
Syntax Reference
Binding Syntax Expanded |
---|
Function [ <Status> [ <Device> <KeyIndex> <SubControl> ] <MetaKeyValue> <ActivationType> ]
|
Function Reference
In-Game Accessible Functions
The following tables map the labels in the game client's Options/Keymapping panel to function names in the keymap file. They are presented in the panel's ordering.
Movement | |
---|---|
InGame Label | Function Name |
Move Forward | MovementForward |
Move Forward (Camera) | MovementForwardCameraMovement |
Move Backwards | MovementBackup |
Turn Left | MovementTurnOrStrafeLeft |
Turn Right | MovementTurnOrStrafeRight |
Strafe Left | MovementStrafeLeft |
Strafe Right | MovementStrafeRight |
Jump | MovementLongJump |
Walk Mode | MovementWalkMode |
Lock Run Forward | MovementRunLock |
Quickslots | |
---|---|
InGame Label | Function Name |
Quickslot Page Up | Quickslot_Page_Up |
Quickslot Page Down | Quickslot_Page_Down |
Quickslot (1-72) | QUICKSLOT_1 (1-72) |
QuickBar 1 Visibility | QUICKSLOT_CTRL_META |
QuickBar 2 Visibility | QUICKSLOT_ALT_META |
QuickBar 3 Visibility | QUICKSLOT_SHIFT_META |
QuickBar 4 Visibility | QUICKSLOT_EXTRABAR1_META |
QuickBar 5 Visibility | QUICKSLOT_EXTRABAR2_META |
Selection | |
---|---|
InGame Label | Function Name |
Select Self | SELECTION_SELF |
Select Nearest Foe | SELECTION_NEAREST_FOE |
Select Next Foe | SELECTION_NEXT_FOE |
Select Previous Foe | SELECTION_PREVIOUS_FOE |
Select Next Tracked | SELECTION_NEXT_TRACKED |
Select Previous Tracked | SELECTION_PREVIOUS_TRACKED |
Select Fellow (1-6) | SelectFellowOne (Two, Three, Four, Five, Six) |
Assist Fellow (2-6) | AssistFellowTwo (Three, Four, Five, Six) |
Select Nearest Fellow | SELECTION_NEAREST_FELLOW |
Select Nearest Player | SELECTION_NEAREST_PC |
Select Next Player | SELECTION_NEXT_PC |
Select Previous Player | SELECTION_PREVIOUS_PC |
Select Nearest NPC | SELECTION_NEAREST_CREATURE |
Select Next NPC | SELECTION_NEXT_CREATURE |
Select Previous NPC | SELECTION_PREVIOUS_CREATURE |
Select Nearest Item | SELECTION_NEAREST_ITEM |
Select Next Item | SELECTION_NEXT_ITEM |
Select Previous Item | SELECTION_PREVIOUS_ITEM |
Previous Selection | SELECTION_LAST |
Previous Attacker | SELECTION_LAST_ATTACKER |
Assist | SELECTION_ASSIST |
Panels | |
---|---|
InGame Label | Function Name |
Skills Panel | ToggleSkillPanel |
Traits Panel | ToggleTraitPanel |
Housing Panel | ToggleHousingPanel |
Crafting Panel | ToggleCraftingPanel |
Map Panel | ToggleMapPanel |
Character Journal Panel | ToggleJournalPanel |
Titles Panel | TITLE_VIEW |
Social Panel | ToggleSocialPanel |
Inventory Panel | QUICKSLOT_BACKPACK |
Bag (1-6) | QUICKSLOT_BACKPACK1 (1-6) |
Dressing Room | DressingRoom |
Item Link to Chat Entry | ItemLinkToChat |
Multi-use Item | MultiUseItem |
This Options Panel | ToggleOptionsPanel |
Help Panel | ToggleAssistancePanel |
Toggle Radar On/Off | ToggleRadarPanel |
Toggle Quest Panel On/Off | ToggleQuestPanel |
Toggle Deed Log On/Off | ToggleAccomplishmentPanel |
Legendary Items Panel | ToggleItemAdvancementPanel |
Mounts Panel | ToggleMountsPanel |
Toggle Instance Finder - Specific | ToggleWorldJoin |
Skirmish Panel | ToggleSkirmishPanel |
Toggle Instance Finder | ToggleFellowshipMakerUI |
Toggle Instance Finder - Simple | ToggleFellowshipMakerSimple |
Toggle Instance Finder - Advanced | ToggleFellowshipMakerAdvanced |
Mounted Combat Panel | ToggleMountedCombatUI |
Toggle LOTRO Store On/Off | ToggleWebStore |
Reputation Panel | ShowReputationPage |
Hobby Panel | ToggleHobbyPanel |
Destiny Point Perks Panel | ToggleDestinyPerksVendor |
Fellowing Panel | ToggleSocialFellowingPanel |
Friends Panel | ToggleSocialFriendsPanel |
Kinship Panel | ToggleSocialKinshipPanel |
Raid Panel | ToggleSocialRaidPanel |
Group Stage Panel | ToggleSocialGroupStagePanel |
Wallet | TogglePaperItemPanel |
Hobbit Presents | ToggleRandomItemRewardUI |
Pending Loot | PendingLootUI |
Plugin Manager Panel | TogglePluginManager |
Collections | ToggleCollectionUI |
Filters | ToggleFilterUI |
Chat | |
---|---|
InGame Label | Function Name |
Reply | ChatModeReply |
Miscellaneous | |
---|---|
InGame Label | Function Name |
Toggle Autoattack | QUICKSLOT_SKILLMODE |
Use Selection | USE |
Follow Selection | FOLLOW |
Find Items | FindItems |
Epic Battles | ToggleBigBattlesUI |
MailBox | ToggleMailUI |
Show Names | SHOW_NAMES |
Show Damage | SHOW_DAMAGE |
Screenshot | CaptureScreenshot |
Detach Tooltip | TOOLTIP_DETACH |
Reposition UI | ToggleHiddenDragBoxes |
Lock/Unlock Quickslots | ToggleQuickslotLockState |
Toggle HUD On/Off | UI_TOGGLE |
Logout | LOGOUT |
Voice Push to Talk | VOICECHAT_TALK |
Enable Item Sell Lock | ToggleItemSellLock |
Loot All | AutoLootAll |
Dismount / Remount | DismountRemount |
Show Remote Quest Actions | RemoteQuestAction |
Track Nearby Quests | FindNearbyQuests |
Clear Search Filters | ClearFilters |
Music | |
---|---|
InGame Label | Function Name |
Toggle Music Mode | ToggleMusicMode |
in "MusicUI" section of lotro.keymap | |
Stop Playing Song | MusicEndSong |
Play Note C2 | MUSIC_C2 |
Play Note C#2 | MUSIC_Db2 |
Play Note D2 | MUSIC_D2 |
Play Note D#2 | MUSIC_Eb2 |
Play Note E2 | MUSIC_E2 |
Play Note F2 | MUSIC_F2 |
Play Note F#2 | MUSIC_Gb2 |
Play Note G2 | MUSIC_G2 |
Play Note G#2 | MUSIC_Ab2 |
Play Note A2 | MUSIC_A2 |
Play Note A#2 | MUSIC_Bb2 |
Play Note B2 | MUSIC_B2 |
same for octaves 3-4 (label sharp, function flat) | |
Play Note C5 | MUSIC_C5 |
Fellowship Manoeuvres | |
---|---|
InGame Label | Function Name |
Fellowship Skill Assist | Conjunction_Contribution_Assist |
Top Fellowship Manoeuvre | Conjunction_Contribution_1 |
Bottom Fellowship Manoeuvre | Conjunction_Contribution_2 |
Left Fellowship Manoeuvre | Conjunction_Contribution_3 |
Right Fellowship Manoeuvre | Conjunction_Contribution_4 |
Fellowship Target Marking | |
---|---|
InGame Label | Function Name |
Shield | ToggleTargetMark1 |
Spear | ToggleTargetMark2 |
Arrow | ToggleTargetMark3 |
Sun | ToggleTargetMark4 |
Swords | ToggleTargetMark5 |
Moon | ToggleTargetMark6 |
Star | ToggleTargetMark7 |
Claw | ToggleTargetMark8 |
Skull | ToggleTargetMark9 |
Leaf | ToggleTargetMark10 |
Cosmetic Outfit Selection | |
---|---|
InGame Label | Function Name |
Present Main Inventory | SelectOutfitInventory |
Present Outfit (1-7) | SelectOutfit1 (1-7) |
Camera | |
---|---|
InGame Label | Function Name |
Reset Camera | CameraReset |
Rotate Camera | CameraInstantMouseLook |
Rotate Camera Left | CameraRotateLeft |
Rotate Camera Right | CameraRotateRight |
Pitch Camera Up | CameraRotateUp |
Pitch Camera Down | CameraRotateDown |
Pan Camera In | CameraMoveToward |
Pan Camera Out | CameraMoveAway |
Toggle First/Third Person | CameraFirstPerson |
Toggle Target Lock-on Mode | CameraToggleTargetCam |
Manually Configured Functions
These are keybind functions that can only be changed by editing the lotro.keymap file manually. The game client does not provide access to them within the Options/Keymapping UI.
You can, however, disable or reassign the bound keys within the game client, by assigning the key to an in-game-accessible function. This assignment can be cleared afterward to effectively disable the original keybind.
Manually Configured Functions | ||
---|---|---|
Effect | Function Name | Default Keybind |
Do Nothing | DoNothing This function provides a means of overriding a default keybind without binding it to another action. |
(n/a) |
FPS Toggle | ToggleDebugHUD This toggles the small Frames-per-second UI element. |
Ctrl+F |
Lantern Toggle | ADMIN_LIGHT This toggles the in-game lantern effect. Note this effect is usually only visible at night, and some areas force the effect on while in the area. |
Alt+F10 |
Mouse Move Forward | MovementForwardCameraMovementToggleMouseSteer This function is almost the same as MovementForwardCameraMovement: left and right mouse buttons pressed at the same time will move the character forward. Whichever mouse button is pressed first will be considered the KeyIndex, and the second is treated as the MetaKey. This function is triggered when the left mouse button (MouseButton0) is pressed first. |
Mouse Btn0+Btn1 |
"High" Jump | MovementHighJump This function seems to be identical to MovementLongJump, which is the regular Jump function bound to Space. The in-game jump actions do not appear to differ. |
Shift+Space |
Start Command | START_COMMAND This function moves keyboard focus to the chat entry field and emits the bound character there. |
Slash |
Inactive (Debugging) Functions
These function entries appear to be disabled in the live game client. They may be functional in development builds such as the Bullroarer client. They are listed here with their default keybinds for completeness.
Inactive Functions | |
---|---|
Function Name | Default Keybind |
ToggleAdminPanel | Ctrl+A |
ToggleThreatTrackerPanel | Ctrl+H |
ToggleBlockUI | Shift+Ctrl+Alt+F9 |
TogglePerfGraph | Shift+Ctrl+Alt+F10 |
ToggleMemoryGraph | Shift+Ctrl+Alt+F8 |
ToggleProfiler | Shift+Ctrl+Alt+F11 |
ToggleEntityNodeLabels | Shift+Ctrl+Alt+F12 |
ToggleStringTokenDebugger | Alt+Grave |
CameraFlightMode | Ctrl+Period |
CameraRotateRollReset | NumpadSlash |
CameraRotateRollRight | NumpadPlus |
CameraRotateRollLeft | NumpadMinus |
ToggleDebugConsole | Ctrl+Grave, Pause |