summaryrefslogtreecommitdiffstats
path: root/src/peds
diff options
context:
space:
mode:
Diffstat (limited to 'src/peds')
-rw-r--r--src/peds/Ped.cpp2
-rw-r--r--src/peds/Ped.h2
-rw-r--r--src/peds/PedAttractor.cpp4
3 files changed, 6 insertions, 2 deletions
diff --git a/src/peds/Ped.cpp b/src/peds/Ped.cpp
index 1484d578..12437dcd 100644
--- a/src/peds/Ped.cpp
+++ b/src/peds/Ped.cpp
@@ -1609,7 +1609,7 @@ CPed::ProcessBuoyancy(void)
color.r = (0.5f * CTimeCycle::GetDirectionalRed() + CTimeCycle::GetAmbientRed()) * 127.5f;
color.g = (0.5f * CTimeCycle::GetDirectionalBlue() + CTimeCycle::GetAmbientBlue()) * 127.5f;
color.b = (0.5f * CTimeCycle::GetDirectionalGreen() + CTimeCycle::GetAmbientGreen()) * 127.5f;
- color.a = (CGeneral::GetRandomNumber() % 256 * 48.0f) + 48;
+ color.a = CGeneral::GetRandomNumberInRange(48.0f, 96.0f);
bIsInWater = true;
ApplyMoveForce(buoyancyImpulse);
if (!DyingOrDead()) {
diff --git a/src/peds/Ped.h b/src/peds/Ped.h
index ec6574de..c94cd320 100644
--- a/src/peds/Ped.h
+++ b/src/peds/Ped.h
@@ -639,7 +639,7 @@ public:
uint32 m_threatFlags;
uint32 m_threatCheckTimer;
uint32 m_threatCheckInterval;
- uint32 m_delayedSoundID;
+ int32 m_delayedSoundID;
uint32 m_delayedSoundTimer;
uint32 m_lastSoundStart;
uint32 m_soundStart;
diff --git a/src/peds/PedAttractor.cpp b/src/peds/PedAttractor.cpp
index de587270..11fb5b31 100644
--- a/src/peds/PedAttractor.cpp
+++ b/src/peds/PedAttractor.cpp
@@ -113,7 +113,11 @@ const C2dEffect* CPedAttractorManager::GetEffectForIceCreamVan(CVehicle* pVehicl
CVehicleToEffect effect(pVehicle);
vVehicleToEffect.push_back(effect);
POP_MEMID();
+#ifdef FIX_BUGS
+ return vVehicleToEffect.back().ChooseEffect(pos);
+#else
return effect.ChooseEffect(pos);
+#endif
}
CVehicle* CPedAttractorManager::GetIceCreamVanForEffect(C2dEffect* pEffect)