/// <summary> /// Updates the keyboard state and fires any necessary binding events. /// </summary> /// <param name="time">The GameTime object from the XNA framework.</param> public virtual void Update(GameTime time) { KeyboardState keystate = Keyboard.GetState(); MouseState mState = Mouse.GetState(); _Binds.ForEach(ForEachUpdate, keystate, mState, null); _ScrollValue = mState.ScrollWheelValue; }
/// <summary> /// Fires the input recieved event. /// </summary> /// <param name="bind">The key binding who's state has changed.</param> protected virtual void OnInput(Bind bind) { if (InputRecieved != null) { InputRecieved(bind); } _Screens.ForEach(ForEachInput, bind, null, null); }