summaryrefslogtreecommitdiffstats
path: root/src/audio
diff options
context:
space:
mode:
authorRoman Masanin <36927roma@gmail.com>2020-11-01 21:48:03 +0100
committerRoman Masanin <36927roma@gmail.com>2020-11-01 21:48:03 +0100
commitfad0a9507d4a4eb63fc5a658c2886fe07f7dadee (patch)
tree65221a96d38889dc2dda367a9eb5563316c92eab /src/audio
parentMerge branch 'master' of https://github.com/GTAmodding/re3 (diff)
downloadre3-fad0a9507d4a4eb63fc5a658c2886fe07f7dadee.tar
re3-fad0a9507d4a4eb63fc5a658c2886fe07f7dadee.tar.gz
re3-fad0a9507d4a4eb63fc5a658c2886fe07f7dadee.tar.bz2
re3-fad0a9507d4a4eb63fc5a658c2886fe07f7dadee.tar.lz
re3-fad0a9507d4a4eb63fc5a658c2886fe07f7dadee.tar.xz
re3-fad0a9507d4a4eb63fc5a658c2886fe07f7dadee.tar.zst
re3-fad0a9507d4a4eb63fc5a658c2886fe07f7dadee.zip
Diffstat (limited to 'src/audio')
-rw-r--r--src/audio/AudioLogic.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/audio/AudioLogic.cpp b/src/audio/AudioLogic.cpp
index 3fc9334f..1e8a8194 100644
--- a/src/audio/AudioLogic.cpp
+++ b/src/audio/AudioLogic.cpp
@@ -1930,7 +1930,6 @@ cAudioManager::ProcessVehicleOneShots(cVehicleParams *params)
m_sQueueSample.m_nSampleIndex = SFX_OLD_CAR_DOOR_CLOSE;
break;
case NEW_DOOR:
- default:
m_sQueueSample.m_nSampleIndex = SFX_NEW_CAR_DOOR_CLOSE;
break;
case TRUCK_DOOR:
@@ -1939,9 +1938,12 @@ cAudioManager::ProcessVehicleOneShots(cVehicleParams *params)
case BUS_DOOR:
m_sQueueSample.m_nSampleIndex = SFX_AIR_BRAKES;
break;
+ default:
+ m_sQueueSample.m_nSampleIndex = SFX_NEW_CAR_DOOR_CLOSE;
+ break;
}
m_sQueueSample.m_nBankIndex = SFX_BANK_0;
- m_sQueueSample.m_nCounter = m_asAudioEntities[m_sQueueSample.m_nEntityIndex].m_awAudioEvent[i] + 22;
+ m_sQueueSample.m_nCounter = event + 22; //originaly used m_asAudioEntities[m_sQueueSample.m_nEntityIndex].m_awAudioEvent[i], which is same
m_sQueueSample.m_nFrequency = SampleManager.GetSampleBaseFrequency(m_sQueueSample.m_nSampleIndex);
m_sQueueSample.m_nFrequency += RandomDisplacement(m_sQueueSample.m_nFrequency / 32);
m_sQueueSample.m_nReleasingVolumeModificator = 3;
@@ -1975,7 +1977,7 @@ cAudioManager::ProcessVehicleOneShots(cVehicleParams *params)
break;
}
m_sQueueSample.m_nBankIndex = SFX_BANK_0;
- m_sQueueSample.m_nCounter = m_asAudioEntities[m_sQueueSample.m_nEntityIndex].m_awAudioEvent[i] + 10;
+ m_sQueueSample.m_nCounter = event + 10; //also used m_asAudioEntities[m_sQueueSample.m_nEntityIndex].m_awAudioEvent[i]
m_sQueueSample.m_nFrequency = SampleManager.GetSampleBaseFrequency(m_sQueueSample.m_nSampleIndex);
m_sQueueSample.m_nFrequency += RandomDisplacement(m_sQueueSample.m_nFrequency / 32);
m_sQueueSample.m_nReleasingVolumeModificator = 3;