Exemple #1
0
 private bool IsGamePadButtonTapped(Buttons button)
 {
     return(PreviousGamePadState.IsButtonDown(button) && CurrentGamePadState.IsButtonUp(button));
 }
Exemple #2
0
 /// <summary>
 /// Gets whether the given button was just released.
 /// </summary>
 /// <param name="button">The given button.</param>
 /// <returns>True if the button was just released, false otherwise.</returns>
 public static bool GetButtonDownUp(Buttons button)
 {
     return(PreviousGamePadState.IsButtonDown(button) && CurrentGamePadState.IsButtonUp(button));
 }