summaryrefslogtreecommitdiffstats
path: root/src/peds/PedAI.cpp
diff options
context:
space:
mode:
authoraap <aap@papnet.eu>2021-01-02 20:30:12 +0100
committeraap <aap@papnet.eu>2021-01-02 20:30:12 +0100
commit0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf (patch)
tree2c8584344263fd2f06b6cad574004f601e3adb2f /src/peds/PedAI.cpp
parent"clarification" of handling code (diff)
downloadre3-0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf.tar
re3-0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf.tar.gz
re3-0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf.tar.bz2
re3-0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf.tar.lz
re3-0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf.tar.xz
re3-0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf.tar.zst
re3-0d05be4e31a40d7ed84f5f0d59b7aee7cd40dfaf.zip
Diffstat (limited to '')
-rw-r--r--src/peds/PedAI.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/peds/PedAI.cpp b/src/peds/PedAI.cpp
index a747c684..cc27992c 100644
--- a/src/peds/PedAI.cpp
+++ b/src/peds/PedAI.cpp
@@ -832,10 +832,10 @@ CPed::ProcessObjective(void)
m_pMyVehicle->SetStatus(STATUS_PHYSICS);
m_pMyVehicle->AutoPilot.m_nPrevRouteNode = 0;
if (m_nPedType == PEDTYPE_COP) {
- m_pMyVehicle->AutoPilot.m_nCruiseSpeed = (FindPlayerPed()->m_pWanted->m_nWantedLevel * 0.1f + 0.6f) * (GAME_SPEED_TO_CARAI_SPEED * m_pMyVehicle->pHandling->Transmission.fUnkMaxVelocity);
+ m_pMyVehicle->AutoPilot.m_nCruiseSpeed = (FindPlayerPed()->m_pWanted->m_nWantedLevel * 0.1f + 0.6f) * (GAME_SPEED_TO_CARAI_SPEED * m_pMyVehicle->pHandling->Transmission.fMaxCruiseVelocity);
m_pMyVehicle->AutoPilot.m_nCarMission = CCarAI::FindPoliceCarMissionForWantedLevel();
} else {
- m_pMyVehicle->AutoPilot.m_nCruiseSpeed = GAME_SPEED_TO_CARAI_SPEED * m_pMyVehicle->pHandling->Transmission.fUnkMaxVelocity * 0.8f;
+ m_pMyVehicle->AutoPilot.m_nCruiseSpeed = GAME_SPEED_TO_CARAI_SPEED * m_pMyVehicle->pHandling->Transmission.fMaxCruiseVelocity * 0.8f;
m_pMyVehicle->AutoPilot.m_nCarMission = MISSION_RAMPLAYER_FARAWAY;
}
m_pMyVehicle->AutoPilot.m_nDrivingStyle = DRIVINGSTYLE_AVOID_CARS;
@@ -4775,7 +4775,7 @@ CPed::RegisterThreatWithGangPeds(CEntity *attacker)
if (nearVehDriver && nearVehDriver != this && nearVehDriver->m_nPedType == m_nPedType) {
if (nearVeh->IsVehicleNormal() && nearVeh->IsCar()) {
- nearVeh->AutoPilot.m_nCruiseSpeed = GAME_SPEED_TO_CARAI_SPEED * nearVeh->pHandling->Transmission.fUnkMaxVelocity * 0.8f;
+ nearVeh->AutoPilot.m_nCruiseSpeed = GAME_SPEED_TO_CARAI_SPEED * nearVeh->pHandling->Transmission.fMaxCruiseVelocity * 0.8f;
nearVeh->AutoPilot.m_nCarMission = MISSION_RAMPLAYER_FARAWAY;
nearVeh->SetStatus(STATUS_PHYSICS);
nearVeh->AutoPilot.m_nTempAction = TEMPACT_NONE;