/// <summary> /// Initialize state. /// </summary> private UserInput(IntPtr parentHandle) { _parentHandle = parentHandle; // Instantiate controller and open device. _usb = new UsbSingleNintendoController(parentHandle); _usb.FindController(); }
/// <summary> /// Initializes a new instance of the <see cref="NintendoController"/> class. /// </summary> /// <param name="game">The game.</param> public NintendoController(Game game) { this._controller = new UsbSingleNintendoController(game.Window.Handle); this._previousState = NintendoControllerState.Disconnected; }