> ## 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.

# XINPUT_STATE

> XINPUT_STATE

# XINPUT\_STATE

Décrit l'état d'une manette.

## Syntaxe

```cpp theme={null}
typedef struct XINPUT_STATE {  
    DWORD dwPacketNumber;  
    XINPUT_GAMEPAD Gamepad;  
} XINPUT_STATE  
```

### Membres

*dwPacketNumber*\
Type : DWORD

Numéro de paquet d'état. Le numéro de paquet indique si l'état de la manette a changé. Si la valeur est identique dans des objets `XINPUT_STATE` renvoyés successivement, l'état de la manette n'a pas changé.

*Gamepad*\
Type : [XINPUT\_GAMEPAD](https://docs.xbox.com/fr/reference/input/xinputongameinput/structs/xinput_gamepad.md)

Objet [XINPUT\_GAMEPAD](https://docs.xbox.com/fr/reference/input/xinputongameinput/structs/xinput_gamepad.md) qui contient l'état actuel d'une manette.

## Remarques

La valeur de *dwPacketNumber* n'est incrémentée que si l'état de la manette a changé depuis la dernière interrogation de la manette.

Cette structure est utilisée par les fonctions [XInputGetState](https://docs.xbox.com/fr/reference/input/xinputongameinput/functions/xinputgetstate.md) et [XInputGetStateWithToken](https://docs.xbox.com/fr/reference/input/xinputongameinput/functions/xinputgetstatewithtoken.md).

Pour plus d'informations, consultez [Le wrapper XInputOnGameInput](https://docs.xbox.com/fr/build/core-features/common/input/porting/input-porting-xinput.md#xinputWrapperSection).

## Configuration requise

**En-tête :** XInputOnGameInput.h

**Plateformes prises en charge :** consoles de la famille XBOX One et consoles XBOX Series

## Voir aussi

[Portage de XInput vers GameInput](https://docs.xbox.com/fr/build/core-features/common/input/porting/input-porting-xinput.md)\
[XInputOnGameInput](https://docs.xbox.com/fr/reference/input/xinputongameinput/xinputongameinput_members.md)


## Related topics

- [XInputGetState](https://docs.xbox.com/fr/reference/input/xinputongameinput/functions/xinputgetstate.md)
- [XInputGetStateWithToken](https://docs.xbox.com/fr/reference/input/xinputongameinput/functions/xinputgetstatewithtoken.md)
- [XINPUT_GAMEPAD](https://docs.xbox.com/fr/reference/input/xinputongameinput/structs/xinput_gamepad.md)
- [XInputOnGameInput (contenu de l'API)](https://docs.xbox.com/fr/reference/input/xinputongameinput/xinputongameinput_members.md)
- [XINPUT_VIBRATION](https://docs.xbox.com/fr/reference/input/xinputongameinput/structs/xinput_vibration.md)
