internal bool IsButtonPressed(WiimoteButton button) { switch (button) { case (WiimoteButton.A): return(Wiimote.WiimoteState.ButtonState.A); case (WiimoteButton.B): return(Wiimote.WiimoteState.ButtonState.B); case (WiimoteButton.Left): return(Wiimote.WiimoteState.ButtonState.Left); case (WiimoteButton.Right): return(Wiimote.WiimoteState.ButtonState.Right); case (WiimoteButton.Down): return(Wiimote.WiimoteState.ButtonState.Down); case (WiimoteButton.Up): return(Wiimote.WiimoteState.ButtonState.Up); case (WiimoteButton.Home): return(Wiimote.WiimoteState.ButtonState.Home); case (WiimoteButton.Plus): return(Wiimote.WiimoteState.ButtonState.Plus); case (WiimoteButton.Minus): return(Wiimote.WiimoteState.ButtonState.Minus); case (WiimoteButton.One): return(Wiimote.WiimoteState.ButtonState.One); case (WiimoteButton.Two): return(Wiimote.WiimoteState.ButtonState.Two); } return(false); }
public void executeButtonDown(WiimoteButton button) { this.executeButtonDown(button.ToString()); }
public void executeButtonUp(WiimoteButton button) { this.executeButtonUp(button.ToString());//ToString converts WiimoteButton.A to "A" for instance }