summaryrefslogtreecommitdiffstats
path: root/src/control
diff options
context:
space:
mode:
authorNikolay Korolev <nickvnuk@gmail.com>2021-08-15 17:27:30 +0200
committerNikolay Korolev <nickvnuk@gmail.com>2021-08-15 17:28:34 +0200
commit3441714a13f57eecdf6ef74d3208cf503efd588c (patch)
tree786a0807b82bda3209fec41cb37e2f2544781d46 /src/control
parentFix .ini fix for glfw (diff)
downloadre3-3441714a13f57eecdf6ef74d3208cf503efd588c.tar
re3-3441714a13f57eecdf6ef74d3208cf503efd588c.tar.gz
re3-3441714a13f57eecdf6ef74d3208cf503efd588c.tar.bz2
re3-3441714a13f57eecdf6ef74d3208cf503efd588c.tar.lz
re3-3441714a13f57eecdf6ef74d3208cf503efd588c.tar.xz
re3-3441714a13f57eecdf6ef74d3208cf503efd588c.tar.zst
re3-3441714a13f57eecdf6ef74d3208cf503efd588c.zip
Diffstat (limited to 'src/control')
-rw-r--r--src/control/CarAI.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/control/CarAI.cpp b/src/control/CarAI.cpp
index 8e79fee1..2609436f 100644
--- a/src/control/CarAI.cpp
+++ b/src/control/CarAI.cpp
@@ -584,8 +584,11 @@ void CCarAI::TellOccupantsToLeaveCar(CVehicle* pVehicle)
{
if (pVehicle->pDriver){
pVehicle->pDriver->SetObjective(OBJECTIVE_LEAVE_CAR, pVehicle);
- if (pVehicle->GetModelIndex() == MI_AMBULAN)
+ switch (pVehicle->GetModelIndex()) {
+ case MI_AMBULAN:
pVehicle->pDriver->Say(SOUND_PED_LEAVE_VEHICLE);
+ break;
+ }
}
int timer = 100;
for (int i = 0; i < pVehicle->m_nNumMaxPassengers; i++){