GamePadState.DPad Property

Returns a structure that identifies what directions of the directional pad on the Xbox 360 Controller are pressed.

Namespace: Microsoft.Xna.Framework.Input
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)

Syntax

public GamePadDPad DPad { get; }

Property Value

Structure that identifies what directional pad directions are pressed.

Remarks

Bb196396.bp(en-us,XNAGameStudio.41).gifBest Practice
Many games allow movement to be controlled with either the left thumbstick or the directional pad (d-pad). The left thumbstick may be accessed with GamePadState.ThumbSticks.

See Also

Reference

GamePadState Structure
GamePadState Members
Microsoft.Xna.Framework.Input Namespace

Platforms

Xbox 360, Windows 7, Windows Vista, Windows XP, Windows Phone