summaryrefslogtreecommitdiffstats
path: root/src/audio/AudioLogic.cpp
diff options
context:
space:
mode:
authorRoman Masanin <36927roma@gmail.com>2020-10-12 19:55:19 +0200
committerRoman Masanin <36927roma@gmail.com>2020-10-12 19:55:19 +0200
commita4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678 (patch)
treeeedce0da18bbd842ad29159f5bad420a8c857eeb /src/audio/AudioLogic.cpp
parentmark some audio stuff and fix frameCounter (diff)
downloadre3-a4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678.tar
re3-a4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678.tar.gz
re3-a4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678.tar.bz2
re3-a4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678.tar.lz
re3-a4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678.tar.xz
re3-a4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678.tar.zst
re3-a4fd1a9f395c3ef9bf5ead3eb1eff6254b9ed678.zip
Diffstat (limited to 'src/audio/AudioLogic.cpp')
-rw-r--r--src/audio/AudioLogic.cpp26
1 files changed, 5 insertions, 21 deletions
diff --git a/src/audio/AudioLogic.cpp b/src/audio/AudioLogic.cpp
index bf99f991..7bc2b93f 100644
--- a/src/audio/AudioLogic.cpp
+++ b/src/audio/AudioLogic.cpp
@@ -2027,33 +2027,17 @@ cAudioManager::ProcessVehicleHorn(cVehicleParams *params)
}
bool
-cAudioManager::UsesSiren(int32 model) const
+cAudioManager::UsesSiren(cVehicleParams *params) const
{
- switch (model) {
- case FIRETRUK:
- case AMBULAN:
- case FBICAR:
- case POLICE:
- case ENFORCER:
- case PREDATOR:
- return true;
- default:
- return false;
- }
+ params->m_pVehicle->UsesSiren();
}
bool
-cAudioManager::UsesSirenSwitching(int32 model) const
+cAudioManager::UsesSirenSwitching(cVehicleParams *params) const
{
- switch (model) {
- case AMBULAN:
- case POLICE:
- case ENFORCER:
- case PREDATOR:
- return true;
- default:
+ if (params->m_nIndex == FIRETRUK || params->m_nIndex == MRWHOOP)
return false;
- }
+ return params->m_pVehicle->UsesSiren();
}
bool