diff options
| author | Gustav Sörnäs <gustav@sornas.net> | 2021-01-03 19:14:13 +0100 |
|---|---|---|
| committer | Gustav Sörnäs <gustav@sornas.net> | 2021-01-03 19:17:14 +0100 |
| commit | fc208994a1e1228b79091303920fc90e066a087f (patch) | |
| tree | 561fd89dd9bdcac352ddcb437c8f000020898fdc /mumd | |
| parent | 3e9b55d70301cdb322a1d2aa2fb599b55521621d (diff) | |
| download | mum-fc208994a1e1228b79091303920fc90e066a087f.tar.gz | |
remove unused return type
Diffstat (limited to 'mumd')
| -rw-r--r-- | mumd/src/audio.rs | 6 | ||||
| -rw-r--r-- | mumd/src/state.rs | 4 |
2 files changed, 3 insertions, 7 deletions
diff --git a/mumd/src/audio.rs b/mumd/src/audio.rs index 0e53a63..fe0ce40 100644 --- a/mumd/src/audio.rs +++ b/mumd/src/audio.rs @@ -202,11 +202,11 @@ impl Audio { user_volumes, play_sounds, }; - res.load_sound_effects(&vec![]).unwrap(); + res.load_sound_effects(&vec![]); res } - pub fn load_sound_effects(&mut self, sound_effects: &Vec<SoundEffect>) -> Result<(), ()> { + pub fn load_sound_effects(&mut self, sound_effects: &Vec<SoundEffect>) { let overrides: HashMap<_, _> = sound_effects .iter() .map(|sound_effect| { (&sound_effect.event, &sound_effect.file) }) @@ -272,8 +272,6 @@ impl Audio { (event, samples) }) .collect(); - - Ok(()) } pub fn decode_packet(&self, session_id: u32, payload: VoicePacketPayload) { diff --git a/mumd/src/state.rs b/mumd/src/state.rs index 47aef66..84247bc 100644 --- a/mumd/src/state.rs +++ b/mumd/src/state.rs @@ -574,9 +574,7 @@ impl State { self.audio.set_output_volume(output_volume); } if let Some(sound_effects) = &self.config.audio.sound_effects { - if let Err(e) = self.audio.load_sound_effects(sound_effects) { - warn!("Error loading sound effects: {:?}", e); - } + self.audio.load_sound_effects(sound_effects); } } |
