1
0
Fork 0
mirror of https://git.rip/DMCA_FUCKER/re3.git synced 2024-12-22 22:20:01 +00:00

Merge pull request #947 from withmorten/miami

fix CPed struct, GetWantedLevel
This commit is contained in:
aap 2021-01-11 22:46:06 +01:00 committed by GitHub
commit afcb794d59
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 8 additions and 2 deletions

View file

@ -41,6 +41,7 @@ public:
int32 NumOfHelisRequired();
void SetWantedLevel(int32);
void SetWantedLevelNoDrop(int32 level);
int32 GetWantedLevel() { return m_nWantedLevel; }
void CheatWantedLevel(int32 level);
void RegisterCrime(eCrimeType type, const CVector &coors, uint32 id, bool policeDoesntCare);
void RegisterCrime_Immediately(eCrimeType type, const CVector &coors, uint32 id, bool policeDoesntCare);

View file

@ -492,10 +492,15 @@ public:
uint32 bDonePositionOutOfCollision : 1;
uint32 bCanAttackPlayerWithCops : 1;
#ifdef KANGAROO_CHEAT
// our own flags
uint32 m_ped_flagI80 : 1; // KANGAROO_CHEAT define makes use of this as cheat toggle
#endif
uint8 m_gangFlags;
uint8 m_unused15D; // these 3 can't be padding but had to actually have been members ...
uint8 m_unused15E;
uint8 m_unused15F;
uint8 CharCreatedBy;
eObjective m_objective;
eObjective m_prevObjective;
@ -536,7 +541,7 @@ public:
uint32 m_pathNodeTimer;
CPathNode m_pathNodeObjPool[8];
CPathNode* m_pCurPathNode;
char m_nPathDir;
int8 m_nPathDir;
CPathNode* m_pLastPathNode;
CPathNode* m_pNextPathNode;
CVector m_followPathDestPos;

View file

@ -288,7 +288,7 @@ CAutomobile::ProcessControl(void)
// Improve grip of vehicles in certain cases
bool strongGrip1 = false;
bool strongGrip2 = false;
if(FindPlayerVehicle() && this != FindPlayerVehicle() && FindPlayerPed()->m_pWanted->m_nWantedLevel > 3 &&
if(FindPlayerVehicle() && this != FindPlayerVehicle() && FindPlayerPed()->m_pWanted->GetWantedLevel() > 3 &&
(AutoPilot.m_nCarMission == MISSION_RAMPLAYER_FARAWAY || AutoPilot.m_nCarMission == MISSION_RAMPLAYER_CLOSE ||
AutoPilot.m_nCarMission == MISSION_BLOCKPLAYER_FARAWAY || AutoPilot.m_nCarMission == MISSION_BLOCKPLAYER_CLOSE) &&
FindPlayerSpeed().Magnitude() > 0.3f){