IN KEYS

From GMod Wiki

Revision as of 01:56, 4 November 2009 by Crazy Quebecer (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

This is a list of the IN_KEY identifiers used by functions such as Gamemode.KeyPress, Player.KeyDown, or Player.KeyPressed. See below for a full list of functions that use these definitions. KEY_* enums are used by input library

Contents

IN_* Enums

Works in the above Hooks


Notepad-48.png The prefix to these enumerations is IN_


SHARED | 0000000000000001 | 00000000000000000000000001 | ATTACK
SHARED | 0000000000000002 | 00000000000000000000000010 | JUMP
SHARED | 0000000000000004 | 00000000000000000000000100 | DUCK
SHARED | 0000000000000008 | 00000000000000000000001000 | FORWARD
SHARED | 0000000000000016 | 00000000000000000000010000 | BACK
SHARED | 0000000000000032 | 00000000000000000000100000 | USE
SHARED | 0000000000000064 | 00000000000000000001000000 | CANCEL
SHARED | 0000000000000128 | 00000000000000000010000000 | LEFT
SHARED | 0000000000000256 | 00000000000000000100000000 | RIGHT
SHARED | 0000000000000512 | 00000000000000001000000000 | MOVELEFT
SHARED | 0000000000001024 | 00000000000000010000000000 | MOVERIGHT
SHARED | 0000000000002048 | 00000000000000100000000000 | ATTACK2
SHARED | 0000000000004096 | 00000000000001000000000000 | RUN
SHARED | 0000000000008192 | 00000000000010000000000000 | RELOAD
SHARED | 0000000000016384 | 00000000000100000000000000 | ALT1
SHARED | 0000000000032768 | 00000000001000000000000000 | ALT2
SHARED | 0000000000065536 | 00000000010000000000000000 | SCORE
SHARED | 0000000000131072 | 00000000100000000000000000 | SPEED
SHARED | 0000000000262144 | 00000001000000000000000000 | WALK
SHARED | 0000000000524288 | 00000010000000000000000000 | ZOOM
SHARED | 0000000001048576 | 00000100000000000000000000 | WEAPON1
SHARED | 0000000002097152 | 00001000000000000000000000 | WEAPON2
SHARED | 0000000004194304 | 00010000000000000000000000 | BULLRUSH
SHARED | 0000000008388608 | 00100000000000000000000000 | GRENADE1
SHARED | 0000000016777216 | 01000000000000000000000000 | GRENADE2

KEY_* enums

Only works with input.IsKeyDown


Notepad-48.png The prefix to these enumerations is KEY_


Identifier Value
KEY_NONE 0
KEY_0 1
KEY_1 2
KEY_2 3
KEY_3 4
KEY_4 5
KEY_5 6
KEY_6 7
KEY_7 8
KEY_8 9
KEY_9 10
KEY_A 11
KEY_B 12
KEY_C 13
KEY_D 14
KEY_E 15
KEY_F 16
KEY_G 17
KEY_H 18
KEY_I 19
KEY_J 20
KEY_K 21
KEY_L 22
KEY_M 23
KEY_N 24
KEY_O 25
KEY_P 26
KEY_Q 27
KEY_R 28
KEY_S 29
KEY_T 30
KEY_U 31
KEY_V 32
KEY_W 33
KEY_X 34
KEY_Y 35
KEY_Z 36
KEY_PAD_0 37
KEY_PAD_1 38
KEY_PAD_2 39
KEY_PAD_3 40
KEY_PAD_4 41
KEY_PAD_5 42
KEY_PAD_6 43
KEY_PAD_7 44
KEY_PAD_8 45
KEY_PAD_9 46
KEY_PAD_DIVIDE 47
KEY_PAD_MULTIPLY 48
KEY_PAD_MINUS 49
KEY_PAD_PLUS 50
KEY_PAD_ENTER 51
KEY_PAD_DECIMAL 52
KEY_LBRACKET 53
KEY_RBRACKET 54
KEY_SEMICOLON 55
KEY_APOSTROPHE 56
KEY_BACKQUOTE 57
KEY_COMMA 58
KEY_PERIOD 59
KEY_SLASH 60
KEY_BACKSLASH 61
KEY_MINUS 62
KEY_EQUAL 63
KEY_ENTER 64
KEY_SPACE 65
KEY_BACKSPACE 66
KEY_TAB 67
KEY_CAPSLOCK 68
KEY_NUMLOCK 69
KEY_ESCAPE 70
KEY_SCROLLLOCK 71 - (Actual: Printscreen)
KEY_INSERT 72
KEY_DELETE 73
KEY_HOME 74
KEY_END 75
KEY_PAGEUP 76
KEY_PAGEDOWN 77
KEY_BREAK 78
KEY_LSHIFT 79
KEY_RSHIFT 80 - (Not used, registers as KEY_LSHIFT)
KEY_LALT 81
KEY_RALT 82 - (Not used, registers as KEY_LALT)
KEY_LCONTROL 83
KEY_RCONTROL 84 - (Not used, registers as KEY_LCONTROL)
KEY_LWIN 85
KEY_RWIN 86
KEY_APP 87
KEY_UP 88
KEY_LEFT 89
KEY_DOWN 90
KEY_RIGHT 91
KEY_F1 92
KEY_F2 93
KEY_F3 94
KEY_F4 95
KEY_F5 96
KEY_F6 97
KEY_F7 98
KEY_F8 99
KEY_F9 100
KEY_F10 101
KEY_F11 102
KEY_F12 103
KEY_CAPSLOCKTOGGLE 104
KEY_NUMLOCKTOGGLE 105
KEY_SCROLLLOCKTOGGLE 106
KEY_XBUTTON_UP 107
KEY_XBUTTON_DOWN 108
KEY_XBUTTON_LEFT 109
KEY_XBUTTON_RIGHT 110
KEY_XBUTTON_START 111
KEY_XBUTTON_BACK 112
KEY_XBUTTON_STICK1 113
KEY_XBUTTON_STICK2 114
KEY_XBUTTON_A 115
KEY_XBUTTON_B 116
KEY_XBUTTON_X 117
KEY_XBUTTON_Y 118
KEY_XBUTTON_BLACK 119
KEY_XBUTTON_WHITE 120
KEY_XBUTTON_LTRIGGER 121
KEY_XBUTTON_RTRIGGER 122
KEY_XSTICK1_UP 123
KEY_XSTICK1_DOWN 124
KEY_XSTICK1_LEFT 125
KEY_XSTICK1_RIGHT 126
KEY_XSTICK2_UP 127
KEY_XSTICK2_DOWN 128
KEY_XSTICK2_LEFT 129
KEY_XSTICK2_RIGHT 130

Mouse values

Only works with input.IsMouseDown

Identifier
MOUSE_4
MOUSE_5
MOUSE_COUNT
MOUSE_FIRST
MOUSE_LAST
MOUSE_LEFT
MOUSE_MIDDLE
MOUSE_RIGHT
MOUSE_WHEEL_DOWN
MOUSE_WHEEL_UP

Note: MOUSE_WHEEL_DOWN and MOUSE_WHEEL_UP with input.IsMouseDown work again since the Garry's Mod update #70. They broke in update #54.

See Also

Personal tools
Namespaces
Variants
Actions
Navigation
Lua Scripting
Functions
Hooks
Toolbox