1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-22 14:24:33 +01:00

Fix mute / unmute logic

This commit is contained in:
Ted John
2017-04-30 18:03:25 +01:00
parent 21bf897bda
commit 75e0c94082
2 changed files with 5 additions and 6 deletions

View File

@@ -398,12 +398,11 @@ void audio_close()
gAudioCurrentDevice = -1;
}
void audio_toggle_all_sounds(){
gConfigSound.sound_enabled = !gConfigSound.sound_enabled;
if (gConfigSound.sound_enabled)
void audio_toggle_all_sounds()
{
if (gGameSoundsOff) {
audio_unpause_sounds();
else {
audio_stop_title_music();
} else {
audio_pause_sounds();
}
}

View File

@@ -790,7 +790,7 @@ static void window_top_toolbar_invalidate(rct_window *w)
else
w->pressed_widgets &= ~(1 << WIDX_PAUSE);
if (gConfigSound.sound_enabled)
if (!gGameSoundsOff)
window_top_toolbar_widgets[WIDX_MUTE].image = 0x20000000 | SPR_G2_TOOLBAR_MUTE;
else
window_top_toolbar_widgets[WIDX_MUTE].image = 0x20000000 | SPR_G2_TOOLBAR_UNMUTE;