> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xbox.com/llms.txt
> Use this file to discover all available pages before exploring further.

# GameInputKeyState

> GameInputKeyState

Describes the state of an active key on a game controller.

## Syntax

```cpp theme={null}
struct GameInputKeyState
{
    uint32_t scanCode;
    uint32_t codePoint;
    uint8_t  virtualKey;
    bool     isDeadKey;
};
```

### Members

*scanCode*\

Type: uint32\_t

The scan code of the key.

*codePoint*\

Type: uint32\_t

The Unicode code point of the physical glyph on the key.

*virtualKey*\

Type: uint8\_t

The virtual-key code.

*isDeadKey*\

Type: bool

Indicates whether the key is dead. (A dead key modifies the character generated by the next keystroke.)

## Remarks

This structure is used by the [IGameInputReading::GetKeyState](https://docs.xbox.com/reference/input/gameinput/interfaces/igameinputreading/methods/igameinputreading_getkeystate.md) method. `GetKeyState` is intended solely for mapping keyboard input to game actions, not for regular text input.

For more information, see [GameInput readings](https://docs.xbox.com/build/core-features/common/input/overviews/input-readings.md).

## Requirements

**Header:** GameInput.h

**Supported platforms:** Windows, XBOX One family consoles and XBOX Series consoles

## Conceptual documentation

* [GameInput keyboard and mouse](https://docs.xbox.com/build/core-features/common/input/advanced/input-keyboard-mouse.md)

## See also

[Overview of GameInput](https://docs.xbox.com/build/core-features/common/input/overviews/input-overview.md)\
[GameInput](https://docs.xbox.com/reference/input/gameinput/gameinput_members.md)

## Version History

| Version | Changes |
| - | - |
| **v0** | Introduced. |


## Related topics

- [GetKeyState](https://docs.xbox.com/reference/input/gameinput/interfaces/igameinputreading/methods/igameinputreading_getkeystate.md)
- [GameInput keyboard and mouse](https://docs.xbox.com/build/core-features/common/input/advanced/input-keyboard-mouse.md)
- [GameInput API members](https://docs.xbox.com/reference/input/gameinput/gameinput_members.md)
- [GameInputGamepadState](https://docs.xbox.com/reference/input/gameinput/structs/gameinputgamepadstate.md)
- [GameInputSensorsState](https://docs.xbox.com/reference/input/gameinput/structs/gameinputsensorsstate.md)
