Minecraft:Key codes: Difference between revisions
More actions
Sync: updated from Minecraft |
Sync: updated from Minecraft |
||
| Line 12: | Line 12: | ||
=== Keyboard codes === | === Keyboard codes === | ||
The displayed names of several keys will change depending on the currently active system keyboard layout. The values displayed in this table assume a standard en-US QWERTY layout. Some keys also have operating system dependent names, which are assigned different rows sharing an ID. | The displayed names of several keys will change depending on the currently active system keyboard layout. The values displayed in this table assume a standard en-US QWERTY layout. Some keys also have operating system dependent names, which are assigned different rows sharing an ID. | ||
| Line 404: | Line 403: | ||
| {{btn|F25}} | | {{btn|F25}} | ||
| colspan="2" | Unclear{{note|Ostensibly for a twenty-fifth function key, but Windows, Linux and presumably macOS only recognise up to F24. Some keyboards from decades past go past F24, and Arch Linux can apparently recognise up to F246, however it is unknown if Minecraft would recognise either of these.}} | | colspan="2" | Unclear{{note|Ostensibly for a twenty-fifth function key, but Windows, Linux and presumably macOS only recognise up to F24. Some keyboards from decades past go past F24, and Arch Linux can apparently recognise up to F246, however it is unknown if Minecraft would recognise either of these.}} | ||
| {{code|key.keyboard.f25 | | {{code|key.keyboard.f25}} | ||
|- | |- | ||
! {{code|key.keyboard.keypad.0}} | ! {{code|key.keyboard.keypad.0}} | ||
| Line 690: | Line 689: | ||
| {{code|key.keyboard.right.meta}}{{upcoming|java 26.3}} | | {{code|key.keyboard.right.meta}}{{upcoming|java 26.3}} | ||
|- | |- | ||
! {{code|key.keyboard.lang1}}{{upcoming|java 26.3}}<ref name="genericintl"> | ! {{code|key.keyboard.lang1}}{{upcoming|java 26.3}}<ref name="genericintl">Mojang have chosen to assign generic, non-descriptive titles to these keys, matching their internal SDL3 IDs rather than the actual real-life key names: {{bug|MC-311175}}</ref> | ||
| {{btn|Language 1}}<ref name="genericintl"/> | | {{btn|Language 1}}<ref name="genericintl"/> | ||
| colspan="2" | {{key|Hangul}} | | colspan="2" | {{key|Hangul}} | ||
| Line 739: | Line 738: | ||
| colspan="2" | {{key|Muhenkan}} | | colspan="2" | {{key|Muhenkan}} | ||
| {{code|key.keyboard.international5}}<ref name="genericintl"/> | | {{code|key.keyboard.international5}}<ref name="genericintl"/> | ||
|- | |||
! {{code|key.keyboard.international6}}{{upcoming|java 26.3}}<ref name="generic9800">{{bug|MC-311184}}</ref> | |||
| {{btn|International 6}}<ref name="generic9800"/> | |||
| colspan="2" | {{key|Numpad ,}} (PC-9800){{note|Windows only; it is assumed that KEY_KPJPCOMMA is meant to represent this on Linux, but is incorrectly bound to International 5 - see https://github.com/libsdl-org/SDL/pull/16168}} | |||
| {{code|key.keyboard.international6}}<ref name="generic9800"/> | |||
|- | |- | ||
! {{code|key.keyboard.mute}}{{upcoming|java 26.3}} | ! {{code|key.keyboard.mute}}{{upcoming|java 26.3}} | ||
| Line 759: | Line 763: | ||
| colspan="2" | {{key|Media Play Pause}} | | colspan="2" | {{key|Media Play Pause}} | ||
| {{code|key.keyboard.media.play.pause}} | | {{code|key.keyboard.media.play.pause}} | ||
|- | |||
! {{code|key.keyboard.media.play}}{{upcoming|java 26.3}} | |||
| {{btn|Media Play}} | |||
| colspan="2" | {{key|Media Play}} | |||
| {{code|key.keyboard.media.play}} | |||
|- | |||
! {{code|key.keyboard.media.pause}}{{upcoming|java 26.3}} | |||
| {{btn|Media Pause}} | |||
| colspan="2" | {{key|Media Pause}} | |||
| {{code|key.keyboard.media.pause}} | |||
|- | |||
! {{code|key.keyboard.media.record}}{{upcoming|java 26.3}} | |||
| {{btn|Record}} | |||
| colspan="2" | {{key|Media Record}} | |||
| {{code|key.keyboard.media.record}} | |||
|- | |||
! {{code|key.keyboard.media.fast.forward}}{{upcoming|java 26.3}} | |||
| {{btn|Fast Forward}} | |||
| colspan="2" | {{key|Media Fast Forward}} | |||
| {{code|key.keyboard.media.fast.forward}} | |||
|- | |||
! {{code|key.keyboard.media.rewind}}{{upcoming|java 26.3}} | |||
| {{btn|Rewind}} | |||
| colspan="2" | {{key|Media Rewind}} | |||
| {{code|key.keyboard.media.rewind}} | |||
|- | |||
! {{code|key.keyboard.media.next.track}}{{upcoming|java 26.3}} | |||
| {{btn|Next Track}} | |||
| colspan="2" | {{key|Media Next Track}} | |||
| {{code|key.keyboard.media.next.track}} | |||
|- | |||
! {{code|key.keyboard.media.previous.track}}{{upcoming|java 26.3}} | |||
| {{btn|Previous Track}} | |||
| colspan="2" | {{key|Media Previous Track}} | |||
| {{code|key.keyboard.media.previous.track}} | |||
|- | |||
! {{code|key.keyboard.media.stop}}{{upcoming|java 26.3}} | |||
| {{btn|Media Stop}} | |||
| colspan="2" | {{key|Media Stop}} | |||
| {{code|key.keyboard.media.stop}} | |||
|- | |||
! {{code|key.keyboard.media.eject}}{{upcoming|java 26.3}} | |||
| {{btn|Eject}} | |||
| colspan="2" | {{key|Media Eject}} | |||
| {{code|key.keyboard.media.eject}} | |||
|- | |||
! {{code|key.keyboard.media.select}}{{upcoming|java 26.3}} | |||
| {{btn|Media Select}} | |||
| colspan="2" | {{key|Media Select}} | |||
| {{code|key.keyboard.media.select}} | |||
|- | |- | ||
! {{code|key.keyboard.stop}}{{upcoming|java 26.3}} | ! {{code|key.keyboard.stop}}{{upcoming|java 26.3}} | ||
| Line 764: | Line 818: | ||
| colspan="2" | {{key|Stop}} | | colspan="2" | {{key|Stop}} | ||
| {{code|key.keyboard.stop}} | | {{code|key.keyboard.stop}} | ||
|- | |||
! {{code|key.keyboard.cancel}}{{upcoming|java 26.3}} | |||
| {{btn|Cancel}} | |||
| colspan="2" | {{key|Cancel}} | |||
| {{code|key.keyboard.cancel}} | |||
|- | |- | ||
! {{code|key.keyboard.cut}}{{upcoming|java 26.3}} | ! {{code|key.keyboard.cut}}{{upcoming|java 26.3}} | ||
| Line 794: | Line 853: | ||
| colspan="2" | {{key|Application New}} | | colspan="2" | {{key|Application New}} | ||
| {{code|key.keyboard.ac.new}} | | {{code|key.keyboard.ac.new}} | ||
|- | |||
! {{code|key.keyboard.ac.open}}{{upcoming|java 26.3}} | |||
| {{btn|AC Open}} | |||
| colspan="2" | {{key|Application Open}} | |||
| {{code|key.keyboard.ac.open}} | |||
|- | |- | ||
! {{code|key.keyboard.ac.save}}{{upcoming|java 26.3}} | ! {{code|key.keyboard.ac.save}}{{upcoming|java 26.3}} | ||
| Line 809: | Line 873: | ||
| colspan="2" | {{key|Find}} | | colspan="2" | {{key|Find}} | ||
| {{code|key.keyboard.find}} | | {{code|key.keyboard.find}} | ||
|- | |||
! {{code|key.keyboard.ac.close}}{{upcoming|java 26.3}} | |||
| {{btn|AC Close}} | |||
| colspan="2" | {{key|Application Close}} | |||
| {{code|key.keyboard.ac.close}} | |||
|- | |||
! {{code|key.keyboard.ac.exit}}{{upcoming|java 26.3}} | |||
| {{btn|AC Exit}} | |||
| colspan="2" | {{key|Application Exit}} | |||
| {{code|key.keyboard.ac.exit}} | |||
|- | |||
! {{code|key.keyboard.ac.stop}}{{upcoming|java 26.3}} | |||
| {{btn|AC Stop}} | |||
| colspan="2" | {{key|Application Stop}} | |||
| {{code|key.keyboard.ac.stop}} | |||
|- | |||
! {{code|key.keyboard.ac.properties}}{{upcoming|java 26.3}} | |||
| {{btn|AC Properties}} | |||
| colspan="2" | {{key|Application Properties}} | |||
| {{code|key.keyboard.ac.properties}} | |||
|- | |||
! {{code|key.keyboard.ac.search}}{{upcoming|java 26.3}} | |||
| {{btn|AC Search}} | |||
| colspan="2" | {{key|Application Search}} | |||
| {{code|key.keyboard.ac.search}} | |||
|- | |||
! {{code|key.keyboard.ac.home}}{{upcoming|java 26.3}} | |||
| {{btn|AC Home}} | |||
| colspan="2" | {{key|Application Home}} | |||
| {{code|key.keyboard.ac.home}} | |||
|- | |||
! {{code|key.keyboard.ac.back}}{{upcoming|java 26.3}} | |||
| {{btn|AC Back}} | |||
| colspan="2" | {{key|Application Back}} | |||
| {{code|key.keyboard.ac.back}} | |||
|- | |||
! {{code|key.keyboard.ac.forward}}{{upcoming|java 26.3}} | |||
| {{btn|AC Forward}} | |||
| colspan="2" | {{key|Application Forward}} | |||
| {{code|key.keyboard.ac.forward}} | |||
|- | |||
! {{code|key.keyboard.ac.refresh}}{{upcoming|java 26.3}} | |||
| {{btn|AC Refresh}} | |||
| colspan="2" | {{key|Application Refresh}} | |||
| {{code|key.keyboard.ac.refresh}} | |||
|- | |||
! {{code|key.keyboard.ac.bookmarks}}{{upcoming|java 26.3}} | |||
| {{btn|AC Favorites}} | |||
| colspan="2" | {{key|Application Bookmarks}} | |||
| {{code|key.keyboard.ac.bookmarks}} | |||
|- | |||
! {{code|key.keyboard.power}}{{upcoming|java 26.3}} | |||
| {{btn|Power}} | |||
| colspan="2" | {{key|Power}} | |||
| {{code|key.keyboard.power}} | |||
|- | |||
! {{code|key.keyboard.sleep}}{{upcoming|java 26.3}} | |||
| {{btn|Sleep}} | |||
| colspan="2" | {{key|Sleep}} | |||
| {{code|key.keyboard.sleep}} | |||
|- | |||
! {{code|key.keyboard.wake}}{{upcoming|java 26.3}} | |||
| {{btn|Wake}} | |||
| colspan="2" | {{key|Wake}} | |||
| {{code|key.keyboard.wake}} | |||
|- | |- | ||
! {{code|scancode.{{note|name="oldkeynumberid"|Two or three digit number representing operating system key ID}}}}{{until|java 26.3}} | ! {{code|scancode.{{note|name="oldkeynumberid"|Two or three digit number representing operating system key ID}}}}{{until|java 26.3}} | ||
| Line 821: | Line 950: | ||
|} | |} | ||
==== | ==== Unused ==== | ||
Minecraft includes IDs and translation strings for all named SDL3 key IDs, even those which are not present in the key binding files for any supported operating system, and therefore cannot be accessed. | |||
SDL3 | |||
These can be set via modifying {{code|[[Minecraft:options.txt]]}} manually, but will not be triggerable due to the lack of an associated key. | |||
{| class="wikitable sortable" data-description=" | Keys such as World 2, Keypad Decimal and Escape may warrant inclusion here later.{{upcoming|java 26.3}} | ||
{| class="wikitable sortable" data-description="IDs of unused keys" style="margin-left:auto; margin-right:auto; text-align: center" | |||
! ID{{note|The translation string is assumed to match unless stated otherwise.}} | |||
! Displayed name | ! Displayed name | ||
! | ! Notes | ||
! | |- | ||
! {{code|key.keyboard.ac.print}} | |||
| {{btn|AC Print}} | |||
| | |||
|- | |||
! {{code|key.keyboard.alternate.erase}} | |||
| {{btn|Alternate Erase}} | |||
| | |||
|- | |||
! {{code|key.keyboard.call}} | |||
| {{btn|Call}} | |||
| This is a mobile phone button.<ref name="SDLmasterlist">https://wiki.libsdl.org/SDL3/SDL_Scancode</ref> | |||
|- | |||
! {{code|key.keyboard.channel.down}} | |||
| {{btn|Channel Down}} | |||
| | |||
|- | |||
! {{code|key.keyboard.channel.up}} | |||
| {{btn|Channel Up}} | |||
| | |||
|- | |||
! {{code|key.keyboard.clear}} | |||
| {{btn|Clear}} | |||
| | |||
|- | |||
! {{code|key.keyboard.clear.again}} | |||
| {{btn|Clear Again}} | |||
| | |||
|- | |||
! {{code|key.keyboard.crsel}} | |||
| {{btn|CrSel}} | |||
| | |||
|- | |||
! {{code|key.keyboard.currency.subunit}} | |||
| {{btn|Currency Subunit}} | |||
| | |||
|- | |||
! {{code|key.keyboard.currency.unit}} | |||
| {{btn|Currency Unit}} | |||
| | |||
|- | |||
! {{code|key.keyboard.decimal.separator}} | |||
| {{btn|Decimal Separator}} | |||
| | |||
|- | |||
! {{code|key.keyboard.end.call}} | |||
| {{btn|End Call}} | |||
| This is a mobile phone button.<ref name="SDLmasterlist"/> | |||
|- | |||
! {{code|key.keyboard.enter2}} | |||
| {{btn|Enter 2}} | |||
| | |||
|- | |||
! {{code|key.keyboard.execute}} | |||
| {{btn|Execute}} | |||
| | |||
|- | |||
! {{code|key.keyboard.exsel}} | |||
| {{btn|ExSel}} | |||
| | |||
|- | |||
! {{code|key.keyboard.international7}} | |||
| {{btn|International 7}} | |||
| | |||
|- | |||
! {{code|key.keyboard.international8}} | |||
| {{btn|International 8}} | |||
| | |||
|- | |||
! {{code|key.keyboard.international9}} | |||
| {{btn|International 9}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.00}} | |||
| {{btn|Keypad 00}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.000}} | |||
| {{btn|Keypad 000}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.a}} | |||
| {{btn|Keypad A}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.ampersand}} | |||
| {{btn|Keypad &}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.at}} | |||
| {{btn|Keypad @}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.b}} | |||
| {{btn|Keypad B}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.backspace}} | |||
| {{btn|Keypad Backspace}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.binary}} | |||
| {{btn|Keypad Binary}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.c}} | |||
| {{btn|Keypad C}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.clear}} | |||
| {{btn|Keypad Clear}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.clear.entry}} | |||
| {{btn|Keypad Clear Entry}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.colon}} | |||
| {{btn|Keypad :}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.d}} | |||
| {{btn|Keypad D}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.double.ampersand}} | |||
| {{btn|Keypad &&}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.double.vertical.bar}} | |||
| {{btn|Keypad <nowiki>||</nowiki>}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.e}} | |||
| {{btn|Keypad E}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.equals.as400}} | |||
| {{btn|Keypad {{=}} (AS400)}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.exclamation}} | |||
| {{btn|Keypad !}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.f}} | |||
| {{btn|Keypad F}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.greater}} | |||
| {{btn|Keypad >}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.hash}} | |||
| {{btn|Keypad #}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.hexadecimal}} | |||
| {{btn|Keypad Hexadecimal}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.left.brace}} | |||
| {{btn|Keypad {}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.less}} | |||
| {{btn|Keypad <}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.memory.add}} | |||
| {{btn|Keypad M+}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.memory.clear}} | |||
| {{btn|Keypad MC}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.memory.divide}} | |||
| {{btn|Keypad M/}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.memory.multiply}} | |||
| {{btn|Keypad M*}} | |||
| | |||
|- | |||
! {{code|key.keyboard.keypad.memory.recall}} | |||
| {{btn|Keypad MR}} | |||
| | |||
|- | |- | ||
! {{code|key.keyboard.keypad.memory.store}} | |||
| {{ | | {{btn|Keypad MS}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.memory.subtract}} | |||
| {{ | | {{btn|Keypad M-}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.octal}} | |||
| {{ | | {{btn|Keypad Octal}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.percent}} | |||
| {{ | | {{btn|Keypad %}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.power}} | |||
| {{ | | {{btn|Keypad ^}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.right.brace}} | |||
| {{ | | {{btn|Keypad <nowiki>}</nowiki>}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.space}} | |||
| {{ | | {{btn|Keypad Space}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.tab}} | |||
| {{ | | {{btn|Keypad Tab}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.vertical.bar}} | |||
| {{ | | {{btn|Keypad <nowiki>|</nowiki>}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.keypad.xor}} | |||
| {{ | | {{btn|Keypad XOR}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.lang6}} | |||
| {{ | | {{btn|Language 6}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.lang7}} | |||
| {{ | | {{btn|Language 7}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.lang8}} | |||
| {{ | | {{btn|Language 8}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.lang9}} | |||
| {{ | | {{btn|Language 9}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.mode}} | |||
| {{ | | {{btn|Mode}} | ||
| {{bug|MC- | | Accidentally assignable in Linux.<ref>{{bug|MC-310984}}</ref> | ||
|- | |- | ||
! {{code|key.keyboard.oper}} | |||
| {{ | | {{btn|Oper}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.out}} | |||
| {{ | | {{btn|Out}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.prior}} | |||
| {{ | | {{btn|Prior}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.select}} | |||
| {{ | | {{btn|Select}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.separator}} | |||
| {{ | | {{btn|Separator}} | ||
| | | | ||
|- | |- | ||
! {{code|key.keyboard.soft.left}} | |||
| {{ | | {{btn|Soft Left}} | ||
| | | This is a mobile phone button.<ref name="SDLmasterlist"/> | ||
|- | |- | ||
! {{code|key.keyboard.soft.right}} | |||
| {{ | | {{btn|Soft Right}} | ||
| | | This is a mobile phone button.<ref name="SDLmasterlist"/> | ||
|- | |- | ||
! {{code|key.keyboard.sys.req}} | |||
| {{ | | {{btn|SysRq}} | ||
| | | The Print Screen key usually holds this functionality. | ||
|- | |- | ||
! {{code|key.keyboard.thousands.separator}} | |||
| {{ | | {{btn|Thousands Separator}} | ||
| | | | ||
|} | |} | ||
Revision as of 11:12, 19 August 2026
Template:For This is a list of key codes used by Minecraft:Minecraft, which are used in the Minecraft:options.txt file.
Java Edition
Only keys which can be directly detected by the operating system are able to be bound to game controls - keys such as F Lock<ref>Template:Bug</ref> or Fn typically are not recognisable themselves as keys, and Minecraft and all other computer programs will be oblivious to them in isolation.
Only mouse buttons can have controls be bound to them in the options menu. Mouse movement, vertical scrolling and horizontal scrolling are hardcoded, and their default actions cannot be assigned to other keys or buttons, nor can scrolling or moving the mouse be made to do anything else.
Java Edition does not provide official support for controllers.
Keyboard codes
The displayed names of several keys will change depending on the currently active system keyboard layout. The values displayed in this table assume a standard en-US QWERTY layout. Some keys also have operating system dependent names, which are assigned different rows sharing an ID.
Unused
Minecraft includes IDs and translation strings for all named SDL3 key IDs, even those which are not present in the key binding files for any supported operating system, and therefore cannot be accessed.
These can be set via modifying Template:Code manually, but will not be triggerable due to the lack of an associated key.
Keys such as World 2, Keypad Decimal and Escape may warrant inclusion here later.Template:Upcoming
Mouse codes
Mouse buttons are handled as a signed 32-bit integer, meaning that through editing options.txt, values from Template:Code to Template:Code can be specified without being rejected by the game as invalid.<ref>Template:Bug</ref> However, the USB HID specification only permits mouse buttons from 1 to 65535,<ref>https://www.usb.org/sites/default/files/documents/hut1_12v2.pdf</ref> meaning that all negative values and the vast majority of the positive values can never actually be assigned to in-game actions without file editing.
Only the first eight mouse buttons can have controls assigned to them.Template:Until
On Linux, mouse buttons up to 48Template:Upcoming can be specified (evdev key press events 272 to 319) - it is not known if any supported operating systems support a 49th or higher mouse button as input. The maximum mouse button on macOS is 32,<ref>according to what karabiner-elements allows: https://discord.com/channels/647810384031645728/648555495564509184/1528136787434930358</ref> and the maximum mouse button on Windows is 5.
For the first three mouse buttons, the translation keys match the key IDs; all other buttons follow a generic template.
Bedrock Edition
Keyboard codes
Template:Info needed section Template:Cleanup In Template:BE, keys are stored as the decimal representation of their virtual key code.
Some numbers are skipped because they are reserved or not assigned. By modifying options.txt, you can force the game to show these numbers (prefixed with "Button"), but they are unobtainable by pressing a key.
The virtual key code specification also provides numbers for buttons on the mouse. However, mouse buttons are not stored as those numbers.
Mouse codes
Template:Info needed section Mouse buttons are represented by negative numbers.
Controller codes
History
Java Edition
Removed keys
Notes
References
Template:Navbox Java Edition technical Template:Navbox Bedrock Edition
Minecraft:fr:Codes de touche Minecraft:hu:Billentyűkódok Minecraft:ja:キーコード Minecraft:nl:Toetscodes Minecraft:pt:Códigos de teclas Minecraft:ru:Коды клавиш Minecraft:uk:Коди клавіш Minecraft:zh:键控代码