Esempio n. 1
0
 public void PrepareHapticsForHost(SimpleController finalHostController)
 {
     foreach (var kvp in _feedbackBindings)
     {
         if (_haptics.TryGetValue(kvp.Key, out var strength))
         {
             finalHostController.SetHapticChannelStrength(kvp.Value.GamepadPrefix + kvp.Value.Channel, (int)((double)strength * kvp.Value.Prescale));
         }
     }
 }
Esempio n. 2
0
 public void PrepareHapticsForHost(SimpleController finalHostController)
 {
     foreach (var(k, v) in _feedbackBindings)
     {
         if (_haptics.TryGetValue(k, out var strength))
         {
             foreach (var hostChannel in v.Channels !.Split('+'))
             {
                 finalHostController.SetHapticChannelStrength(v.GamepadPrefix + hostChannel, (int)((double)strength * v.Prescale));
             }
         }
     }
 }