// Supported with union (c) 2018-2021 Union team

#ifndef __ZINPUT__CONST_H__VER2__
#define __ZINPUT__CONST_H__VER2__

namespace Gothic_II_Classic {
  #define KEY_ESCAPE          0x01
  #define KEY_1               0x02
  #define KEY_2               0x03
  #define KEY_3               0x04
  #define KEY_4               0x05
  #define KEY_5               0x06
  #define KEY_6               0x07
  #define KEY_7               0x08
  #define KEY_8               0x09
  #define KEY_9               0x0A
  #define KEY_0               0x0B
  #define KEY_MINUS           0x0C
  #define KEY_EQUALS          0x0D
  #define KEY_BACK            0x0E    
  #define KEY_TAB             0x0F
  #define KEY_Q               0x10
  #define KEY_W               0x11
  #define KEY_E               0x12
  #define KEY_R               0x13
  #define KEY_T               0x14
  #define KEY_Y               0x15
  #define KEY_U               0x16
  #define KEY_I               0x17
  #define KEY_O               0x18
  #define KEY_P               0x19
  #define KEY_LBRACKET        0x1A
  #define KEY_RBRACKET        0x1B
  #define KEY_RETURN          0x1C    
  #define KEY_LCONTROL        0x1D
  #define KEY_A               0x1E
  #define KEY_S               0x1F
  #define KEY_D               0x20
  #define KEY_F               0x21
  #define KEY_G               0x22
  #define KEY_H               0x23
  #define KEY_J               0x24
  #define KEY_K               0x25
  #define KEY_L               0x26
  #define KEY_SEMICOLON       0x27
  #define KEY_APOSTROPHE      0x28
  #define KEY_GRAVE           0x29    
  #define KEY_LSHIFT          0x2A
  #define KEY_BACKSLASH       0x2B
  #define KEY_Z               0x2C
  #define KEY_X               0x2D
  #define KEY_C               0x2E
  #define KEY_V               0x2F
  #define KEY_B               0x30
  #define KEY_N               0x31
  #define KEY_M               0x32
  #define KEY_COMMA           0x33
  #define KEY_PERIOD          0x34    
  #define KEY_SLASH           0x35    
  #define KEY_RSHIFT          0x36
  #define KEY_MULTIPLY        0x37    
  #define KEY_LMENU           0x38    
  #define KEY_SPACE           0x39
  #define KEY_CAPITAL         0x3A
  #define KEY_F1              0x3B
  #define KEY_F2              0x3C
  #define KEY_F3              0x3D
  #define KEY_F4              0x3E
  #define KEY_F5              0x3F
  #define KEY_F6              0x40
  #define KEY_F7              0x41
  #define KEY_F8              0x42
  #define KEY_F9              0x43
  #define KEY_F10             0x44
  #define KEY_NUMLOCK         0x45
  #define KEY_SCROLL          0x46    
  #define KEY_NUMPAD7         0x47
  #define KEY_NUMPAD8         0x48
  #define KEY_NUMPAD9         0x49
  #define KEY_SUBTRACT        0x4A    
  #define KEY_NUMPAD4         0x4B
  #define KEY_NUMPAD5         0x4C
  #define KEY_NUMPAD6         0x4D
  #define KEY_ADD             0x4E    
  #define KEY_NUMPAD1         0x4F
  #define KEY_NUMPAD2         0x50
  #define KEY_NUMPAD3         0x51
  #define KEY_NUMPAD0         0x52
  #define KEY_DECIMAL         0x53    
  #define KEY_OEM_102         0x56    
  #define KEY_F11             0x57
  #define KEY_F12             0x58
  #define KEY_F13             0x64    
  #define KEY_F14             0x65    
  #define KEY_F15             0x66    
  #define KEY_KANA            0x70    
  #define KEY_ABNT_C1         0x73    
  #define KEY_CONVERT         0x79    
  #define KEY_NOCONVERT       0x7B    
  #define KEY_YEN             0x7D    
  #define KEY_ABNT_C2         0x7E    
  #define KEY_NUMPADEQUALS    0x8D    
  #define KEY_PREVTRACK       0x90    
  #define KEY_AT              0x91    
  #define KEY_COLON           0x92    
  #define KEY_UNDERLINE       0x93    
  #define KEY_KANJI           0x94    
  #define KEY_STOP            0x95    
  #define KEY_AX              0x96    
  #define KEY_UNLABELED       0x97    
  #define KEY_NEXTTRACK       0x99    
  #define KEY_NUMPADENTER     0x9C    
  #define KEY_RCONTROL        0x9D
  #define KEY_MUTE            0xA0    
  #define KEY_CALCULATOR      0xA1    
  #define KEY_PLAYPAUSE       0xA2    
  #define KEY_MEDIASTOP       0xA4    
  #define KEY_VOLUMEDOWN      0xAE    
  #define KEY_VOLUMEUP        0xB0    
  #define KEY_WEBHOME         0xB2    
  #define KEY_NUMPADCOMMA     0xB3    
  #define KEY_DIVIDE          0xB5    
  #define KEY_SYSRQ           0xB7
  #define KEY_RMENU           0xB8    
  #define KEY_PAUSE           0xC5    
  #define KEY_HOME            0xC7    
  #define KEY_UP              0xC8    
  #define KEY_PRIOR           0xC9    
  #define KEY_LEFT            0xCB    
  #define KEY_RIGHT           0xCD    
  #define KEY_END             0xCF    
  #define KEY_DOWN            0xD0    
  #define KEY_NEXT            0xD1    
  #define KEY_INSERT          0xD2    
  #define KEY_DELETE          0xD3    
  #define KEY_LWIN            0xDB    
  #define KEY_RWIN            0xDC    
  #define KEY_APPS            0xDD    
  #define KEY_POWER           0xDE    
  #define KEY_SLEEP           0xDF    
  #define KEY_WAKE            0xE3    
  #define KEY_WEBSEARCH       0xE5    
  #define KEY_WEBFAVORITES    0xE6    
  #define KEY_WEBREFRESH      0xE7    
  #define KEY_WEBSTOP         0xE8    
  #define KEY_WEBFORWARD      0xE9    
  #define KEY_WEBBACK         0xEA    
  #define KEY_MYCOMPUTER      0xEB    
  #define KEY_MAIL            0xEC    
  #define KEY_MEDIASELECT     0xED    

  #define KEY_BACKSPACE       KEY_BACK            
  #define KEY_NUMPADSTAR      KEY_MULTIPLY        
  #define KEY_LALT            KEY_LMENU           
  #define KEY_CAPSLOCK        KEY_CAPITAL         
  #define KEY_NUMPADMINUS     KEY_SUBTRACT        
  #define KEY_NUMPADPLUS      KEY_ADD             
  #define KEY_NUMPADPERIOD    KEY_DECIMAL         
  #define KEY_NUMPADSLASH     KEY_DIVIDE          
  #define KEY_RALT            KEY_RMENU           
  #define KEY_UPARROW         KEY_UP              
  #define KEY_PGUP            KEY_PRIOR           
  #define KEY_LEFTARROW       KEY_LEFT            
  #define KEY_RIGHTARROW      KEY_RIGHT           
  #define KEY_DOWNARROW       KEY_DOWN            
  #define KEY_PGDN            KEY_NEXT            

  #define KEY_CIRCUMFLEX      KEY_PREVTRACK       


  #define MAX_KEYS            512
  #define MAX_KEYS_AND_CODES  515
  #define KEY_NOT_HERE        (MAX_KEYS_AND_CODES + 1)
  #define KEY_RELEASE         0x8000              


  #define GAME_LEFT           1
  #define GAME_RIGHT          2
  #define GAME_UP             3
  #define GAME_DOWN           4
  #define GAME_ACTION         5
  #define GAME_SLOW           6
  #define GAME_ACTION2        7
  #define GAME_WEAPON         8
  #define GAME_SMOVE          11
  #define GAME_SMOVE2         12
  #define GAME_SHIFT          13
  #define GAME_END            14
  #define GAME_INVENTORY      15
  #define GAME_LOOK           16
  #define GAME_SNEAK          17
  #define GAME_STRAFELEFT     18
  #define GAME_STRAFERIGHT    19
  #define GAME_SCREEN_STATUS  20
  #define GAME_SCREEN_LOG     21
  #define GAME_SCREEN_MAP     22
  #define GAME_LOOK_FP        23
  #define GAME_LOCK_TARGET    24
  #define GAME_PARADE         25
  #define GAME_ACTIONLEFT     26
  #define GAME_ACTIONRIGHT    27
  #define GAME_LAME_POTION    28
  #define GAME_LAME_HEAL      29


  #define MIN_MOUSE_BTNS_AND_CODES  (KEY_NOT_HERE)  

  #define MOUSE_DX                  (MIN_MOUSE_BTNS_AND_CODES +  0)
  #define MOUSE_DY                  (MIN_MOUSE_BTNS_AND_CODES +  1)
  #define MOUSE_UP                  (MIN_MOUSE_BTNS_AND_CODES +  2)
  #define MOUSE_DOWN                (MIN_MOUSE_BTNS_AND_CODES +  3)
  #define MOUSE_LEFT                (MIN_MOUSE_BTNS_AND_CODES +  4)
  #define MOUSE_RIGHT               (MIN_MOUSE_BTNS_AND_CODES +  5)
  #define MOUSE_WHEELUP             (MIN_MOUSE_BTNS_AND_CODES +  6)
  #define MOUSE_WHEELDOWN           (MIN_MOUSE_BTNS_AND_CODES +  7)
  #define MOUSE_BUTTONLEFT          (MIN_MOUSE_BTNS_AND_CODES +  8)
  #define MOUSE_BUTTONRIGHT         (MIN_MOUSE_BTNS_AND_CODES +  9)
  #define MOUSE_BUTTONMID           (MIN_MOUSE_BTNS_AND_CODES + 10)
  #define MOUSE_XBUTTON1            (MIN_MOUSE_BTNS_AND_CODES + 11)
  #define MOUSE_XBUTTON2            (MIN_MOUSE_BTNS_AND_CODES + 12)
  #define MOUSE_XBUTTON3            (MIN_MOUSE_BTNS_AND_CODES + 13)
  #define MOUSE_XBUTTON4            (MIN_MOUSE_BTNS_AND_CODES + 14)
  #define MOUSE_XBUTTON5            (MIN_MOUSE_BTNS_AND_CODES + 15)

  #define MAX_MOUSE_BTNS_AND_CODES  (MOUSE_XBUTTON5         +  1)
  #define MIN_MOUSE_BTNS            (MOUSE_WHEELUP)  
  #define MAX_MOUSE_BTNS            (MOUSE_XBUTTON5         +  1)
  #define MIN_JOY_BTNS_AND_CODES    (MAX_MOUSE_BTNS_AND_CODES)
  #define JOY_LEFT                  (MIN_JOY_BTNS_AND_CODES +  0)
  #define JOY_RIGHT                 (MIN_JOY_BTNS_AND_CODES +  1)
  #define JOY_UP                    (MIN_JOY_BTNS_AND_CODES +  2)
  #define JOY_DOWN                  (MIN_JOY_BTNS_AND_CODES +  3)
  #define THROTTLE_UP               (MIN_JOY_BTNS_AND_CODES +  4)
  #define THROTTLE_DOWN             (MIN_JOY_BTNS_AND_CODES +  5)
  #define RUDDER_LEFT               (MIN_JOY_BTNS_AND_CODES +  6)
  #define RUDDER_RIGHT              (MIN_JOY_BTNS_AND_CODES +  7)
  #define JOY_POV_LEFT              (MIN_JOY_BTNS_AND_CODES +  8)
  #define JOY_POV_RIGHT             (MIN_JOY_BTNS_AND_CODES +  9)
  #define JOY_POV_UP                (MIN_JOY_BTNS_AND_CODES + 10)
  #define JOY_POV_DOWN              (MIN_JOY_BTNS_AND_CODES + 11)
  #define JOY_BUTTON_1              (MIN_JOY_BTNS_AND_CODES + 12)
  #define JOY_BUTTON_2              (MIN_JOY_BTNS_AND_CODES + 13)
  #define JOY_BUTTON_3              (MIN_JOY_BTNS_AND_CODES + 14)
  #define JOY_BUTTON_4              (MIN_JOY_BTNS_AND_CODES + 15)
  #define JOY_BUTTON_5              (MIN_JOY_BTNS_AND_CODES + 16)
  #define JOY_BUTTON_6              (MIN_JOY_BTNS_AND_CODES + 17)
  #define JOY_BUTTON_7              (MIN_JOY_BTNS_AND_CODES + 18)
  #define JOY_BUTTON_8              (MIN_JOY_BTNS_AND_CODES + 19)
  #define JOY_BUTTON_9              (MIN_JOY_BTNS_AND_CODES + 20)
  #define JOY_BUTTON_10             (MIN_JOY_BTNS_AND_CODES + 21)
  #define JOY_BUTTON_11             (MIN_JOY_BTNS_AND_CODES + 22)
  #define JOY_BUTTON_12             (MIN_JOY_BTNS_AND_CODES + 23)
  #define JOY_BUTTON_13             (MIN_JOY_BTNS_AND_CODES + 24)
  #define JOY_BUTTON_14             (MIN_JOY_BTNS_AND_CODES + 25)
  #define JOY_BUTTON_15             (MIN_JOY_BTNS_AND_CODES + 26)
  #define JOY_BUTTON_16             (MIN_JOY_BTNS_AND_CODES + 27)
  #define JOY_BUTTON_17             (MIN_JOY_BTNS_AND_CODES + 28)
  #define JOY_BUTTON_18             (MIN_JOY_BTNS_AND_CODES + 29)
  #define JOY_BUTTON_19             (MIN_JOY_BTNS_AND_CODES + 30)
  #define JOY_BUTTON_20             (MIN_JOY_BTNS_AND_CODES + 31)
  #define JOY_BUTTON_21             (MIN_JOY_BTNS_AND_CODES + 32)
  #define JOY_BUTTON_22             (MIN_JOY_BTNS_AND_CODES + 33)
  #define JOY_BUTTON_23             (MIN_JOY_BTNS_AND_CODES + 34)
  #define JOY_BUTTON_24             (MIN_JOY_BTNS_AND_CODES + 35)
  #define JOY_BUTTON_25             (MIN_JOY_BTNS_AND_CODES + 36)
  #define JOY_BUTTON_26             (MIN_JOY_BTNS_AND_CODES + 37)
  #define JOY_BUTTON_27             (MIN_JOY_BTNS_AND_CODES + 38)
  #define JOY_BUTTON_28             (MIN_JOY_BTNS_AND_CODES + 39)
  #define JOY_BUTTON_29             (MIN_JOY_BTNS_AND_CODES + 40)
  #define JOY_BUTTON_30             (MIN_JOY_BTNS_AND_CODES + 41)
  #define JOY_BUTTON_31             (MIN_JOY_BTNS_AND_CODES + 42)
  #define JOY_BUTTON_32             (MIN_JOY_BTNS_AND_CODES + 43)

  enum zTLogicalKey
  {
    zLOGICKEY_NULL           = 0x00,
    zLOGICKEY_LEFT           = 0x01,
    zLOGICKEY_RIGHT          = 0x02,
    zLOGICKEY_UP             = 0x03,
    zLOGICKEY_DOWN           = 0x04,
    zLOGICKEY_ACTION         = 0x05,
    zLOGICKEY_SLOW           = 0x06,
    zLOGICKEY_WEAPON         = 0x08,
    zLOGICKEY_SMOVE          = 0x0B,
    zLOGICKEY_END            = 0x0E,
    zLOGICKEY_INVENTORY      = 0x0F,
    zLOGICKEY_LOOK           = 0x10,
    zLOGICKEY_SNEAK          = 0x11,
    zLOGICKEY_STRAFELEFT     = 0x12,
    zLOGICKEY_STRAFERIGHT    = 0x13,
    zLOGICKEY_SCREEN_STATUS  = 0x14,
    zLOGICKEY_SCREEN_LOG     = 0x15,
    zLOGICKEY_SCREEN_MAP     = 0x16,
    zLOGICKEY_LOOK_FP        = 0x17,
    zLOGICKEY_LOCK_TARGET    = 0x18,
    zLOGICKEY_PARADE         = 0x19,
    zLOGICKEY_ACTIONLEFT     = 0x1A,
    zLOGICKEY_ACTIONRIGHT    = 0x1B,
    zLOGICKEY_LAME_POTION    = 0x1C,
    zLOGICKEY_LAME_HEAL      = 0x1D
  };

} // namespace Gothic_II_Classic

#endif // __ZINPUT__CONST_H__VER2__