Colobot
|
Key-related macros and enums. More...
#include <SDL_keycode.h>
Macros | |
#define | SDLK_LAST (SDLK_SCANCODE_MASK << 1) |
#define | KEY(x) SDLK_ ## x |
#define | KEY_MOD(x) KMOD_ ## x |
#define | VIRTUAL_KMOD(x) VIRTUAL_KMOD_ ## x |
#define | VIRTUAL_JOY(num) (SDLK_LAST + 200 + num) |
Enumerations | |
enum | VirtualKmod { VIRTUAL_KMOD_CTRL = SDLK_LAST + 100 , VIRTUAL_KMOD_SHIFT = SDLK_LAST + 101 , VIRTUAL_KMOD_ALT = SDLK_LAST + 102 , VIRTUAL_KMOD_GUI = SDLK_LAST + 103 } |
Virtual key codes generated on kmod presses. More... | |
enum | InputSlot { INPUT_SLOT_LEFT , INPUT_SLOT_RIGHT , INPUT_SLOT_UP , INPUT_SLOT_DOWN , INPUT_SLOT_GUP , INPUT_SLOT_GDOWN , INPUT_SLOT_CAMERA , INPUT_SLOT_DESEL , INPUT_SLOT_ACTION , INPUT_SLOT_CAM_LEFT , INPUT_SLOT_CAM_RIGHT , INPUT_SLOT_CAM_UP , INPUT_SLOT_CAM_DOWN , INPUT_SLOT_CAM_NEAR , INPUT_SLOT_CAM_AWAY , INPUT_SLOT_CAM_ALT , INPUT_SLOT_NEXT , INPUT_SLOT_HUMAN , INPUT_SLOT_QUIT , INPUT_SLOT_HELP , INPUT_SLOT_PROG , INPUT_SLOT_VISIT , INPUT_SLOT_SPEED_DEC , INPUT_SLOT_SPEED_RESET , INPUT_SLOT_SPEED_INC , INPUT_SLOT_QUICKSAVE , INPUT_SLOT_QUICKLOAD , INPUT_SLOT_PAUSE , INPUT_SLOT_CMDLINE , INPUT_SLOT_MAX } |
Available slots for input bindings NOTE: When adding new values, remember to also update keyTable in input.cpp and their descriptions in restext.cpp. More... | |
enum | JoyAxisSlot { JOY_AXIS_SLOT_X , JOY_AXIS_SLOT_Y , JOY_AXIS_SLOT_Z , JOY_AXIS_SLOT_CAM_X , JOY_AXIS_SLOT_CAM_Y , JOY_AXIS_SLOT_CAM_Z , JOY_AXIS_SLOT_MAX } |
Slots for joystick axes inputs. More... | |
Functions | |
unsigned int | GetVirtualKey (unsigned int key, unsigned int kmodState) |
Converts individual codes to virtual keys if needed. More... | |
Variables | |
const unsigned int | KEY_INVALID = SDLK_LAST + 1000 |
Special value for invalid key bindings. More... | |
Key-related macros and enums.
enum VirtualKmod |
enum InputSlot |
Available slots for input bindings NOTE: When adding new values, remember to also update keyTable in input.cpp and their descriptions in restext.cpp.
enum JoyAxisSlot |
Slots for joystick axes inputs.
unsigned int GetVirtualKey | ( | unsigned int | key, |
unsigned int | kmodState | ||
) |
Converts individual codes to virtual keys if needed.
const unsigned int KEY_INVALID = SDLK_LAST + 1000 |
Special value for invalid key bindings.