Audio update
This commit is contained in:
@ -2,6 +2,7 @@
|
||||
#include "../core/state/StateManager.h"
|
||||
#include "../graphics/ui/Font.h"
|
||||
#include "../audio/Audio.h"
|
||||
#include "../audio/AudioManager.h"
|
||||
#include "../audio/SoundEffect.h"
|
||||
#include <SDL3/SDL.h>
|
||||
#include <algorithm>
|
||||
@ -220,7 +221,7 @@ void OptionsState::toggleFullscreen() {
|
||||
}
|
||||
|
||||
void OptionsState::toggleMusic() {
|
||||
Audio::instance().toggleMute();
|
||||
if (auto sys = ::AudioManager::get()) sys->toggleMute();
|
||||
// If muted, music is disabled. If not muted, music is enabled.
|
||||
// Note: Audio::instance().isMuted() returns true if muted.
|
||||
// But Audio class doesn't expose isMuted directly in header usually?
|
||||
|
||||
Reference in New Issue
Block a user