summaryrefslogtreecommitdiffstats
path: root/src/peds
diff options
context:
space:
mode:
authorerorcun <erorcunerorcun@hotmail.com.tr>2021-02-08 11:23:19 +0100
committererorcun <erorcunerorcun@hotmail.com.tr>2021-02-08 11:23:19 +0100
commitb464bb7fd43a86264e816e950ccac1d6845b0230 (patch)
tree1070200f94f1f7adf4ae26950011884e1956576d /src/peds
parentUse our synonyms for attack anims again (diff)
parentreorganize shaders; use modulate flag; update librw (diff)
downloadre3-b464bb7fd43a86264e816e950ccac1d6845b0230.tar
re3-b464bb7fd43a86264e816e950ccac1d6845b0230.tar.gz
re3-b464bb7fd43a86264e816e950ccac1d6845b0230.tar.bz2
re3-b464bb7fd43a86264e816e950ccac1d6845b0230.tar.lz
re3-b464bb7fd43a86264e816e950ccac1d6845b0230.tar.xz
re3-b464bb7fd43a86264e816e950ccac1d6845b0230.tar.zst
re3-b464bb7fd43a86264e816e950ccac1d6845b0230.zip
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)