mirror of
https://github.com/halpz/re3.git
synced 2025-06-30 00:06:20 +00:00
Merge branch 'miami' of https://github.com/GTAmodding/re3 into miami
This commit is contained in:
@ -325,7 +325,7 @@ CCivilianPed::ProcessControl(void)
|
||||
CWorld::Players[CWorld::PlayerInFocus].m_nSexFrequency = Max(250, playerSexFrequency - 10);
|
||||
}
|
||||
|
||||
m_pMyVehicle->pDriver->m_fHealth = Min(125.0f, 1.0f + m_pMyVehicle->pDriver->m_fHealth);
|
||||
m_pMyVehicle->pDriver->m_fHealth = Min(CWorld::Players[0].m_nMaxHealth + 25.0f, 1.0f + m_pMyVehicle->pDriver->m_fHealth);
|
||||
if (CWorld::Players[CWorld::PlayerInFocus].m_nSexFrequency == 250)
|
||||
CWorld::Players[CWorld::PlayerInFocus].m_nNextSexFrequencyUpdateTime = CTimer::GetTimeInMilliseconds() + 3000;
|
||||
} else {
|
||||
@ -336,7 +336,7 @@ CCivilianPed::ProcessControl(void)
|
||||
} else {
|
||||
bWanderPathAfterExitingCar = true;
|
||||
CWorld::Players[CWorld::PlayerInFocus].m_pHooker = nil;
|
||||
m_pMyVehicle->pDriver->m_fHealth = 125.0f;
|
||||
m_pMyVehicle->pDriver->m_fHealth = CWorld::Players[0].m_nMaxHealth + 25.0f;
|
||||
SetObjective(OBJECTIVE_LEAVE_VEHICLE, m_pMyVehicle);
|
||||
}
|
||||
} else {
|
||||
|
@ -513,6 +513,8 @@ CPed::CPed(uint32 pedType) : m_pedIK(this)
|
||||
m_fAirResistance = 0.4f / m_fMass;
|
||||
m_fElasticity = 0.05f;
|
||||
|
||||
m_ceaseAttackTimer = 0;
|
||||
|
||||
bIsStanding = false;
|
||||
bWasStanding = false;
|
||||
bIsAttacking = false;
|
||||
@ -18604,4 +18606,29 @@ bool
|
||||
CPed::CanBeDamagedByThisGangMember(CPed* who)
|
||||
{
|
||||
return m_gangFlags & (1 << (uint8)(who->m_nPedType - PEDTYPE_GANG1));
|
||||
}
|
||||
|
||||
bool
|
||||
IsPedPointerValid_NotInWorld(CPed* pPed)
|
||||
{
|
||||
if (!pPed)
|
||||
return false;
|
||||
int index = CPools::GetPedPool()->GetJustIndex(pPed);
|
||||
#ifdef FIX_BUGS
|
||||
if (index < 0 || index >= NUMPEDS)
|
||||
#else
|
||||
if (index < 0 || index > NUMPEDS)
|
||||
#endif
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool
|
||||
IsPedPointerValid(CPed* pPed)
|
||||
{
|
||||
if (!IsPedPointerValid_NotInWorld(pPed))
|
||||
return false;
|
||||
if (pPed->bInVehicle && pPed->m_pMyVehicle)
|
||||
return IsEntityPointerValid(pPed->m_pMyVehicle);
|
||||
return pPed->m_entryInfoList.first || pPed == FindPlayerPed();
|
||||
}
|
@ -220,7 +220,7 @@ enum eObjective : uint32 {
|
||||
OBJECTIVE_LEAVE_CAR_AND_DIE,
|
||||
OBJECTIVE_USE_SEAT_ATTRACTOR,
|
||||
OBJECTIVE_USE_ATM_ATTRACTOR,
|
||||
OBJECTIVE_FLEE_CAR, // is it 41?
|
||||
OBJECTIVE_FLEE_CAR,
|
||||
OBJ_42,
|
||||
OBJECTIVE_USE_STOP_ATTRACTOR,
|
||||
OBJECTIVE_USE_PIZZA_ATTRACTOR,
|
||||
@ -563,7 +563,7 @@ public:
|
||||
uint32 m_duckAndCoverTimer;
|
||||
uint32 m_bloodyFootprintCountOrDeathTime; // Death time when bDoBloodyFootprints is false. Weird decision
|
||||
uint32 m_shotTime;
|
||||
uint32 m_shotTimeAdd;
|
||||
uint32 m_ceaseAttackTimer;
|
||||
uint8 m_panicCounter;
|
||||
bool m_deadBleeding;
|
||||
int8 m_bodyPartBleeding; // PedNode, but -1 if there isn't
|
||||
@ -1026,3 +1026,6 @@ void FinishFuckUCB(CAnimBlendAssociation *assoc, void *arg);
|
||||
#ifndef PED_SKIN
|
||||
VALIDATE_SIZE(CPed, 0x53C);
|
||||
#endif
|
||||
|
||||
bool IsPedPointerValid(CPed*);
|
||||
bool IsPedPointerValid_NotInWorld(CPed*);
|
||||
|
Reference in New Issue
Block a user