summaryrefslogtreecommitdiffstats
path: root/src/audio/AudioManager.cpp
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2019-10-26 15:23:04 +0200
committerGitHub <noreply@github.com>2019-10-26 15:23:04 +0200
commitfd8096aec8deaaa3ce3500853f8a4b4cba2b688a (patch)
tree0f5c8a4a2197ef2812d63e6333ec267eda8ddcf0 /src/audio/AudioManager.cpp
parentFix audio bug (diff)
parentA bit more enums for ChangeMusicMode (diff)
downloadre3-fd8096aec8deaaa3ce3500853f8a4b4cba2b688a.tar
re3-fd8096aec8deaaa3ce3500853f8a4b4cba2b688a.tar.gz
re3-fd8096aec8deaaa3ce3500853f8a4b4cba2b688a.tar.bz2
re3-fd8096aec8deaaa3ce3500853f8a4b4cba2b688a.tar.lz
re3-fd8096aec8deaaa3ce3500853f8a4b4cba2b688a.tar.xz
re3-fd8096aec8deaaa3ce3500853f8a4b4cba2b688a.tar.zst
re3-fd8096aec8deaaa3ce3500853f8a4b4cba2b688a.zip
Diffstat (limited to 'src/audio/AudioManager.cpp')
-rw-r--r--src/audio/AudioManager.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/audio/AudioManager.cpp b/src/audio/AudioManager.cpp
index c8e2656a..36713dbc 100644
--- a/src/audio/AudioManager.cpp
+++ b/src/audio/AudioManager.cpp
@@ -1,5 +1,6 @@
#include "common.h"
#include "patcher.h"
+#include "audio_enums.h"
#include "AudioManager.h"
@@ -582,8 +583,8 @@ cAudioManager::ComputePan(float dist, CVector *vec)
return min(107, panTable[index] + 63);
}
-uint32
-cAudioManager::ComputeVolume(int emittingVolume, float soundIntensity, float distance) const
+uint8
+cAudioManager::ComputeVolume(uint8 emittingVolume, float soundIntensity, float distance) const
{
float newSoundIntensity;
if(soundIntensity <= 0.0f) return 0;
@@ -7128,14 +7129,14 @@ cAudioManager::ProcessSpecial()
{
if(m_bUserPause) {
if(!m_bPreviousUserPause) {
- MusicManager.ChangeMusicMode(0);
+ MusicManager.ChangeMusicMode(MUSICMODE_FRONTEND);
SampleManager.SetEffectsFadeVolume(maxVolume);
SampleManager.SetMusicFadeVolume(maxVolume);
}
} else {
if(m_bPreviousUserPause) {
MusicManager.StopFrontEndTrack();
- MusicManager.ChangeMusicMode(1);
+ MusicManager.ChangeMusicMode(MUSICMODE_GAME);
}
CPlayerPed *playerPed = FindPlayerPed();
if(playerPed) {