Joystick axis move event parameters
Inheritance: System.EventArgs
Example #1
0
 void OnJoystickMoved(object sender, JoystickMoveEventArgs e)
 {
     //Console.WriteLine("Joystick " + e.JoystickId + " moved axis " + e.Axis + " to " + e.Position);
 }
Example #2
0
 /// <summary>
 /// Handles the JoyMoved event of the <see cref="GameBase.RenderWindow"/>.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="SFML.Window.JoystickMoveEventArgs"/> instance containing the event data.</param>
 void rw_JoystickMoved(object sender, JoystickMoveEventArgs e)
 {
     if (JoyMoved != null)
         JoyMoved.Raise(this, e);
 }
Example #3
0
 /// <summary>
 /// Protected overridable handler that raises JoystickMoved event.
 /// </summary>
 protected virtual void OnJoystickMoved(JoystickMoveEventArgs args)
 {
     JoystickMoved?.Invoke(this, args);
 }
Example #4
0
 static void JoystickMoved(object sender, JoystickMoveEventArgs e)
 {
     EventMgr.Notify (Event.JoystickMoved, e);
 }
Example #5
0
        private void window_JoyMoved(object sender, JoystickMoveEventArgs e)
        {
            Event evt = new Event();
            evt.Type = EventType.JoystickMoved;
            evt.JoystickMove.Axis = e.Axis;
            evt.JoystickMove.JoystickId = e.JoystickId;
            evt.JoystickMove.Position = e.Position;

            Events.Enqueue(evt);
        }