mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-04-05 04:33:51 +00:00
Add ambient sound system and eliminate log spam
- Implement AmbientSoundManager with tavern/outdoor ambience - Fix audio buffer limit (5s → 60s) for long ambient loops - Set log level to INFO to eliminate DEBUG spam (130MB → 3.2MB logs) - Remove excessive terrain/model/network logging - Fix ambient sound timer sharing and pitch parameter bugs
This commit is contained in:
parent
4a7e599764
commit
dab23f1895
24 changed files with 701 additions and 138 deletions
|
|
@ -119,6 +119,21 @@ void MusicManager::setVolume(int volume) {
|
|||
|
||||
// Update AudioEngine music volume directly (no restart needed!)
|
||||
float vol = volumePercent / 100.0f;
|
||||
if (underwaterMode) {
|
||||
vol *= 0.3f; // 30% volume underwater
|
||||
}
|
||||
AudioEngine::instance().setMusicVolume(vol);
|
||||
}
|
||||
|
||||
void MusicManager::setUnderwaterMode(bool underwater) {
|
||||
if (underwaterMode == underwater) return;
|
||||
underwaterMode = underwater;
|
||||
|
||||
// Apply volume change immediately
|
||||
float vol = volumePercent / 100.0f;
|
||||
if (underwaterMode) {
|
||||
vol *= 0.3f; // Fade to 30% underwater
|
||||
}
|
||||
AudioEngine::instance().setMusicVolume(vol);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue