diff options
Diffstat (limited to 'src/audio/AudioManager.cpp')
-rw-r--r-- | src/audio/AudioManager.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/audio/AudioManager.cpp b/src/audio/AudioManager.cpp index 368c08e8..c0479002 100644 --- a/src/audio/AudioManager.cpp +++ b/src/audio/AudioManager.cpp @@ -172,9 +172,7 @@ cAudioManager::AddReflectionsToRequestedQueue() reflectionDistance = m_afReflectionsDistances[i]; if(reflectionDistance > 0.0f && reflectionDistance < 100.f && reflectionDistance < m_sQueueSample.m_fSoundIntensity) { - m_sQueueSample.m_bLoopsRemaining = - (reflectionDistance * - 0.38873f); // @todo assert value, here used from VC + m_sQueueSample.m_bLoopsRemaining = (reflectionDistance * 500.f / 1029.f); if(m_sQueueSample.m_bLoopsRemaining > 5u) { m_sQueueSample.m_fDistance = m_afReflectionsDistances[i]; m_sQueueSample.m_bEmittingVolume = emittingVolume; @@ -287,8 +285,8 @@ cAudioManager::AddSampleToRequestedQueue() calculatedVolume = m_sQueueSample.field_16 * (maxVolume - m_sQueueSample.m_bVolume); sampleIndex = m_bSampleRequestQueuesStatus[m_bActiveSampleQueue]; if(sampleIndex >= m_bActiveSamples) { - sampleIndex = *(&m_asSamples[1][26].field_91 + m_bActiveSamples + - 27 * m_bActiveSampleQueue); + sampleIndex = + m_abSampleQueueIndexTable[m_bActiveSampleQueue][m_bActiveSamples - 1]; if(m_asSamples[m_bActiveSampleQueue][sampleIndex].calculatedVolume <= calculatedVolume) return; |