From f90044d343ff97ca54c09e9f5360eba87744b613 Mon Sep 17 00:00:00 2001 From: rubidium Date: Sat, 5 Mar 2011 18:00:48 +0000 Subject: (svn r22202) -Codechange: make MusicFileSettings a proper citizen of the client settings --- src/sound.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'src/sound.cpp') diff --git a/src/sound.cpp b/src/sound.cpp index 060eb6073..4b6886d36 100644 --- a/src/sound.cpp +++ b/src/sound.cpp @@ -22,7 +22,6 @@ #include "base_media_func.h" static SoundEntry _original_sounds[ORIGINAL_SAMPLE_COUNT]; -MusicFileSettings _msf; static void OpenBankFile(const char *filename) { @@ -227,7 +226,7 @@ void SndCopyToPool() */ static void SndPlayScreenCoordFx(SoundID sound, int left, int right, int top, int bottom) { - if (_msf.effect_vol == 0) return; + if (_settings_client.music.effect_vol == 0) return; const Window *w; FOR_ALL_WINDOWS_FROM_BACK(w) { @@ -243,7 +242,7 @@ static void SndPlayScreenCoordFx(SoundID sound, int left, int right, int top, in StartSound( sound, panning, - (_msf.effect_vol * _vol_factor_by_zoom[vp->zoom - ZOOM_LVL_BEGIN]) / 256 + (_settings_client.music.effect_vol * _vol_factor_by_zoom[vp->zoom - ZOOM_LVL_BEGIN]) / 256 ); return; } @@ -272,7 +271,7 @@ void SndPlayVehicleFx(SoundID sound, const Vehicle *v) void SndPlayFx(SoundID sound) { - StartSound(sound, 0.5, _msf.effect_vol); + StartSound(sound, 0.5, _settings_client.music.effect_vol); } INSTANTIATE_BASE_MEDIA_METHODS(BaseMedia, SoundsSet) -- cgit v1.2.3-54-g00ecf