ScreenManagement.InputState.IsNewButtonPress C# (CSharp) Method

IsNewButtonPress() public method

Helper for checking if a button was newly pressed during this update. This method is designed for use in one-player games and only checks the gamepad for player one.
public IsNewButtonPress ( Buttons button ) : bool
button Buttons
return bool
        public bool IsNewButtonPress(Buttons button)
        {
            return (CurrentGamePadStates[0].IsButtonDown(button) &&
                    LastGamePadStates[0].IsButtonUp(button));
        }

Same methods

InputState::IsNewButtonPress ( Buttons button, PlayerIndex controllingPlayer, PlayerIndex &playerIndex ) : bool