Esempio n. 1
0
 private void SetValueIfNeeded(Xbox360Slider slider, double?value)
 {
     if (value.HasValue)
     {
         var newValue = (byte)(value.Value * byte.MaxValue);
         controller.SetSliderValue(slider, newValue);
     }
 }
Esempio n. 2
0
        public void SetSliderValue(Xbox360Slider slider, byte value)
        {
            switch (slider.Name)
            {
            case "LeftTrigger":
                _nativeReport.bLeftTrigger = value;
                break;

            case "RightTrigger":
                _nativeReport.bRightTrigger = value;
                break;
            }

            if (AutoSubmitReport)
            {
                SubmitNativeReport(_nativeReport);
            }
        }
Esempio n. 3
0
 public VigemXbox360SliderMapping(Xbox360Slider slider)
 {
     Type = slider;
 }
 public static void SetSlider(int controllerId, Xbox360Slider slider, byte value)
 {
     singleton.gamepads[controllerId].SetSliderValue(slider, value);
 }