public JoystickController(int index) { IsValid = asd.Engine.JoystickContainer.GetIsPresentAt(index); joystick = asd.Engine.JoystickContainer.GetJoystickAt(index); binding = new Dictionary <TControl, IJoystickInput>(); axisTiltBinding = new Dictionary <TTiltControl, int>(); }
public asd.ButtonState GetState(asd.Joystick joystick) { if (currentState) { return(previousState ? asd.ButtonState.Hold : asd.ButtonState.Push); } else { return(previousState ? asd.ButtonState.Release : asd.ButtonState.Free); } }
public void Update(asd.Joystick joystick) { previousState = currentState; currentState = joystick.GetAxisState(axisIndex) == direction; }
public void Update(asd.Joystick joystick) { }
public asd.ButtonState GetState(asd.Joystick joystick) { return(joystick.GetButtonState(index)); }