diff options
Diffstat (limited to 'src/core/References.cpp')
-rw-r--r-- | src/core/References.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/core/References.cpp b/src/core/References.cpp index 3eb2eaf3..52abbc3e 100644 --- a/src/core/References.cpp +++ b/src/core/References.cpp @@ -26,8 +26,17 @@ CReferences::RemoveReferencesToPlayer(void) { if(FindPlayerVehicle()) FindPlayerVehicle()->ResolveReferences(); +#ifdef FIX_BUGS + if (FindPlayerPed()) { + CPlayerPed* pPlayerPed = FindPlayerPed(); + FindPlayerPed()->ResolveReferences(); + CWorld::Players[CWorld::PlayerInFocus].m_pPed = pPlayerPed; + pPlayerPed->RegisterReference((CEntity**)&CWorld::Players[CWorld::PlayerInFocus].m_pPed); + } +#else if(FindPlayerPed()) FindPlayerPed()->ResolveReferences(); +#endif } void |