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

# GameInputGamepadState

> GameInputGamepadState

# GameInputGamepadState

Describes the state of a gamepad input device.

<a id="syntaxSection" />

## Syntax

```cpp theme={null}
struct GameInputGamepadState
{
    GameInputGamepadButtons buttons;
    float                   leftTrigger;
    float                   rightTrigger;
    float                   leftThumbstickX;
    float                   leftThumbstickY;
    float                   rightThumbstickX;
    float                   rightThumbstickY;
};
```

<a id="membersSection" />

### Members

*buttons*<br />
Type: [GameInputGamepadButtons](/reference/input/gameinput/enums/gameinputgamepadbuttons)

The gamepad buttons that are pressed.

*leftTrigger*<br />
Type: float

Position of left trigger, normalized as a value in the range \[0.0, 1.0].

*rightTrigger*<br />
Type: float

Position of right trigger, normalized as a value in the range \[0.0, 1.0].

*leftThumbstickX*<br />
Type: float

Horizontal position of the left thumbstick, normalized as a value in the range \[-1.0, 1.0].

*leftThumbstickY*<br />
Type: float

Vertical position of the left thumbstick, normalized as a value in the range \[-1.0, 1.0].

*rightThumbstickX*<br />
Type: float

Horizontal position of the right thumbstick, normalized as a value in the range \[-1.0, 1.0].

*rightThumbstickY*<br />
Type: float

Vertical position of the right thumbstick, normalized as a value in the range \[-1.0, 1.0].

<a id="remarksSection" />

## Remarks

Used by the [IGameInputReading:GetGamePadState](/reference/input/gameinput/interfaces/igameinputreading/methods/igameinputreading_getgamepadstate) method.

For more information, see the [Getting data from readings](/build/core-features/common/input/overviews/input-readings#gettingStateSection) section of [GameInput readings](/build/core-features/common/input/overviews/input-readings). For a code example, see [A simple gamepad input loop](/build/core-features/common/input/overviews/input-readings#sampleSection).

<a id="requirementsSection" />

## Requirements

**Header:** GameInput.h

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

<a id="seealsoSection" />

## See also

[Overview of GameInput](/build/core-features/common/input/overviews/input-overview)\
[GameInput](/reference/input/gameinput/gameinput_members)

## Version History

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


## Related topics

- [IGameInputReading::GetGamepadState](/reference/input/gameinput/interfaces/igameinputreading/methods/igameinputreading_getgamepadstate.md)
- [GameInput](/reference/input/gameinput/gameinput_members.md)
- [GameInputGamepadButtons](/reference/input/gameinput/enums/gameinputgamepadbuttons.md)
- [GameInputGamepadAxes](/reference/input/gameinput/enums/gameinputgamepadaxes.md)
- [GameInputArcadeStickState](/reference/input/gameinput/structs/gameinputarcadestickstate.md)
