From 396b43cbd4f5495c6c3c555d6b58ccfdbbf964fb Mon Sep 17 00:00:00 2001 From: aap Date: Fri, 5 Jul 2019 14:23:39 +0200 Subject: implemented some CVehicle functions --- src/control/Population.cpp | 1 + src/control/Population.h | 4 +++- src/control/Replay.cpp | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) (limited to 'src/control') diff --git a/src/control/Population.cpp b/src/control/Population.cpp index 9af68670..1ae5962d 100644 --- a/src/control/Population.cpp +++ b/src/control/Population.cpp @@ -10,3 +10,4 @@ float &CPopulation::PedDensityMultiplier = *(float*)0x5FA56C; WRAPPER void CPopulation::UpdatePedCount(uint32, bool) { EAXJMP(0x4F5A60); } WRAPPER void CPopulation::DealWithZoneChange(eLevelName oldLevel, eLevelName newLevel, bool) { EAXJMP(0x4F6200); } +WRAPPER CPed *CPopulation::AddPedInCar(CVehicle *vehicle) { EAXJMP(0x4F5800); } diff --git a/src/control/Population.h b/src/control/Population.h index 4169261a..6bd2e3ae 100644 --- a/src/control/Population.h +++ b/src/control/Population.h @@ -1,6 +1,7 @@ #pragma once -#include "PedType.h" +class CPed; +class CVehicle; struct PedGroup { @@ -17,4 +18,5 @@ public: static void UpdatePedCount(uint32, bool); static void DealWithZoneChange(eLevelName oldLevel, eLevelName newLevel, bool); + static CPed *AddPedInCar(CVehicle *vehicle); }; diff --git a/src/control/Replay.cpp b/src/control/Replay.cpp index a2164f6b..12fce4ef 100644 --- a/src/control/Replay.cpp +++ b/src/control/Replay.cpp @@ -717,7 +717,7 @@ void CReplay::ProcessCarUpdate(CVehicle *vehicle, float interpolation, CAddressI car->m_DamageManager.SetDoorStatus(CDamageManager::CAR_DOOR_RR, 3); car->SetDoorDamage(12, CDamageManager::CAR_DOOR_RR, true); } - vehicle->m_veh_flagA10 = true; + vehicle->bEngineOn = true; if (vehicle->IsCar()) ((CAutomobile*)vehicle)->m_nDriveWheelsOnGround = 4; CWorld::Remove(vehicle); -- cgit v1.2.3