ddnet/src/engine/client/keynames.h
Robert Müller 1eaa88b236 Handle ordinal joystick hat keys as combined cardinal hat keys
Instead of considering diagonal hat inputs (e.g. up-left) as separate keys, consider them as inputs for both cardinal directions (e.g. up and left) at the same time.

This improves input with gamecontrollers that map the D-Pad to a joystick hat, as it was impossible with the previous handling to move with hat-left/right and jump with hat-up at the same time.

This means that diagonal hat buttons can no longer be used in binds, because they are no longer considered distinct buttons. It's unlikely that they would ever be useful in this game, as real joystick POV hats would not be used anyway.

Closes #6120.
2022-12-17 17:18:01 +01:00

523 lines
5.7 KiB
C

/* AUTO GENERATED! DO NOT EDIT MANUALLY! */
#ifndef KEYS_INCLUDE
#error do not include this header!
#endif
const char g_aaKeyStrings[512][20] = // NOLINT(misc-definitions-in-headers)
{
"unknown",
"&1",
"&2",
"&3",
"a",
"b",
"c",
"d",
"e",
"f",
"g",
"h",
"i",
"j",
"k",
"l",
"m",
"n",
"o",
"p",
"q",
"r",
"s",
"t",
"u",
"v",
"w",
"x",
"y",
"z",
"1",
"2",
"3",
"4",
"5",
"6",
"7",
"8",
"9",
"0",
"return",
"escape",
"backspace",
"tab",
"space",
"minus",
"equals",
"leftbracket",
"rightbracket",
"backslash",
"nonushash",
"semicolon",
"apostrophe",
"grave",
"comma",
"period",
"slash",
"capslock",
"f1",
"f2",
"f3",
"f4",
"f5",
"f6",
"f7",
"f8",
"f9",
"f10",
"f11",
"f12",
"printscreen",
"scrolllock",
"pause",
"insert",
"home",
"pageup",
"delete",
"end",
"pagedown",
"right",
"left",
"down",
"up",
"numlockclear",
"kp_divide",
"kp_multiply",
"kp_minus",
"kp_plus",
"kp_enter",
"kp_1",
"kp_2",
"kp_3",
"kp_4",
"kp_5",
"kp_6",
"kp_7",
"kp_8",
"kp_9",
"kp_0",
"kp_period",
"nonusbackslash",
"application",
"power",
"kp_equals",
"f13",
"f14",
"f15",
"f16",
"f17",
"f18",
"f19",
"f20",
"f21",
"f22",
"f23",
"f24",
"execute",
"help",
"menu",
"select",
"stop",
"again",
"undo",
"cut",
"copy",
"paste",
"find",
"mute",
"volumeup",
"volumedown",
"&130",
"&131",
"&132",
"kp_comma",
"kp_equalsas400",
"international1",
"international2",
"international3",
"international4",
"international5",
"international6",
"international7",
"international8",
"international9",
"lang1",
"lang2",
"lang3",
"lang4",
"lang5",
"lang6",
"lang7",
"lang8",
"lang9",
"alterase",
"sysreq",
"cancel",
"clear",
"prior",
"return2",
"separator",
"out",
"oper",
"clearagain",
"crsel",
"exsel",
"&165",
"&166",
"&167",
"&168",
"&169",
"&170",
"&171",
"&172",
"&173",
"&174",
"&175",
"kp_00",
"kp_000",
"thousandsseparator",
"decimalseparator",
"currencyunit",
"currencysubunit",
"kp_leftparen",
"kp_rightparen",
"kp_leftbrace",
"kp_rightbrace",
"kp_tab",
"kp_backspace",
"kp_a",
"kp_b",
"kp_c",
"kp_d",
"kp_e",
"kp_f",
"kp_xor",
"kp_power",
"kp_percent",
"kp_less",
"kp_greater",
"kp_ampersand",
"kp_dblampersand",
"kp_verticalbar",
"kp_dblverticalbar",
"kp_colon",
"kp_hash",
"kp_space",
"kp_at",
"kp_exclam",
"kp_memstore",
"kp_memrecall",
"kp_memclear",
"kp_memadd",
"kp_memsubtract",
"kp_memmultiply",
"kp_memdivide",
"kp_plusminus",
"kp_clear",
"kp_clearentry",
"kp_binary",
"kp_octal",
"kp_decimal",
"kp_hexadecimal",
"&222",
"&223",
"lctrl",
"lshift",
"lalt",
"lgui",
"rctrl",
"rshift",
"ralt",
"rgui",
"&232",
"&233",
"&234",
"&235",
"&236",
"&237",
"&238",
"&239",
"&240",
"&241",
"&242",
"&243",
"&244",
"&245",
"&246",
"&247",
"&248",
"&249",
"&250",
"&251",
"&252",
"&253",
"&254",
"&255",
"&256",
"mode",
"audionext",
"audioprev",
"audiostop",
"audioplay",
"audiomute",
"mediaselect",
"www",
"mail",
"calculator",
"computer",
"ac_search",
"ac_home",
"ac_back",
"ac_forward",
"ac_stop",
"ac_refresh",
"ac_bookmarks",
"brightnessdown",
"brightnessup",
"displayswitch",
"kbdillumtoggle",
"kbdillumdown",
"kbdillumup",
"eject",
"sleep",
"app1",
"app2",
"mouse1",
"mouse2",
"mouse3",
"mouse4",
"mouse5",
"mouse6",
"mouse7",
"mouse8",
"mouse9",
"mousewheelup",
"mousewheeldown",
"mousewheelleft",
"mousewheelright",
"joystick0",
"joystick1",
"joystick2",
"joystick3",
"joystick4",
"joystick5",
"joystick6",
"joystick7",
"joystick8",
"joystick9",
"joystick10",
"joystick11",
"joy_hat0_up",
"joy_hat0_left",
"joy_hat0_right",
"joy_hat0_down",
"joy_hat1_up",
"joy_hat1_left",
"joy_hat1_right",
"joy_hat1_down",
"joy_axis0_left",
"joy_axis0_right",
"joy_axis1_left",
"joy_axis1_right",
"joy_axis2_left",
"joy_axis2_right",
"joy_axis3_left",
"joy_axis3_right",
"joy_axis4_left",
"joy_axis4_right",
"joy_axis5_left",
"joy_axis5_right",
"joy_axis6_left",
"joy_axis6_right",
"joy_axis7_left",
"joy_axis7_right",
"joy_axis8_left",
"joy_axis8_right",
"joy_axis9_left",
"joy_axis9_right",
"joy_axis10_left",
"joy_axis10_right",
"joy_axis11_left",
"joy_axis11_right",
"&342",
"&343",
"&344",
"&345",
"&346",
"&347",
"&348",
"&349",
"&350",
"&351",
"&352",
"&353",
"&354",
"&355",
"&356",
"&357",
"&358",
"&359",
"&360",
"&361",
"&362",
"&363",
"&364",
"&365",
"&366",
"&367",
"&368",
"&369",
"&370",
"&371",
"&372",
"&373",
"&374",
"&375",
"&376",
"&377",
"&378",
"&379",
"&380",
"&381",
"&382",
"&383",
"&384",
"&385",
"&386",
"&387",
"&388",
"&389",
"&390",
"&391",
"&392",
"&393",
"&394",
"&395",
"&396",
"&397",
"&398",
"&399",
"&400",
"&401",
"&402",
"&403",
"&404",
"&405",
"&406",
"&407",
"&408",
"&409",
"&410",
"&411",
"&412",
"&413",
"&414",
"&415",
"&416",
"&417",
"&418",
"&419",
"&420",
"&421",
"&422",
"&423",
"&424",
"&425",
"&426",
"&427",
"&428",
"&429",
"&430",
"&431",
"&432",
"&433",
"&434",
"&435",
"&436",
"&437",
"&438",
"&439",
"&440",
"&441",
"&442",
"&443",
"&444",
"&445",
"&446",
"&447",
"&448",
"&449",
"&450",
"&451",
"&452",
"&453",
"&454",
"&455",
"&456",
"&457",
"&458",
"&459",
"&460",
"&461",
"&462",
"&463",
"&464",
"&465",
"&466",
"&467",
"&468",
"&469",
"&470",
"&471",
"&472",
"&473",
"&474",
"&475",
"&476",
"&477",
"&478",
"&479",
"&480",
"&481",
"&482",
"&483",
"&484",
"&485",
"&486",
"&487",
"&488",
"&489",
"&490",
"&491",
"&492",
"&493",
"&494",
"&495",
"&496",
"&497",
"&498",
"&499",
"&500",
"&501",
"&502",
"&503",
"&504",
"&505",
"&506",
"&507",
"&508",
"&509",
"&510",
"&511",
};