Esempio n. 1
0
 private void HandleChannelMessagePlayed(object sender, ChannelMessageEventArgs e)
 {
     if (ConfigManager.GetProperty(PropertyItem.NoteConversionMode) != "1")
     {
         if (ConfigManager.GetBooleanProperty(PropertyItem.SoundEffects) && !disposed)
         {
             outDevice.Send(mordhauOutDevice.FilterNote(trackSelectionManager.FilterMidiEvent(e.Message, e.TrackId)));
         }
         else
         {
             mordhauOutDevice.SendNote(trackSelectionManager.FilterMidiEvent(e.Message, e.TrackId));
         }
     }
     else
     {
         outDevice.Send(trackSelectionManager.FilterMidiEvent(e.Message, e.TrackId));
     }
 }
Esempio n. 2
0
 private void HandleChannelMessagePlayed(object sender, ChannelMessageEventArgs e)
 {
     if (ConfigManager.GetProperty(PropertyItem.NoteConversionMode) != "1")
     {
         if (ConfigManager.GetBooleanProperty(PropertyItem.SoundEffects) && !disposed)
         {
             try
             {
                 outDevice.Send(mordhauOutDevice.FilterNote(trackSelectionManager.FilterMidiEvent(e.Message, e.TrackId)));
             }
             catch (Exception) { }
             // You can edit the track while it's playing and the edits will take place live in Mordhau as it's playing.
             // Though you probably shouldn't do this, but it's better than just erroring out.
         }
         else
         {
             mordhauOutDevice.SendNote(trackSelectionManager.FilterMidiEvent(e.Message, e.TrackId));
         }
     }
     else
     {
         outDevice.Send(trackSelectionManager.FilterMidiEvent(e.Message, e.TrackId));
     }
 }